© photo
Sometimes it happens that you need to log in, password-protected. And this does not mean that you are a cunning spy-terrorist planning and steal the overarching information, although it is possible and such. In any case, your too forgetful boyfriend or girlfriend may forget your password, and access to a Mac need oh how urgently. What to do? There are 2 easy ways to break into the system to bypass the password.
1. Mac OS X Installer
If you have the installation CD, while Mac has a floppy drive, then reset the administrator password is very simple. By the way, if the drive is not present, it is necessary to think over everything in advance and make a bootable USB flash drive for our instruction. So, insert the disc into the Mac and hold down the «c» in the computer's boot time. You will see the installer Mac OS X. Go to the Utilities and choose Password Reset. Next, the installer prompts you to select the drive on which the system is installed, as well as the user for which you want to reset your password. If you have the installer Mountain Lion, the menu does not have to choose Utilities, and Terminal. Then enter «resetpassword» and press the «Enter», and then reset the password menu will appear.
We can only enter a new password for the selected user and click the save button. Voila! After reboot, you can use the new password.
2. Single User Mode
If the boot drive is not and get it not at all impossible, and get into your Mac like right now, you'll have to do miracles from the command line in the world. Turn on the computer and hold key combination Command + S. Mac to boot into Single User mode, and it will be available for the console. If you have Snow Leopard or below, then type the following (after each line we press Enter):
/ Sbin / fsck -fy
/ Sbin / mount -uw /
launchctl load /System/Library/LaunchDaemons/com.apple. DirectoryServices.plist
dscl. -passwd / Users / username parol_polzovatelya
If there is a Lion or later, you need to write the following:
/ Sbin / fsck -fy
/ Sbin / mount -uw /
launchctl load /System/Library/LaunchDaemons/com.apple.opendirectoryd.plist
dscl. -passwd / Users / username parol_polzovatelya
Replace "username" in the name of the user whose password you want to reset, and "parol_polzovatelya" to the password you want to assign to this user. If Lion or Mountain Lion you get an error regarding com.apple. DirectoryServicesLocal.plist, then do not worry. Reset all work the same.
If you forget not only the password, but also a user name (anything can happen) then just type in console «ls / Users» and a list of folders will match the user names on that Mac. Will only recognize yourself in this list.
Protection from the methods described above
As can be seen from the above, all of these passwords does not mean absolutely nothing, and if a person strongly wants, he will climb into your Mac. However, if you encrypt your hard drive, including FileVault to System Preferences -> Security, then reset the password will not be released.
For even better protection should install Firmware Password. Boot from the installer and go to the Utilities -> Firmware Password Utility. This method does not allow the download Mac from another hard drive or boot, and will not allow the boot into Single User Mode.
Of course, there are ways around these security measures, but it is unlikely anyone would spend time on it, unless your Mac is not stored prescription drugs for AIDS, cancer and bad sense of humor.
[via LH]