Header Shadow Image

Linux: Resetting an MD5 hash for ssh or ftp login.

Just happened to have forgotten a password for one of my user accounts on my workstation and remembered a handy little thing one can do to reset a pass.

If you have root access, one can simply regenerate the MD5 hash with:

# openssl passwd -1 -salt mysalt

# ftp localhost
Connected to localhost (
220 Welcome to the Crazy Town .  If you are not an authorized user, please logout now!
Name (localhost:root): tom
331 Please specify the password.
230 Login successful.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> quit
221 Goodbye.

and replace the existing hash string in proftpd or any other service with what ever is entered as a pass above.  This should help to reset your pass.


Leave a Reply

You must be logged in to post a comment.

  Copyright © 2003 - 2013 Tom Kacperski (microdevsys.com). All rights reserved.

Creative Commons License
This work is licensed under a Creative Commons Attribution 3.0 Unported License