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.

IP Blocker misdetecting rules

Discussion in 'Security' started by Kent Brockman, Jul 19, 2015.

  1. Kent Brockman

    Kent Brockman Well-Known Member

    Joined:
    Jan 20, 2008
    Messages:
    1,130
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    Buenos Aires, Argentina
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello guys, you may want to review this issue.
    It happens when you have a complex dynamic website, and you need to enforce the security by blocking public access to diverse components by using a command like "Deny from".
    The problem arise when you simply use "Deny from all", because cPanel identifies the "all" as an IP. And given that the UI does not allow to use IP's, it may for instance confuse end users.

    You can see an example in the below pasted link:

    - Removed Please Attach Images to Posts -

    Is there any possibility that you filter out those useless "all" in the IP Blocker screen?

    Thanks in advance!

    X5V8K-zurrs3KWK4x4oUMbz4X3qnaVDCYIjDX6qVx8pCiIj0dSkDDkb6PfrL_Vq-7L0hB3TQ=w1838-h772.png
     
    #1 Kent Brockman, Jul 19, 2015
    Last edited by a moderator: Jul 28, 2015
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

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

    Could you attach the image directly to your post instead of linking to a third-party image hosting website? This will allow us to review the example you referenced.

    Thank you.
     
  3. Infopro

    Infopro cPanel Sr. Product Evangelist
    Staff Member

    Joined:
    May 20, 2003
    Messages:
    14,478
    Likes Received:
    203
    Trophy Points:
    63
    Location:
    Pennsylvania
    cPanel Access Level:
    Root Administrator
    Twitter:
    First post updated with image.
     
  4. Kent Brockman

    Kent Brockman Well-Known Member

    Joined:
    Jan 20, 2008
    Messages:
    1,130
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    Buenos Aires, Argentina
    cPanel Access Level:
    Root Administrator
    Twitter:
    Thank you INFOPRO!
     
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

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

    The current behavior is by design. For instance, the "IP Blocker" option in cPanel will display the corresponding entry if you add "Deny From All" to /home/$username/public_html/.htaccess. This helps to prevent duplicate entries in the event an IP address is already blocked in the .htaccess file. Could you elaborate on how you would prefer the interface to handle these entries?

    Thank you.
     
  6. Kent Brockman

    Kent Brockman Well-Known Member

    Joined:
    Jan 20, 2008
    Messages:
    1,130
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    Buenos Aires, Argentina
    cPanel Access Level:
    Root Administrator
    Twitter:
    I think I wasn't totally clear on this one. The problem is that the IP Blocker feature read every ocurrence of "Deny from" string an print it in screen.

    The screen capture I've attached is obtained when you have a .htaccess file with something like this (a common security config for WordPress sites):

    Code:
        <files .htaccess>
            <IfModule mod_authz_core.c>
                Require all denied
            </IfModule>
            <IfModule !mod_authz_core.c>
                Order allow,deny
                Deny from all
            </IfModule>
        </files>
        <files readme.html>
            <IfModule mod_authz_core.c>
                Require all denied
            </IfModule>
            <IfModule !mod_authz_core.c>
                Order allow,deny
                Deny from all
            </IfModule>
        </files>
        <files readme.txt>
            <IfModule mod_authz_core.c>
                Require all denied
            </IfModule>
            <IfModule !mod_authz_core.c>
                Order allow,deny
                Deny from all
            </IfModule>
        </files>
        <files install.php>
            <IfModule mod_authz_core.c>
                Require all denied
            </IfModule>
            <IfModule !mod_authz_core.c>
                Order allow,deny
                Deny from all
            </IfModule>
        </files>
        <files wp-config.php>
            <IfModule mod_authz_core.c>
                Require all denied
            </IfModule>
            <IfModule !mod_authz_core.c>
                Order allow,deny
                Deny from all
            </IfModule>
        </files>
    
    Try uploading this to a root ftp folder, and then check the IP Blocker screen at the acocunt's cpanel, it should be self-explanatory :)
     
  7. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    676
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Internal case FB-48372 should address this issue. There's currently no time frame for it's release, but you can monitor our change log at:

    cPanel - Change Logs

    Thank you.
     
  8. Kent Brockman

    Kent Brockman Well-Known Member

    Joined:
    Jan 20, 2008
    Messages:
    1,130
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    Buenos Aires, Argentina
    cPanel Access Level:
    Root Administrator
    Twitter:
    Thanks. Great to see it will be addressed sometime.. :)
     
Loading...
Similar Threads - Blocker misdetecting rules
  1. epanagio
    Replies:
    4
    Views:
    318

Share This Page