mod_evasive在Ubuntu服务器16.04上不做任何事情

我使用本指南在Apache/2.4.18上设置了mod_evasive : https : mod_evasive

我只将[email protected]更改为root@localhost

我第一次使用test.pl它工作,但每剩余时间它只显示HTTP/1.1 400 Bad Request 。 我不确定是否意外地改变了什么,但是这里是我的test.pl

 #!/usr/bin/perl # test.pl: small script to test mod_dosevasive's effectiveness use IO::Socket; use strict; for(0..100) { my($response); my($SOCKET) = new IO::Socket::INET( Proto => "tcp", PeerAddr=> "127.0.0.1:80"); if (! defined $SOCKET) { die $!; } print $SOCKET "GET /?$_ HTTP/1.0\n\n"; $response = <$SOCKET>; print $response; close($SOCKET); } 

因为它第一次运作,不应该有一个日志呢? 我检查了/var/log/mod_evasive/ ,它是空的。 在syslog中也没有提到mod_evasive/var/mail/只有root没有收到mod_evasive的邮件。

难道是因为我redirecthttphttps ? 我在000-default.conf设置了一个Redirect permanent / https://mydomain.example