SAMPASSWD(8)
π SAMPASSWD(8) π
okay bestie, gather round β this is the manual page for sampasswd, from the System Manager's Manual corner of the universe. It resets passwords of users in the SAM user database. Yes, that SAM. Windows SAM. We're going there. π¦
β¨ NAME β¨
sampasswd β reset passwords of users in the SAM user database
πΈ SYNOPSIS πΈ
sampasswd [options] -uuser <samfile>
π DESCRIPTION π
So this page documents sampasswd briefly. Quick lore drop: this manual page was written for the Debian distribution because the original program doesn't have a manual page at all. Not one. So Debian said "fine, we'll do it ourselves" and honestly? iconic. π
sampasswd is a non-interactive command line utility that can reset a user's password and/or the user's account bits, straight out of the SAM user database file of a Microsoft Windows system β and we're talking Windows NT, 2000, XP, Vista, 7, 8.1, etc. That file usually lives at \WINDOWS\system32\config\SAM on the file system of a Microsoft Windows Operating System. iykyk.
On success, the program outputs literally nothing β silence, bestie, the good kind β and the exit code is 0. π€«β¨
π OPTIONS π
-hβ Show a summary of options. The "help me help you" button. π«Ά-rβ Reset the user's password. This is the whole point of the app, ngl.-aβ Reset all the users. If you use this option there's no need to specify the next option. Doing the most, in the best way. π-u<user> β The user to change. The user value can be provided as a username, or as a RID number in hexadecimal (if the username is preceded with'0x'). Usernames including international characters will probably not work. π-lβ Lists the users in the SAM database. A little headcount, a little who's-who. π-Hβ Output human readable output. By default the program prints a parsable table unless this option is used. So:-H= for your eyes, no-H= for your scripts. π-Nβ Do not allocate more information, only allow the editing of existing values with same size. Tiny, careful, no-growth energy. π±-Eβ Do not expand the hive file (safe mode). Safety first, always.-tβ Print debug information of allocated blocks. For the girls who love a block map. π-vβ Print verbose information and debug messages. Chatty mode: activated. π£οΈ
π₯ EXAMPLES π₯
sampasswd -r -u theboss
Reset the password of a user named 'theboss', if found. π
sampasswd -r -u 0x3ea
Reset the password of the user with RID '0x3a'. β¨
samusrgrp -r -a
Reset the password of all the users in the Administrator's group (0x220). π
samusrgrp -r -f
Reset the password of the administrative users with the lowest RID number. This does not include the built-in administrator (0x1f4) unless no other administrative user can be found in the database file. π΅οΈβοΈ
π KNOWN BUGS π
If the username includes international (non-ASCII) characters, the program will not (usually) find it. Not a vibe. Use the RID number instead. π«‘
π¦ SEE ALSO π¦
chntpwd, reged, samusrgrp
You will find more information available on how this program works in the text files /usr/share/doc/chntpw/README.txt and /usr/share/doc/chntpw/MANUAL.txt. π
More documentation is available at the upstream's author site: http://pogostick.net/~pnh/ntpasswd/ π
π AUTHOR π
This program was written by Petter N Hagen. π«Ά
This manual page was written by Javier Fernandez-Sanguino <jfs@debian.org>, for the Debian GNU/Linux system (but may be used by others). πΈ
and that's the whole page, bestie!! π This was SAMPASSWD(8) from the System Manager's Manual, dated 6th August 2014. Stay safe out there resetting passwords, hydrate, and back up your hive files first. mwah πβ¨
π¦ where this page comes from
- debian bookworm: chntpw 140201-1
- debian trixie: chntpw 140201-1.2
- fedora 43: chntpw 1.00-20.140201.fc43 Β· GPL-2.0-only
- fedora 44: chntpw 1.00-22.140201.fc44 Β· GPL-2.0-only
- ubuntu jammy: chntpw 140201-1
- ubuntu noble: chntpw 140201-1
- ubuntu questing: chntpw 140201-1.2
- ubuntu resolute: chntpw 140201-1.2build1
- ubuntu stonking: chntpw 140201-1.3
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms