mirror of
https://github.com/centreon/centreon-plugins.git
synced 2025-07-26 23:24:27 +02:00
add alternative subject names in long output
This commit is contained in:
parent
0adf67b791
commit
2aaa2da4cc
@ -153,7 +153,11 @@ sub run {
|
|||||||
foreach my $subject_name (@subject_name) {
|
foreach my $subject_name (@subject_name) {
|
||||||
if ($subject_name =~ /$self->{option_results}->{subjectname}/mi) {
|
if ($subject_name =~ /$self->{option_results}->{subjectname}/mi) {
|
||||||
$subject_altname = $subject_name;
|
$subject_altname = $subject_name;
|
||||||
next;
|
} else {
|
||||||
|
if ($subject_name =~/[\w\-]+(\.[\w\-]+)*\.\w+/) {
|
||||||
|
$subject_altname = $subject_name;
|
||||||
|
$self->{output}->output_add(long_msg => sprintf("Subject Name '%s' is also present in Certificate", $subject_altname));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user