How jmclaren7/ntpwedit works
NTPWEdit is a Windows utility for editing account passwords and unlock state directly in an offline Windows SAM file. The principal workflow is to select and open a SAM file, enumerate its users, apply an unlock or password change, and save the modified hive. The graph also includes the registry-hive and cryptographic layers, plus the documented password-dialog, hibernation, and informational UI branches. Source excerpts are partial, so some internal calls and optional behavior are not shown.
Main entry points: main.c Main window workflow · ntpw.c Account operations · dialogs.c Dialog framework · libsam.c SAM account parser
Components 15
Application workflow
- Main window workflow
main.c - Logging
libntpw/log.c
Windows interface
- Dialog framework
libdlg/dialogs.c - Dialog controls
libdlg - Password prompt
dlgpass.c - Hibernation prompt
dlghiber.c - About window
dlgabout.c - Message dialogs
message.c - Unicode helpers
libdlg/unicode.c
SAM and registry
- SAM hive file
- Account operations
libntpw/ntpw.c - SAM account parser
libntpw/libsam.c - Registry hive access
libntpw/ntreg.c
Cryptography
- DES and MD4
libntpw/libtomcrypt/src
Other components
- Offline operator
Connections 16
- Offline operator → Main window workflow: uses
- Main window workflow → SAM hive file: selects path
main.c - Main window workflow → Account operations: opens and edits
main.c - Main window workflow → Password prompt: requests password
main.c - Main window workflow → Hibernation prompt: checks hibernation
- Main window workflow → About window: opens about
main.c - Main window workflow → Message dialogs: shows messages
main.c - Main window workflow → Dialog framework: builds dialogs
main.c - Dialog framework → Dialog controls: creates controls
libdlg/dialogs.c - Dialog framework → Unicode helpers: uses helpers
libdlg/dialogs.c - Account operations → SAM account parser: reads account data
libntpw/ntpw.c - Account operations → Registry hive access: edits hive
libntpw/ntpw.c - SAM account parser → Registry hive access: reads hive
libntpw/libsam.c - Account operations → DES and MD4: uses crypto
libntpw/ntpw.c - Account operations → Logging: logs operations
- Main window workflow → SAM hive file: saves changes