MoonPoint Support Logo

 

Shop Amazon Warehouse Deals - Deep Discounts on Open-box and Used ProductsAmazon Warehouse Deals



Advanced Search
June
Sun Mon Tue Wed Thu Fri Sat
12
20 21
22 23 24 25 26 27 28
29 30          
2025
Months
Jun
Jul Aug Sep
Oct Nov Dec


Thu, Jun 12, 2025 9:34 pm

Changing a user's password in an htpasswd file or deleting a user from the file

An .htpasswd file can be used to control access to specific directories that visitors to a web server can access when the web server is an Apache web server. Entries in the file can be added, modified, or deleted using the htpasswd utility, which may be in the /bin directory on a Linux sysem. To update a password for a user listed in an .htpasswd file, a command in the form htpasswd htpasswdFileLocation user where htpasswdFileLocation is the location and name for the .htpassword file on the system and user is a specific user listed in that file. The htpasswd utility will prompt for a new password and then prompt you to retype it to ensure there has not been a typo when the new password was provided. E.g.:

# htpasswd /home/jdoe/music/.htpasswd mary
New password:
Re-type new password:
Updating password for user mary
#

If you wish to delete an entry for a user in the .htpasswd file, you can use a command in the form htpasswd -D htpasswdFileLocation user. The -D indicates the entry for the user should be deleted. The response will indicate the password for the user was deleted, which is true, but that indicates the entire entry for that user was removd from the file. E.g.:

# htpasswd -D /home/jdoe/music/.htpasswd manny
Deleting password for user manny
#

Related

  1. Apache AllowOverride AuthConfig Directive
    Date: May 13, 2008

[/network/web/server/apache] permanent link

Valid HTML 4.01 Transitional

Privacy Policy   Contact

Blosxom logo