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!

Password protected directory loosing the protection

Discussion in 'Security' started by kenrbnsn, Aug 20, 2013.

  1. kenrbnsn

    kenrbnsn Active Member

    Joined:
    Feb 27, 2002
    Messages:
    36
    Likes Received:
    1
    Trophy Points:
    308
    Location:
    Hillsborough, NJ, USA
    I password protected a site by putting a password on the public_html directory. Now three weeks later, the client sent me an email saying it was open. I checked and there was no longer a check mark indicating the directory was password protected. I didn't unprotect it.

    cPanel Version 11.38.2 (build 2)
     
  2. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,749
    Likes Received:
    1,886
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello :)

    The "Password Protect Directories" feature in cPanel utilizes the .htaccess file within the account. You should see an entry such as the following in the "/home/user/public_html/.htaccess" file:

    Code:
    AuthType Basic
    AuthName "test"
    AuthUserFile "/home/user/.htpasswds/public_html/passwd"
    require valid-user
    If the entry is missing, it typically indicates the user installed a script that overwrote the .htaccess file, or the file was manually modified.

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. Infopro

    Infopro cPanel Sr. Product Evangelist
    Staff Member

    Joined:
    May 20, 2003
    Messages:
    16,350
    Likes Received:
    404
    Trophy Points:
    583
    Location:
    Pennsylvania
    cPanel Access Level:
    Root Administrator
    Twitter:
    If the user updated or removed his .htaccess for example, this might remove the protection.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. kenrbnsn

    kenrbnsn Active Member

    Joined:
    Feb 27, 2002
    Messages:
    36
    Likes Received:
    1
    Trophy Points:
    308
    Location:
    Hillsborough, NJ, USA
    That solves it. I use Drupal and updated it which overwrote the .htaccess file. I have to remember that... :(
     
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