{"id":6,"date":"2008-07-30T16:40:55","date_gmt":"2008-07-30T20:40:55","guid":{"rendered":"http:\/\/ubuntucat.wordpress.com\/?p=259"},"modified":"2010-07-28T22:28:27","modified_gmt":"2010-07-29T02:28:27","slug":"resetwindowspasswordold","status":"publish","type":"post","link":"https:\/\/www.psychocats.net\/ubuntucat\/resetwindowspasswordold\/","title":{"rendered":"How to reset a Windows password with Ubuntu"},"content":{"rendered":"<p>If you ever have forgotten your password for the only administrative account on Windows or know someone who has, you know the experience can be infuriating. All is not lost, though, if you have a live CD handy. This page is an adaption of <a href=\"http:\/\/rhadimas.wordpress.com\/2006\/10\/15\/reset-windows-password-w-knoppix\/\">Reset a Windows password with Knoppix<\/a> for Ubuntu. It has also been tested for Windows XP, Windows Vista, and Windows 7. <\/p>\n<p> This tutorial assumes you know how to obtain and boot a Ubuntu CD. If you don&#8217;t, go <a href=\"http:\/\/www.psychocats.net\/ubuntu\/getting\">here<\/a> first. <\/p>\n<p> Start off by booting the Ubuntu CD. <\/p>\n<p>\n<a href=\"http:\/\/www.psychocats.net\/wpimages\/ntpass01.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.psychocats.net\/wpimages\/ntpass01.png\" width=\"456\" height=\"353\" border=\"0\"><\/a><br \/> Select your language of choice and then <i>Try Ubuntu without any change to your computer<\/i>. <\/p>\n<p>\n<a href=\"http:\/\/www.psychocats.net\/wpimages\/ntpass03.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.psychocats.net\/wpimages\/ntpass03.png\" width=\"467\" height=\"354\" border=\"0\"><\/a><br \/> Once the live session has loaded, go to System &gt; Administration &gt; Synaptic Package Manager. <\/p>\n<p>\n<a href=\"http:\/\/www.psychocats.net\/wpimages\/ntpass04.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.psychocats.net\/wpimages\/ntpass04.png\" width=\"396\" height=\"169\" border=\"0\"><\/a><br \/> Once Synaptic Package Manager is open, go to Settings &gt; Repositories. This will open the Software Sources window. <\/p>\n<p> <a href=\"http:\/\/www.psychocats.net\/wpimages\/ntpass05.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.psychocats.net\/wpimages\/ntpass05.png\" width=\"428\" height=\"385\" border=\"0\"><\/a><br \/> Once the Software Sources windows appears, make sure you check (or tick) the box next to <i>Software restricted by copyright or legal issues (multiverse)<\/i>. Then click <i>Close<\/i>. You should get a warning about how you&#8217;ll have to reload the repositories to have your changes take effect. <\/p>\n<p> <a href=\"http:\/\/www.psychocats.net\/wpimages\/ntpass06.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.psychocats.net\/wpimages\/ntpass06.png\" width=\"389\" height=\"276\" border=\"0\"><\/a><br \/> So click <i>Reload<\/i> in Synaptic Package Manager and wait for the new information on what&#8217;s available for installation be updated. <\/p>\n<p>\n<a href=\"http:\/\/www.psychocats.net\/wpimages\/ntpass07.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.psychocats.net\/wpimages\/ntpass07.png\" width=\"348\" height=\"228\" border=\"0\"><\/a><br \/>  Click <i>Search<\/i> and search for <i>chntpw<\/i>. <\/p>\n<p> <a href=\"http:\/\/www.psychocats.net\/wpimages\/ntpass08.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.psychocats.net\/wpimages\/ntpass08.png\" width=\"347\" height=\"296\" border=\"0\"><\/a><br \/> Right-click on <i>chntpw<\/i> and mark it for installation. <\/p>\n<p> <a href=\"http:\/\/www.psychocats.net\/wpimages\/ntpass09.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.psychocats.net\/wpimages\/ntpass09.png\" width=\"445\" height=\"380\" border=\"0\"><\/a><br \/> Click <i>Apply<\/i> and in the Summary window, click <i>Apply<\/i> to confirm that you want to apply changes. <\/p>\n<p> <a href=\"http:\/\/www.psychocats.net\/wpimages\/ntpass10.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.psychocats.net\/wpimages\/ntpass10.png\" width=\"422\" height=\"258\" border=\"0\"><\/a><br \/>\n<a href=\"http:\/\/www.psychocats.net\/wpimages\/ntpass11.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.psychocats.net\/wpimages\/ntpass11.png\" width=\"401\" height=\"219\" border=\"0\"><\/a><br \/> Wait for the changes to apply, then click <i>Close<\/i> and then quit Synaptic Package Manager. <\/p>\n<p> That method for installing <i>chntpw<\/i> assumes you have a working internet connection on the computer in question. If you don&#8217;t (or regularly do, but not when you boot the Ubuntu CD), you can also download <i>chntpw<\/i> from <a href=\"http:\/\/packages.ubuntu.com\/hardy\/i386\/chntpw\/download\">one of these mirrors<\/a>, transfer it to the computer in question (via USB stick), and then double-click the download file to install it. <\/p>\n<p> <a href=\"http:\/\/www.psychocats.net\/wpimages\/ntpass13.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.psychocats.net\/wpimages\/ntpass13.png\" width=\"278\" height=\"359\" border=\"0\"><\/a><br \/> To mount (or make available for use) your Windows drive, go to Places and select the appropriate drive. In this case, my drive is an 8.7 GB drive. Yours will probably be different. <\/p>\n<p> <a href=\"http:\/\/www.psychocats.net\/wpimages\/ntpass12.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.psychocats.net\/wpimages\/ntpass12.png\" width=\"324\" height=\"267\" border=\"0\"><\/a><br \/> Then, go to Applications &gt; Accessories &gt; Terminal to use the command-line.<\/p>\n<div class=\"terminal\">\ncd \/media\/disk\/WINDOWS\/system32\/config\/<\/div>\n<p>\nIn most cases, I think the first mounted drive will mount to the \/media\/disk directory, so pasting this command into the terminal should get you into the right directory. <\/p>\n<p> If not, you can try the command <i>df -h<\/i> to see where your Windows drive mounted to and substitute that directory path for <i>\/media\/disk<\/i> in the above command.<\/p>\n<p> <b>Note for Windows 7<\/b>: the word <i>Windows<\/i> is not in all capital letters, so it would actually be <i>cd \/media\/disk\/Windows\/System32\/config\/<\/i><\/p>\n<p><div class=\"terminal\">ls<br \/>\nAppEvent.Evt  SAM           software      system.LOG     userdiff.LOG<br \/>\ndefault       SAM.LOG       software.LOG  systemprofile<br \/>\ndefault.LOG   SecEvent.Evt  software.sav  system.sav<br \/>\ndefault.sav   SECURITY      SysEvent.Evt  TempKey.LOG<br \/>\nInternet.evt  SECURITY.LOG  system        userdiff\n<\/div>\n<p> If you paste in the command <i>ls<\/i>, you&#8217;ll see a list of files in the directory, and one of them should be called SAM. <\/p>\n<p><div class=\"terminal\">sudo chntpw SAM<\/div>\n<p> Paste in the command <i>sudo chntpw SAM<\/i> to change the Administrator account password.<\/p>\n<p> If, instead, you want to change a particular username&#8217;s password, use this command instead: <\/p>\n<div class=\"terminal\">sudo chntpw -u <i>username<\/i> SAM<\/div>\n<p> Either way, you should see a whole bunch of cryptic terminal output: <\/p>\n<p><div class=\"terminal\">\nchntpw version 0.99.3 040818, (c) Petter N Hagen<br \/>\nHive&#8217;s name (from header):<br \/>\nROOT KEY at offset: 0x001020 * Subkey indexing type is: 666c<br \/>\nPage at 0x7000 is not &#8216;hbin&#8217;, assuming file contains garbage at end<br \/>\nFile size 262144 [40000] bytes, containing 6 pages (+ 1 headerpage)<br \/>\nUsed for data: 243\/19072 blocks\/bytes, unused: 11\/5312 blocks\/bytes.<\/p>\n<p>* SAM policy limits:<br \/>\nFailed logins before lockout is: 0<br \/>\nMinimum password length        : 0<br \/>\nPassword history count         : 0<br \/>\nRID: 01f4, Username:<br \/>\nRID: 03ec, Username:<br \/>\nRID: 01f5, Username: , *disabled or locked*<br \/>\nRID: 03e8, Username: , *disabled or locked*<br \/>\nRID: 03eb, Username:<br \/>\nRID: 03ea, Username: , *disabled or locked*<\/p>\n<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&gt; SYSKEY CHECK  Not Set (not installed, good!)<br \/>\nSAM      Account\\F             : 1 -&gt; key-in-registry<br \/>\nSECURITY PolSecretEncryptionKey: -1 -&gt; Not Set (OK if this is NT4)<\/p>\n<p>***************** SYSKEY IS ENABLED! **************<br \/>\nThis installation very likely has the syskey passwordhash-obfuscator installed<br \/>\nIt&#8217;s currently in mode = -1, Unknown-mode<\/p>\n<p>SYSTEM (and possibly SECURITY) hives not loaded, unable to disable syskey!<br \/>\nPlease start the program with at least SAM &amp; SYSTEM-hive filenames as arguments!<\/p>\n<p>RID     : 0500 [01f4]<br \/>\nUsername: Administrator<br \/>\nfullname:<br \/>\ncomment : Built-in account for administering the computer\/domain<br \/>\nhomedir :<\/p>\n<p>Account bits: 0x0210 =<br \/>\n[ ] Disabled        | [ ] Homedir req.    | [ ] Passwd not req. |<br \/>\n[ ] Temp. duplicate | [X] Normal account  | [ ] NMS account     |<br \/>\n[ ] Domain trust ac | [ ] Wks trust act.  | [ ] Srv trust act   |<br \/>\n[X] Pwd don&#8217;t expir | [ ] Auto lockout    | [ ] (unknown 0x08)  |<br \/>\n[ ] (unknown 0x10)  | [ ] (unknown 0x20)  | [ ] (unknown 0x40)  |<\/p>\n<p>Failed login count: 0, while max tries is: 0<br \/>\nTotal  login count: 0<br \/>\n** LANMAN password not set. User MAY have a blank password.<br \/>\n** Usually safe to continue<\/p>\n<p>* = blank the password (This may work better than setting a new password!)<br \/>\nEnter nothing to leave it unchanged<\/p><\/div>\n<p>\nAt this point, you&#8217;ll be prompted to enter a new password, you should enter an asterisk to make it temporarily blank (you can always change the password to something else once you&#8217;re back in Windows. <\/p>\n<p><div class=\"terminal\"> Please enter new password: *<br \/>\nBlanking password!<\/p>\n<p>Do you really wish to change it? (y\/n) [n] y<br \/>\nChanged!<\/p>\n<p>Hives that have changed:<br \/>\n #  Name<br \/>\n 0<br \/>\nWrite hive files? (y\/n) [n] : y<br \/>\n 0   &#8211; OK\n<\/p><\/div>\n<\/p>\n<p> Confirm the changes (with the letter <i>y<\/i> for <i>yes<\/i>) twice when prompted, and you should be done. <\/p>\n<p> Now if you reboot into Windows XP, you can log into the <i>Administrator<\/i> account with an empty password.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>If you ever have forgotten your password for the only administrative account on Windows or know someone who has, you know the experience can be infuriating. All is not lost, though, if you have a live CD handy. This page is an adaption of Reset a Windows password with Knoppix for Ubuntu. It has also&hellip; <a class=\"more-link\" href=\"https:\/\/www.psychocats.net\/ubuntucat\/resetwindowspasswordold\/\">Continue reading <span class=\"screen-reader-text\">How to reset a Windows password with Ubuntu<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[21,24],"tags":[247,919,368],"class_list":["post-6","post","type-post","status-publish","format-standard","hentry","category-ubuntu","category-windows","tag-password","tag-ubuntu","tag-windows-xp","entry"],"_links":{"self":[{"href":"https:\/\/www.psychocats.net\/ubuntucat\/wp-json\/wp\/v2\/posts\/6","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.psychocats.net\/ubuntucat\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.psychocats.net\/ubuntucat\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.psychocats.net\/ubuntucat\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.psychocats.net\/ubuntucat\/wp-json\/wp\/v2\/comments?post=6"}],"version-history":[{"count":11,"href":"https:\/\/www.psychocats.net\/ubuntucat\/wp-json\/wp\/v2\/posts\/6\/revisions"}],"predecessor-version":[{"id":2250,"href":"https:\/\/www.psychocats.net\/ubuntucat\/wp-json\/wp\/v2\/posts\/6\/revisions\/2250"}],"wp:attachment":[{"href":"https:\/\/www.psychocats.net\/ubuntucat\/wp-json\/wp\/v2\/media?parent=6"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.psychocats.net\/ubuntucat\/wp-json\/wp\/v2\/categories?post=6"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.psychocats.net\/ubuntucat\/wp-json\/wp\/v2\/tags?post=6"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}