The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Installing modsecurity Error

Discussion in 'Security' started by prakashnplink, Aug 6, 2015.

  1. prakashnplink

    prakashnplink Active Member

    Joined:
    Apr 8, 2014
    Messages:
    29
    Likes Received:
    1
    Trophy Points:
    3
    cPanel Access Level:
    Root Administrator
    I was trying to install modsecurity OWASP rules but got following error, anybody any idea?

    Error:The system experienced the following error when it attempted to install the “OWASP ModSecurity Core Rule Set” vendor: API failure: The vendor metadata does not contain an entry for your version of ModSecurity, “2.7.7”. The only versions of ModSecurity this rule set supports are “2.8.0” and “2.9.0”.

    Of course it means what it says, I must have 2.7.7 modsecurity version but when I checked from WHM easyapache it is already in 2.9. How to remove modsecurity completely and reinstall it? I have already tried from easyapache but was not helpful.
     
  2. quizknows

    quizknows Well-Known Member

    Joined:
    Oct 20, 2009
    Messages:
    940
    Likes Received:
    55
    Trophy Points:
    28
    cPanel Access Level:
    DataCenter Provider
    You should just need to run an easyapache with your current apache and php versions intact. That will upgrade modsecurity when it runs.

    When new ModSecurity versions are available in EA, you don't get the new version unless you re-run EA. In other words, just because EA builds modsec 2.9 now doesn't mean you're running that version unless you've recently ran a build.
     
  3. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,724
    Likes Received:
    660
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    Yes, as mentioned, it's likely because you have not run EasyApache recently. Ensure you proceed with the actual Apache build when utilizing the EasyApache option.

    Thank you.
     
  4. prakashnplink

    prakashnplink Active Member

    Joined:
    Apr 8, 2014
    Messages:
    29
    Likes Received:
    1
    Trophy Points:
    3
    cPanel Access Level:
    Root Administrator
    yes ofcourse easyapache was run and apache is rebuild again but again same problem. There is two options to build apache: apache 2.2 and 2.4, our apache is 2.2. The thing is that even it is not upgraded to minor version like from 2.2.26 to 2.2.29 or 2.2.31. How to upgrade minor version of apache when there is only two option 2.2 and 2.4? :(
     
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,724
    Likes Received:
    660
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    The most recent minor version available with EasyApache is automatically utilized. Have you verified that EasyApache completes successfully and there are no build failures?

    Thank you.
     
  6. quizknows

    quizknows Well-Known Member

    Joined:
    Oct 20, 2009
    Messages:
    940
    Likes Received:
    55
    Trophy Points:
    28
    cPanel Access Level:
    DataCenter Provider
    You can run "/scripts/easyapache --latest-versions" to see what the latest minor versions are that will be built:

    Code:
    [root@new ~]# /scripts/easyapache --latest-versions
    !! Object fetch succeeded with {"status":"1"} for EasyApache v3305 and Cpanel v1150 !!
    Easy Apache v3.30.5
    
    [Apache]
       2.2.31, 2.4.16
    
    [PHP 5]
       5.3.29, 5.4.44, 5.5.28, 5.6.12
    
     
  7. prakashnplink

    prakashnplink Active Member

    Joined:
    Apr 8, 2014
    Messages:
    29
    Likes Received:
    1
    Trophy Points:
    3
    cPanel Access Level:
    Root Administrator
    Okay looks like there is an error while rebuilding Apache. Because of this error, easyapache roll back to previous state and apache was never updated.

    ERROR:

    Configuration problem detected on line 28 of file /usr/local/apache/conf/httpd.conf.1440180446: : Syntax error on line 2 of /usr/local/apache/conf/includes/pre_main_global.conf: Cannot load /usr/local/apache/modules/mod_rpaf-2.0.so into server: /usr/local/apache/modules/mod_rpaf-2.0.so: cannot open shared object file: No such file or directory

    I think the module mod_rpaf-2.0.so is manually installed. To fix it I have to do following:

    [1] Remove the LoadModule line for the custom unsupported mod_rpaf-2.0 module from Apache includes
    [2] Run EasyApache as desired
    [3] Manually re-install the custom unsupported mod_rpaf-2.0 module again and put its LoadModule line back

    Thank you for replies. :)
     
    #7 prakashnplink, Aug 24, 2015
    Last edited by a moderator: Aug 24, 2015
  8. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,724
    Likes Received:
    660
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
  9. prakashnplink

    prakashnplink Active Member

    Joined:
    Apr 8, 2014
    Messages:
    29
    Likes Received:
    1
    Trophy Points:
    3
    cPanel Access Level:
    Root Administrator
Loading...

Share This Page