HTPasswd Generator Create password credentials for htaccess and htpasswd files

Input enter a username and password
Output copy the entry bellow into your .htpasswd file
Input a user name and password.

Description

The Apache HTTP Server can use a .htpasswd file referenced from a .htaccess file to create restricted protected areas. The .htpasswd file contains rows corresponding to a pair of username and password separated with a colon character. The password is encrypted using the UNIX system's crypt method and may use MD5 or SHA1.
This .htpasswd generator creates passwords that are hashed using the MD5 algorithm. Those passwords can be used on any platform including Windows, MacOsX and Linux.
Once set up, a user wishing to access a restricted directory will be requested a username and password pair to gain access. Only correct pairs will grant access to the requested directory.

Protecting a folder in Apache

To protect a specific folder, a .htaccess file is placed in the directory you want the contents of the file to affect. The rules and configuration directives in the .htaccess file will be enforced on whatever directory it is in and all sub-directories as well. A typical .htaccess file looks like the following:

AuthUserFile /path/to/.htpasswd
AuthType Basic
AuthName "My restricted Area"
Require valid-user

The corresponding .htpasswd file must be placed in the folder defined by the AuthUserFile directive. In that case, it will be located in the "/path/to/.htpasswd" directory. A typical .htpasswd file looks like the following:

user1:$apr1$clme56rh$7kbO8h94VA5UWBNpdayu80
user2:$apr1$l76zf4jy$M7064lZwDjJjGigJ48fqP/
user3:$apr1$f2dmapgz$C.8mBkD1DoUiBVJGaCfJM0

References and links of interest

Wikipedia: .htpasswd

Wikipedia: .htpasswd

.htpasswd is a flat-file used to store usernames and password for basic authentication of Apache HTTP Server. The name of the file is given by in the .htaccess configuration, and can be anything, but ".htpasswd" is the canonical name. The file name starts with a dot, because most Unix-like operating systems consider any file that begins with dot to be hidden. This file is often maintained with the shell command "htpasswd" which can add, delete, and update users, and will properly encode the password for use (so that it is easily checked, but not reversed back to the original password).

Apache tool: htpasswd - Manage user files for basic authentication

Apache tool: htpasswd - Manage user files for basic authentication

htpasswd is used to create and update the flat-files used to store usernames and password for basic authentication of HTTP users. htpasswd encrypts passwords using either a version of MD5 modified for Apache, or the system's crypt() routine.

Javascript Kit: Comprehensive guide to .htaccess - Password protection

Javascript Kit: Comprehensive guide to .htaccess - Password protection

Ever wanted a specific directory in your site to be available only to people who you want it to be available to? Ever got frustrated with the seeming holes in client-side options for this that allowed virtually anyone with enough skill to mess around in your source to get in? htaccess is the answer!

Htaccess Tools: Htpasswd generator

Htaccess Tools: Htpasswd generator

Use the htpasswd generator to create passwords for htpasswd files. Just enter username and password and an entry for a htpasswd file is generated. You can use the htaccces Authentication generator to create a htaccess file that will password protect your site or a directory. This htpasswd generator creates passwords that are hashed using the MD5 algorithm, which means that you can use it for sites hosted on any platform, including Windows and Linux.