Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

mod_evasive + RH9

Discussion in 'General Discussion' started by P_W, Nov 19, 2005.

  1. P_W

    P_W Active Member

    Joined:
    Oct 7, 2003
    Messages:
    43
    Likes Received:
    0
    Trophy Points:
    156
    I've looked and I've not found a difinitive guide to installing dos_evasive on a cpanel server. Here's what I'm attmpting to do:

    cd /usr/local/src
    wget http://www.nuclearelephant.com/projects/mod_evasive/mod_evasive_1.10.1.tar.gz
    tar zxpf mod_evasive.1.10.1.tar.gz

    /usr/local/apache/bin/apxs -iac /usr/local/src/mod_evasive/mod_dosevasive.c





    ================================
    And here's what I get:
    ================================

    /usr/bin/libtool --silent --mode=compile gcc -prefer-pic -O2 -g -pipe -march=i386 -mcpu=i686 -DSSL_EXPERIMENTAL_ENGINE -I/usr/kerberos/include -DAP_HAVE_DESIGNATED_INITIALIZER -DLINUX=2 -D_REENTRANT -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -D_SVID_SOURCE -D_GNU_SOURCE -pthread -I/usr/include/httpd -c -o /usr/local/src/mod_evasive/mod_evasive.lo /usr/local/src/mod_evasive/mod_evasive.c && touch /usr/local/src/mod_evasive/mod_evasive.slo
    /usr/local/src/mod_evasive/mod_evasive.c:43: syntax error before "evasive_module"
    /usr/local/src/mod_evasive/mod_evasive.c:43: warning: data definition has no type or storage class
    /usr/local/src/mod_evasive/mod_evasive.c:116: syntax error before "pool"
    /usr/local/src/mod_evasive/mod_evasive.c: In function `check_access':
    /usr/local/src/mod_evasive/mod_evasive.c:128: request for member `sin_addr' in something not a structure or union
    /usr/local/src/mod_evasive/mod_evasive.c:129: request for member `sin_addr' in something not a structure or union
    /usr/local/src/mod_evasive/mod_evasive.c:146: `FORBIDDEN' undeclared (first use in this function)
    /usr/local/src/mod_evasive/mod_evasive.c:146: (Each undeclared identifier is reported only once
    /usr/local/src/mod_evasive/mod_evasive.c:146: for each function it appears in.)
    /usr/local/src/mod_evasive/mod_evasive.c:245: warning: passing arg 4 of `ap_log_rerror' makes integer from pointer without a cast
    /usr/local/src/mod_evasive/mod_evasive.c:245: warning: passing arg 5 of `ap_log_rerror' from incompatible pointer type
    /usr/local/src/mod_evasive/mod_evasive.c: At top level:
    /usr/local/src/mod_evasive/mod_evasive.c:251: syntax error before "pool"
    /usr/local/src/mod_evasive/mod_evasive.c:655: warning: initialization from incompatible pointer type
    /usr/local/src/mod_evasive/mod_evasive.c:658: warning: initialization from incompatible pointer type
    /usr/local/src/mod_evasive/mod_evasive.c:661: warning: initialization from incompatible pointer type
    /usr/local/src/mod_evasive/mod_evasive.c:664: warning: initialization from incompatible pointer type
    /usr/local/src/mod_evasive/mod_evasive.c:667: warning: initialization from incompatible pointer type
    /usr/local/src/mod_evasive/mod_evasive.c:670: warning: initialization from incompatible pointer type
    /usr/local/src/mod_evasive/mod_evasive.c:673: warning: initialization from incompatible pointer type
    /usr/local/src/mod_evasive/mod_evasive.c:676: warning: initialization from incompatible pointer type
    /usr/local/src/mod_evasive/mod_evasive.c:679: warning: initialization from incompatible pointer type
    /usr/local/src/mod_evasive/mod_evasive.c:682: warning: initialization from incompatible pointer type
    /usr/local/src/mod_evasive/mod_evasive.c:688: syntax error before "evasive_module"
    /usr/local/src/mod_evasive/mod_evasive.c:689: `this_module_needs_to_be_ported_to_apache_2_0' undeclared here (not in a function)
    /usr/local/src/mod_evasive/mod_evasive.c:689: initializer element is not constant
    /usr/local/src/mod_evasive/mod_evasive.c:689: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:690: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:690: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:691: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:691: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:692: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:692: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:693: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:693: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:694: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:694: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:695: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:695: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:696: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:696: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:697: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:697: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:698: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:698: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:699: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:699: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:700: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:700: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:701: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:701: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:702: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:702: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:703: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:703: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:704: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:704: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:705: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:705: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:706: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:706: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:708: warning: excess elements in scalar initializer
    /usr/local/src/mod_evasive/mod_evasive.c:708: warning: (near initialization for `evasive_module')
    /usr/local/src/mod_evasive/mod_evasive.c:708: warning: data definition has no type or storage class
    apxs:Error: Command failed with rc=65536


    Any ideas?
     
  2. chirpy

    chirpy Well-Known Member

    Joined:
    Jun 15, 2002
    Messages:
    13,460
    Likes Received:
    21
    Trophy Points:
    463
    Location:
    Go on, have a guess
    It might be something as simple as running apxs from within the actual directory. Here is what I do (using your src path):

    Code:
    cd /usr/local/src
    wget http://www.nuclearelephant.com/projects/mod_evasive/mod_evasive_1.10.1.tar.gz
    tar -xzf mod_evasive*
    cd mod_evasive*
    /usr/local/apache/bin/apxs -cia mod_evasive.c
    
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. P_W

    P_W Active Member

    Joined:
    Oct 7, 2003
    Messages:
    43
    Likes Received:
    0
    Trophy Points:
    156
    Thanks for the reply Chirpy! Unfortunately, I got the same message. Hmmm... any more ideas?
     
  4. P_W

    P_W Active Member

    Joined:
    Oct 7, 2003
    Messages:
    43
    Likes Received:
    0
    Trophy Points:
    156
    ... wait wait, a typo on my part! Worked fine!

    You will get:
    =====================================

    /usr/local/apache/bin/apxs -cia mod_evasive.c
    gcc -DLINUX=22 -DHAVE_SET_DUMPABLE -I/usr/include/gdbm -DMOD_SSL=208122 -DUSE_HSREGEX -DEAPI -fpic -DSHARED_MODULE -I/usr/local/apache/include -c mod_evasive.c
    gcc -shared -o mod_evasive.so mod_evasive.o
    [activating module `evasive' in /usr/local/apache/conf/httpd.conf]
    cp mod_evasive.so /usr/local/apache/libexec/mod_evasive.so
    chmod 755 /usr/local/apache/libexec/mod_evasive.so
    cp /usr/local/apache/conf/httpd.conf /usr/local/apache/conf/httpd.conf.bak
    cp /usr/local/apache/conf/httpd.conf.new /usr/local/apache/conf/httpd.conf
    rm /usr/local/apache/conf/httpd.conf.new

    =====================================

    Thanks again Chirpy! I'm sure a lot can benefit with the walkthrough. As simple as it was, I couldn't find one specifically for cpanel anywhere, so I was a bit hesitant. Regardless, thanks!!
     
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice