1

I was wondering if it is possible to create a windows SAM file. I already tried using chntpw but it seems like it only works under a Redhat based linux, ie I was able to blank/change a Windows 7 64bit box on Fedora with chntpw 0.99.5 but I couldn't get it done using Backtrack 5, Ubuntu or Kali. I know I can recover the password with tools like ophcrack or just using pwdump or sth like that to get the NTLM hashes and then decypt it using bruteforce or rainbow attacks, but I want to know if it is possible to just replace the hash in the SAM file (with physical access to the box using a live os), in another words I just want to know how chntpw works and how to do what it does manually. any help is appreciated...

please note that my problem isn't replacing the password I know several ways to do that, as I said in the title I want to know if it is possible to generate a SAM file from NTLM hashes, I want to know how these NTLM hashes are stored in the SAM file. I don't want any tools, if anything I want a tool that does the reverse of what pwdump does , ie take the hashes and store it to the SAM file (with live cd of course).

2
  • 1
    SAM file follows the Windows registry format, which is documented here sentinelchicken.com/research/registry_format With that, and some Registry viewer like RegistryViewer you can learn a lot about the SAM file and how to generate them.
    – Adi
    Commented May 27, 2014 at 10:23
  • @Adnan The document was really helpful Thanks a lot...
    – Ashkan
    Commented May 28, 2014 at 3:47

1 Answer 1

-1

Yes, the Windows passwords saved inside the SAM file can be changed, provided the operating system is shut down, you have physical access to the machine and the disk is not encrypted.

A tool that never failed me is ntpasswd, which can be executed from a CD or a USB key and it's very easy to use.

1
  • Thank you very much for the information but my problem isn't replacing the password I know several ways to do that, as I said in the title I want to know if it is possible to generate a SAM file from NTLM hashes, I want to know how these NTLM hashes are stored in the SAM file. I don't want any tools, if anything I want a tool that does the reverse of what pwdump does , ie take the hashes and store it to the SAM file (with live cd of course).
    – Ashkan
    Commented May 27, 2014 at 9:53

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .