HOW TO: mod_evasive

Hi Wael,

I am getting a 404 not found error when trying to download the script. Did you move the script or are you not offering it anymore?
 
I'm getting a "Cannot load /etc/httpd/modules/mod_evasive.so into server: Shared object "libc.so.6" not found, required by "mod_evasive.so"
/usr/sbin/apachectl start: httpd could not be started" error. Anybody have any idea how to correct this since there is no libc.so.6 with the mod_evasive files? And I just uploaded the mod_evasive files and copied them to the above mentioned directories. If there is something to "install", how does one do that, since when I try to run ./configure it gives me an error - I saw someone else had that problem, but I never did see anyone reply to him. I'm running FreeBSD 5.3. Any help would be greatly appreciated.
 
Problem solved.

Note to others:

It helps to actually pay attention to which version of apache you're running; instead of being an idiot like me and jumping to copying and pasting without scrolling down to the Apache 2 heading....where the author had it CLEARLY listed. :)


My apologizes to all who have taken up time to read the above post.
 
Hi all,

i tried to install modsecurity and modevasive but when i am running test.pl i only see:

HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
(a lot of times).

I never see Forbidden or something. I have read the whole topic but i am not good enough at it. Can anyone help me?

(i am dutch, sorry for my bad english!).
 
Question

Hello,
I have some qustion. please help me.
*- I export mod_evasive config from httpd.conf for help me and here is my config:
**- mod_evasive.s directory:
/usr/local/apache/libexec/mod_evasive.so

LoadModule evasive_module libexec/mod_evasive.so

AddModule mod_evasive.c
<IfModule mod_evasive.c>
DOSHashTableSize 3097
DOSPageCount 2
DOSSiteCount 50
DOSPageInterval 1
DOSSiteInterval 1
DOSBlockingPeriod 10
DOSEmailNotify *****@gmail.com
</IfModule>

#ExtendedStatus On

1- How is my config? is it true? is it good?
2- Where is test.pl? I'm not found test.pl on my server!
3- Where is white and black list?
-------
Regards,
M@s0oD
 
Last edited:
Hello,
I have some qustion. please help me.
*- I export mod_evasive config from httpd.conf for help me and here is my config:
**- mod_evasive.s directory:
/usr/local/apache/libexec/mod_evasive.so

LoadModule evasive_module libexec/mod_evasive.so

AddModule mod_evasive.c
<IfModule mod_evasive.c>
DOSHashTableSize 3097
DOSPageCount 2
DOSSiteCount 50
DOSPageInterval 1
DOSSiteInterval 1
DOSBlockingPeriod 10
DOSEmailNotify *****@gmail.com
</IfModule>

#ExtendedStatus On

1- How is my config? is it true? is it good?
2- Where is test.pl? I'm not found test.pl on my server!
3- Where is white and black list?
-------
Regards,
M@s0oD
HELP .............
Lammers **** my server!
 
Test.pl

My test.pl result:
Code:
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 200 OK
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
HTTP/1.1 403 Forbidden
 
I have problems with site using the online foto album Gallery 2.x. If people want to open the thumbs it sometimes gives an 403 error. Also some thumbs aren´t build.
 
Before compile mod

Hi all

before compile Mod_Evasive mod i tried test.pl and perl script returns

Code:
HTTP/1.1 302 Found
HTTP/1.1 302 Found
HTTP/1.1 302 Found

In error_log from apache i read

[Thu Jun 19 12:13:39 2008] [error] [client 127.0.0.1] client sent HTTP/1.1 request without hostname (see RFC2616 section 14.23): /
[Thu Jun 19 12:13:39 2008] [error] [client 127.0.0.1] client sent HTTP/1.1 request without hostname (see RFC2616 section 14.23): /

Any ideas? Why perl returns 302 ?
 
I want use mod_wvasive but i have problem with installation:
Code:
root@server:/usr/src/mod_evasive# /usr/sbin/apxs -a -a -c /usr/src/mod_evasive/mod_evasive.c
/var/www/build/libtool --silent --mode=compile gcc -std=gnu99 -prefer-pic   -DLINUX -D_REENTRANT -D_GNU_SOURCE -g -O2 -pthread -I/usr/include/apache  -I/usr/include/apache   -I/usr/include/apache   -c -o /usr/src/mod_evasive/mod_evasive.lo /usr/src/mod_evasive/mod_evasive.c && touch /usr/src/mod_evasive/mod_evasive.slo
/usr/src/mod_evasive/mod_evasive.c:43:26: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'evasive_module'
/usr/src/mod_evasive/mod_evasive.c:116:47: error: unknown type name 'pool'
/usr/src/mod_evasive/mod_evasive.c: In function 'check_access':
/usr/src/mod_evasive/mod_evasive.c:128:44: error: 'conn_rec' has no member named 'remote_addr'
/usr/src/mod_evasive/mod_evasive.c:129:47: error: 'conn_rec' has no member named 'remote_addr'
/usr/src/mod_evasive/mod_evasive.c:146:15: error: 'FORBIDDEN' undeclared (first use in this function)
/usr/src/mod_evasive/mod_evasive.c:146:15: note: each undeclared identifier is reported only once for each function it appears in
/usr/src/mod_evasive/mod_evasive.c:209:13: warning: implicit declaration of function 'getpid' [-Wimplicit-function-declaration]
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'log' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'log' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'connection' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'connection' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'server' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'log' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'log' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'connection' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'connection' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'server' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'log' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'log' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'connection' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'connection' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'server' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'log' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'log' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'connection' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'connection' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: error: request for member 'server' in something not a structure or union
/usr/src/mod_evasive/mod_evasive.c:243:2: warning: passing argument 5 of 'ap_log_rerror_' makes integer from pointer without a cast [enabled by default]
In file included from /usr/src/mod_evasive/mod_evasive.c:40:0:
/usr/include/apache/http_log.h:456:18: note: expected 'apr_status_t' but argument is of type 'struct request_rec *'
/usr/src/mod_evasive/mod_evasive.c:243:2: warning: passing argument 6 of 'ap_log_rerror_' from incompatible pointer type [enabled by default]
In file included from /usr/src/mod_evasive/mod_evasive.c:40:0:
/usr/include/apache/http_log.h:456:18: note: expected 'const struct request_rec *' but argument is of type 'char *'
/usr/src/mod_evasive/mod_evasive.c: At top level:
/usr/src/mod_evasive/mod_evasive.c:251:47: error: unknown type name 'pool'
/usr/src/mod_evasive/mod_evasive.c:655:9: warning: initialization from incompatible pointer type [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:655:9: warning: (near initialization for 'command_table[0].func.no_args') [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:658:2: warning: initialization from incompatible pointer type [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:658:2: warning: (near initialization for 'command_table[1].func.no_args') [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:661:2: warning: initialization from incompatible pointer type [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:661:2: warning: (near initialization for 'command_table[2].func.no_args') [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:664:2: warning: initialization from incompatible pointer type [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:664:2: warning: (near initialization for 'command_table[3].func.no_args') [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:667:2: warning: initialization from incompatible pointer type [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:667:2: warning: (near initialization for 'command_table[4].func.no_args') [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:670:2: warning: initialization from incompatible pointer type [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:670:2: warning: (near initialization for 'command_table[5].func.no_args') [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:673:2: warning: initialization from incompatible pointer type [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:673:2: warning: (near initialization for 'command_table[6].func.no_args') [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:676:2: warning: initialization from incompatible pointer type [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:676:2: warning: (near initialization for 'command_table[7].func.no_args') [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:679:2: warning: initialization from incompatible pointer type [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:679:2: warning: (near initialization for 'command_table[8].func.no_args') [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:682:9: warning: initialization from incompatible pointer type [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:682:9: warning: (near initialization for 'command_table[9].func.no_args') [enabled by default]
/usr/src/mod_evasive/mod_evasive.c:688:26: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'evasive_module'
apxs:Error: Command failed with rc=65536
.

Debian Wheezy 64Bit

Maybe somebody know how to resolve this problem?

Regards
 
I have the same error when i try install mod_antiloris (from this tutorial: http://help.directadmin.com/item.php?id=302_


Code:
mod_antiloris-0.4/
mod_antiloris-0.4/ChangeLog
mod_antiloris-0.4/mod_antiloris.c
/var/www/build/libtool --silent --mode=compile gcc -std=gnu99 -prefer-pic   -DLINUX -D_REENTRANT -D_GNU_SOURCE -g -O2 -pthread -I/usr/include/apache  -I/usr/include/apache   -I/usr/include/apache   -c -o mod_antiloris.lo mod_antiloris.c && touch mod_antiloris.slo
mod_antiloris.c: In function 'pre_connection':
mod_antiloris.c:126: error: 'conn_rec' has no member named 'remote_ip'
mod_antiloris.c:133: warning: passing argument 1 of 'ap_get_scoreboard_worker' makes pointer from integer without a cast
/usr/include/apache/scoreboard.h:185: note: expected 'struct ap_sb_handle_t *' but argument is of type 'int'
mod_antiloris.c:133: error: too many arguments to function 'ap_get_scoreboard_worker'
mod_antiloris.c:146: error: 'conn_rec' has no member named 'remote_ip'
apxs:Error: Command failed with rc=65536

Please help :)

Regards
 
Back
Top