Bootstrap FreeKB - Linux Commands - htpasswd (delete user)
Linux Commands - htpasswd (delete user)

Updated:   |  Linux Commands articles

Let's say you have created htpasswd file /usr/local/share/users.htpasswd. The cat command can be used to view the contents of the htpasswd file.

~]# cat /usr/local/share/users.htpasswd
john.doe:$2y$05$sLPYyKUXPaaDfnCXCiz0CueZxRp2eX3NYhgPXaMHBYqCEFeVBZGi6
jane.doe:$2y$05$ZUfeWdLh0Vb1uCHpfS1iTurbeDlUaiigFHSn5dwbCdbcIemXjxVYO

 

The htpasswd command with the -D (delete) option can be used to delete a user from the htpasswd file.

~]# htpasswd -D /usr/local/share/users.htpasswd jane.doe
Deleting password for user jane.doe

 




Did you find this article helpful?

If so, consider buying me a coffee over at Buy Me A Coffee



Comments


Add a Comment


Please enter 75ff24 in the box below so that we can be sure you are a human.