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!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Password protected directory issue

Discussion in 'General Discussion' started by darroosh, Jan 13, 2018.

  1. darroosh

    darroosh Registered

    Joined:
    Jan 13, 2018
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Egypt
    cPanel Access Level:
    Website Owner
    Hi,

    I used Cpanel password protected directories to make some directory password protected.

    Now when I try to go to the firectory URL, it says ( page not found ).
    I opened ( ,htacess) inside this folder and found it containts:

    AuthType Basic
    AuthName "Blablabla"
    AuthUserFile "/home/direcotrry/.htpasswds/public_html/wp-admin/passwd"
    require valid-user


    When I make the lines in the htaccess file as comment ( hash them), the URL works fine again.

    And I went to this path: "/home/direcotrry/.htpasswds/public_html/wp-admin/passwd", to find it's normal containing the username and the encrypted password

    What is wrong?
     
  2. 24x7server

    24x7server Well-Known Member

    Joined:
    Apr 17, 2013
    Messages:
    1,669
    Likes Received:
    73
    Trophy Points:
    28
    Location:
    India
    cPanel Access Level:
    Root Administrator
    Please execute the below command on the server and replicate the blank page scenario and check what error is logged on the server. That will be helpful to troubleshoot and advise properly..

    # tail -f /usr/local/apache/logs/error_logs
     
  3. Jcats

    Jcats Well-Known Member

    Joined:
    May 25, 2011
    Messages:
    605
    Likes Received:
    93
    Trophy Points:
    153
    Location:
    New Jersey
    cPanel Access Level:
    DataCenter Provider
    Try adding this to the end:

    Code:
    ErrorDocument 403 default
    So it will look like:

    Code:
    AuthType Basic
    AuthName "Blablabla"
    AuthUserFile "/home/direcotrry/.htpasswds/public_html/wp-admin/passwd"
    require valid-user
    ErrorDocument 403 default
     
  4. darroosh

    darroosh Registered

    Joined:
    Jan 13, 2018
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Egypt
    cPanel Access Level:
    Website Owner
    I don't have access to server to execute command
    I have added it, But still same result, no change at all.
     
  5. Infopro

    Infopro cPanel Sr. Product Evangelist
    Staff Member

    Joined:
    May 20, 2003
    Messages:
    15,993
    Likes Received:
    338
    Trophy Points:
    433
    Location:
    Pennsylvania
    cPanel Access Level:
    Root Administrator
    Twitter:
    Have you tried simply removing the password protection from this specific directory and then re-add it?

    What is the directory you're attempting to protect? It is in the public_html directory, correct?
     
  6. 24x7server

    24x7server Well-Known Member

    Joined:
    Apr 17, 2013
    Messages:
    1,669
    Likes Received:
    73
    Trophy Points:
    28
    Location:
    India
    cPanel Access Level:
    Root Administrator
    I think you should contact your server provider or the person who has the server access to troubleshoot it..
     
Loading...

Share This Page