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.

Stop cPanel redirects for subdomains, subfolders

Discussion in 'Security' started by kpmedia, Dec 5, 2013.

  1. kpmedia

    kpmedia Well-Known Member

    Joined:
    Feb 13, 2011
    Messages:
    85
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    USA, Europe
    cPanel Access Level:
    Root Administrator
    I'm annoyed by the swiss cheese of cPanel. Specially, all the login methods available.
    It causes problems, and I'm tired of it.

    I want to entirely block
    - subdomains (cpanel., whm., etc)
    - subfolders (/cpanel, /whm, etc)

    I DO NOT want to merely redirect them. I want the requests to be 404.

    Not on a per-domain level, but the whole server. This is honestly a stupid feature, and should not exist.

    How can these be disabled permanently?
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

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

    You can disable the "Proxy subdomains" option under the "Domains" tab in "WHM Home » Server Configuration » Tweak Settings". The "ScriptAliasMatch" entries for /cpanel, /whm, and /webmail can be removed from the /usr/local/apache/conf/httpd.conf file. Remember to edit the httpd.conf file using the instructions at the URL below to ensure the changes are preserved:

    EasyApache: Changes Contained Outside a VirtualHost Directive

    Thank you.
     
Loading...

Share This Page