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!

SecFilterSelective HTTP_User-Agent

Discussion in 'General Discussion' started by dan.andrus, Aug 29, 2006.

  1. dan.andrus

    dan.andrus Member

    Joined:
    Jun 30, 2006
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    151
    Hi all

    One of our clients has implemented a payment system with 2checkout.
    Our logs indicate that are receiving a "403 - Forbidden" error notice when
    attempting to access this page. This is most likely because in the case of
    direct return, HTTP_USER_AGENT is identified as:

    "2Checkout.com-purchase libwww-perl/5.800"

    I implemented the following in httpd.conf but still doesn't works.

    SecFilterSelective HTTP_User-Agent "("2Checkout.com-purchase libwww-perl/5.800)" allow


    Thank you very much
     
  2. jsnape

    jsnape Well-Known Member

    Joined:
    Mar 11, 2002
    Messages:
    174
    Likes Received:
    0
    Trophy Points:
    316
    This syntax example *might* help. I just happened to have it open

    # Only allow our own test utility to send requests (or Mozilla)
    SecFilterSelective HTTP_USER_AGENT "!(mod_security|mozilla)"
     
  3. nickp666

    nickp666 Well-Known Member

    Joined:
    Jan 28, 2005
    Messages:
    769
    Likes Received:
    2
    Trophy Points:
    168
    Location:
    /dev/null
    try delimiting the full stops with \
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. dan.andrus

    dan.andrus Member

    Joined:
    Jun 30, 2006
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    151
    Thanks all..finally i got it solved...had to remove libwhisker from
    SecFilterSelective HTTP_User-Agent "(libwhisker|paros|wget|libwww|perl|curl)"

    Hopefully nothing will go wrong as i don't exactly now what libwhisker does...
     
  5. dan.andrus

    dan.andrus Member

    Joined:
    Jun 30, 2006
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    151
    Got the same problem with another domain

    "POST /../.../script.php HTTP/1.1 "403 - "-" "libwww-perl/5.65" in error log

    I could disable perl and libwww in
    SecFilterSelective HTTP_User-Agent "(libwhisker|paros|wget|libwww|perl|curl)"
    but i don't hnow how wise it is...

    What do u mean by "try delimiting the full stops with \"? an example pls...

    Thanks again
     
  6. nickp666

    nickp666 Well-Known Member

    Joined:
    Jan 28, 2005
    Messages:
    769
    Likes Received:
    2
    Trophy Points:
    168
    Location:
    /dev/null
    SecFilterSelective HTTP_User-Agent "("2Checkout\.com-purchase libwww-perl\/5\.800)" allow
    (as an example of the delimiting)

    I dont think you need the brackets for a single string.
    SecFilterSelective HTTP_User-Agent "2Checkout\.com-purchase libwww-perl\/5\.800" allow

    should do the trick, if that string is going to work
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  7. dan.andrus

    dan.andrus Member

    Joined:
    Jun 30, 2006
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    151

    thanx a lot nickp666, that solved the problem
     

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