Add BADREQ with return code0, and accept anything else that is routed to https
This commit is contained in:
@ -22,10 +22,20 @@ sub parser {
|
||||
m/(\ ($re_host):[0-9]{1,6})/gcix && do {
|
||||
$host = $2;
|
||||
};
|
||||
} elsif($string =~ m/https\~ servers\/httpd/) {
|
||||
#haproxy routed this somewhere, probably not the worst
|
||||
$hostile = 0;
|
||||
$reply = 'Routed to https, do not care:)'
|
||||
} elsif($string =~ m/https\~ https\/\<NOSRV\>/) {
|
||||
if($string =~ m/-1\/-1\/-1\/-1\/[0-9]{1,20} 0 0/) {
|
||||
#This one seems like someone is doing something bad. Return code 0
|
||||
$_ = $string;
|
||||
$hostile = 1;
|
||||
$reply = 'Bad request, return code 0';
|
||||
PARSE:
|
||||
m/(\ ($re_host):[0-9]{1,6})/gcix && do {
|
||||
$host = $2;
|
||||
};
|
||||
}
|
||||
} elsif($string =~ m/https\~ /) {
|
||||
#Accepted as https, probably fine..
|
||||
$reply = 'Routed as https';
|
||||
} elsif($string =~ m/stopped \(cumulated conns/) {
|
||||
#Usual service restart info
|
||||
$hostile = 0;
|
||||
|
||||
Reference in New Issue
Block a user