This is a discussion on htpasswd creating passwd file probs within the Apache Web Server forums, part of the Web Server and Related Forums category; Hey all! I haven't had problems with using htpasswd before - but lately, my head is spinning.... I run the ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Hey all!
I haven't had problems with using htpasswd before - but lately, my head is spinning.... I run the command to make a password (eg. htpasswd -c /home/user/passwords/passwd dude). It'll prompt for a password 2 times, then say's it made it. If I'm logged in as root - the file isn't created. If I'm logged in as user - the file is created, BUT, it wouldn't work....I stirred and stirred (and fried), then I found that the permissions for the passwd file were wrong (600)...when I make it (644) all's good! I guess I'm wondering - Is this normal?...do you have to chmod the passwd file once it's made always? Why can't root use htpasswd? Does any of this make sense? Thanks! |
|
|||
|
sLIVER <sLIVER@dontemailmeanyspam.not> wrote:
> I guess I'm wondering - Is this normal?...do you have to chmod the passwd > file once it's made always? If you create it with the wrong permission yes, umask is used to decide the permission of new files/directories. > Why can't root use htpasswd? This I don't know. Check the log files of your system. Since htpasswd uses the crypt libraries, maybe those are broken. Davide |
|
|||
|
"Davide Bianchi" <davideyeahsure@onlyforfun.net> wrote in message news:bokqcr$1fofta$3@ID-18487.news.uni-berlin.de... > sLIVER <sLIVER@dontemailmeanyspam.not> wrote: > > I guess I'm wondering - Is this normal?...do you have to chmod the passwd > > file once it's made always? > > If you create it with the wrong permission yes, umask is used to > decide the permission of new files/directories. > > > Why can't root use htpasswd? > > This I don't know. Check the log files of your system. Since htpasswd > uses the crypt libraries, maybe those are broken. > > Davide Thanks! I'm still not sure why htpasswd would give the file those permissions when it didn't a while ago. What is the ideal file permissions for the passwd files? |
|
|||
|
sLIVER <sLIVER@dontemailmeanyspam.not> wrote:
> Thanks! I'm still not sure why htpasswd would give the file those > permissions when it didn't a while ago. What is the ideal file permissions > for the passwd files? The permission aren't really important, as long as the file can be read by the Apache process, the most important thing is to put the file somewhere where he can't be reached trought the Web. So, don't put it somewhere in your htdocs tree, put it in /etc/ or something. Where the other configuration files of apache are is fine, be sure to include the full path of the file in the AuthPasswdFile directive. Davide |
|
|||
|
"Davide Bianchi" <davideyeahsure@onlyforfun.net> wrote in message news:boljed$1bcpmg$2@ID-18487.news.uni-berlin.de... > sLIVER <sLIVER@dontemailmeanyspam.not> wrote: > > Thanks! I'm still not sure why htpasswd would give the file those > > permissions when it didn't a while ago. What is the ideal file permissions > > for the passwd files? > > The permission aren't really important, as long as the file can > be read by the Apache process, the most important thing is to > put the file somewhere where he can't be reached trought the Web. > So, don't put it somewhere in your htdocs tree, put it in /etc/ or > something. Where the other configuration files of apache are is fine, > be sure to include the full path of the file in the AuthPasswdFile > directive. > > Davide Ya, the setup is all correct, again, it was just something I noticed lately about setting up new passwords. It works once I change the permissions. |
| Thread Tools | |
| Display Modes | |
|
|