If you need to change the encrypted password in the
smbpasswd file, you can also use the
smbpasswd program. Note that this program shares the same name as the encrypted password file itself, so be sure not to accidentally confuse the password file with the password-changing program.
The
smbpasswd program is almost identical to the
passwd program that is used to change Unix account passwords. The program simply asks you to enter your old password (unless you're the root user), and duplicate entries of your new password. No password characters are shown on the screen.
#
smbpasswd dave
Old SMB password:
New SMB password:
Retype new SMB password:
Password changed for user dave
You can look at the
smbpasswd file after this command completes to verify that both the LAN Manager and the NT hashes of the passwords have been stored in their respective positions. Once users have encrypted password entries in the database, they should be able to connect to shares using encrypted passwords!