HTPASSWD(1) htpasswd HTPASSWD(1) (NAME) htpasswd - HTTP (SYNOPSIS) htpasswd [ -c ] [ -i ] [ -m | -B | -2 | -5 | -d | -s | -p ] [ -r rounds ] [ -C cost ] [ -D ] [ -v ] passwdfile username htpasswd -b [ -c ] [ -m | -B | -2 | -5 | -d | -s | -p ] [ -r rounds ] [ -C cost ] [ -D ] [ -v ] passwdfile username password htpasswd -n [ -i ] [ -m | -B | -2 | -5 | -d | -s | -p ] [ -r rounds ] [ -C cost ] username htpasswd -nb [ -m | -B | -2 | -5 | -d | -s | -p ] [ -r rounds ] [ -C cost ] username password (DESCRIPTION) htpasswd (flat-files) HTTP . htpasswd . Apache HTTP htpasswd . . . DBM dbmmanage htdbm . htpasswd bcrypt MD5 SHA-1 crypt() . SHA-2 ( SHA-256 SHA-512) crypt() . htpasswd bcrypt MD5 crypt() . . httpd http://httpd.apache.org . (OPTIONS) -b (batch mode) . . -i . 2.4.4 . -i (stdin) ( ). -c passwdfile. passwdfile (truncate) . -n . -n . . passwdfile ( ) . -c . -m MD5 . ( 2.2.18). -2 crypt() SHA-256 . . -5 crypt() SHA-512 . . -B bcrypt . . -C -B ( bcrypt) . bcrypt ( : 5 : 4 17). -r -2 -5 . SHA-2 ( : 5000). -d crypt() . httpd Netware . . . 2.2.17 . -s SHA-1 ( ) . / Netscape LDAP Directory Interchange Format (ldif) . . -p (plaintext). htpasswd httpd Netware . -D . htpasswd . -v . htpasswd . 2.4.5 . passwdfile . -c . username passwdfile. username . . password . -b . (EXIT STATUS) htpasswd passwdfile ("true") . htpasswd 1 2 3 4 ( ) 5 ( ) 6 7 . (EXAMPLES) htpasswd /usr/local/etc/apache/.htpasswd-users jsmith jsmith . . MD5 . htpasswd . htpasswd -c /home/doe/public_html/.htpasswd jane jane . . htpasswd . htpasswd -db /usr/web/.htpasswd-all jones Pwd4Steve (Pwd4Steve) crypt() . (SECURITY CONSIDERATIONS) htpasswd URI -- . setuid . setuid . -b . crypt() . . SHA-1 (salt) : . crypt() MD5 (dictionary attacks) . SHA-1 crypt() . crypt() SHA-2 ( SHA-256 SHA-512) https://www.akkadia.org/drepper/SHA-crypt.txt . (RESTRICTIONS) htpasswd 255 . . MD5 htpasswd . 255 : . bcrypt -C . apr- util 1.6.0 . (FILES) . passwdfile . (#) . Apache HTTP Server 2026-05-08 HTPASSWD(1)