I need to take our unix password file and make the usernames and passwords in a .htpasswd file to protect some webpages. I really dont want to type them in. Any suggestions how I do this?
for .htpasswd you usually just have to have a
So.. if your web server can handle your hash of choice, you simply need to get the username and hashes... should be able to get that from /etc/shadow (on most systems). What *ix are you using?
So in general:
cut -f1,2 -d: /etc/shadow
would suffice. But only if your passwords are in DES crypt format or MD5 (only on newer web servers). Other hashes may be possible, but in general you can only count on DES or MD5.
I've created .htaccess and use htpasswd comand to create .htpasswd
Now when I try to access my protected area I still have loging panel.
I checked apache error log lile and found that there is some problem with mismatch password.
I use Apache 2.2 .22
Is there some erron in creating... (25 Replies)
Dear all,
I am unable to get the desired result upon executing the below script. the problem is at `perl -le 'print scalar localtime $msecage'` ouput which gives the following result "Thu Jan 1 05:00:00 1970" instead of "Tue Nov 13 10:30:56 2012" but when I run the same command from shell... (2 Replies)
Hi Folks,
I have Solaris 10, latest release.
We have passwd aging set in /etc/defalut/passwd.
I have an account that passwd should never expire. Acheived by emptying associated users shadow file entries for passwd aging.
When I reset the users passwd using passwd command, it re enables... (3 Replies)
I wrote a script to batch-create directories with .htaccess and .htpasswd files.
I am using the following line to create the .htpasswd file:
htpasswd -cb .htpasswd $USER $PASS
However, I keep getting this message in return:
Usage: htpasswd passwordfile username
The -c flag creates a new... (1 Reply)
i wonder if there is a tool to read the /etc/passwd or /etc/shadow files in order to reset user accounts to the same one.
By moving (restore) all filessytem and data to another same Sun box, none of the users are able to logon to the new box which i didn't change nothing. But if i reset the user... (1 Reply)
dear unix,
need ur help, i have installed apache n apache is working... but i cant use htpasswd , the error said command not found. for web authentucation...
thanks for any help
:confused: (4 Replies)
Hi all,
As all of us know that in /etc/passwd file the first field correspond to username
could any one tell me what is bin , damoen etc in the first field, and r they in
user field , what is nologin in the last column ?
root:x:0:0:root:/root:/bin/bash ... (4 Replies)