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 protect not working.

Discussion in 'General Discussion' started by rfc5141, Dec 31, 2013.

  1. rfc5141

    rfc5141 Registered

    Joined:
    Dec 31, 2013
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Website Owner
    I'm trying to password protect my admin folder. I have tried via the Password Protect icon on cPanel and by right clicking on the applicable folder. I enter a name, click the check box to protect and save. I click go back, create a new user and save. When I enter url i go straight to home page, however when I add /admin to go to the backend, I go straight there with no prompt for login. When I first created the password protect it worked initially, however every attempt since takes me straight back in to backend. I've deleted user, I've renamed folder and tried to protect again, I've cleared my cache. Can any kind-hearted soul please help put me out of my misery?:confused:
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

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

    Please review the .htaccess file in the public_html and "admin" directory. Do you see any entries related to the password protection of the directory? Have you confirmed the domain name resolves to the same server that you accessed cPanel on?

    Thank you.
     
  3. cPanelPeter

    cPanelPeter Technical Analyst III
    Staff Member

    Joined:
    Sep 23, 2013
    Messages:
    569
    Likes Received:
    15
    Trophy Points:
    18
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello,

    In addtion to what cPanelMichael mentioned above, by any chance do you have FrontPage Extensions installed on that account? You may not be using them, but if you have them installed they will interfere with cPanel's password protection method (.htaccess Basic Authentication).
     
  4. rfc5141

    rfc5141 Registered

    Joined:
    Dec 31, 2013
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Website Owner
    Hello Peter,

    No, I have just checked. They are not installed. Can't understand why this worked when I initially created the login for the folder but any subsequent visits to the admin have gone straight there without a login prompt.
     
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    675
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
  6. MesinHosting

    MesinHosting Member

    Joined:
    Mar 25, 2011
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    1
    usually i wrote my own code for www authentification based on php documentation. in case use with conjunction for alternative way to protect directories.

    but i think the simplest way for you is. contact your hosting provider to made your admin folder protected. and if they cant, just move to another hosting.

    i think this will solved your problem
     
  7. walt

    walt Member

    Joined:
    Oct 30, 2015
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Houston, Tx
    cPanel Access Level:
    Website Owner
    I understand this is an old thread, but just wanted to add some more info.

    Same issue: password pop-up is only seen once, subsequent visits to protected url (in protected folder) go right through, without needing a password. -Unless- you close and restart the browser. Then, again you only need to enter the password once.

    I have tried this on Windows xp with Firefox 41.0, and on a Linux computer with Midori browser. Both act the same way. I wouldn't go as far as saying password protection is not working, but I would rather it asked for credentials every time.

    However, I suspect this has nothing to do with cPanel. I think all cPanel does is create the htaccess file for you, and add a password in the password file? So maybe it has something to do with Apache settings, or the browsers saving the login info somewhere I cannot find. Deleting all Firefox's saved passwords didn't help.
     
    #7 walt, Mar 16, 2016
    Last edited: Mar 16, 2016
  8. kdean

    kdean Well-Known Member

    Joined:
    Oct 19, 2012
    Messages:
    262
    Likes Received:
    12
    Trophy Points:
    18
    Location:
    Orlando, FL
    cPanel Access Level:
    Root Administrator
    That's how HTTP Authentication works. Browsers remain logged in until they are restarted. There's no timeout of the login.
     
Loading...

Share This Page