- How To Reset The Password For Macbook
- How To Change The Admin Password For Mac
- How To Change The Password For Mac
Open Keychain Access from Finder Applications Utilities, and choose Keychain Access. For you to change Keychain password Mac, you have to change login password. Enter old password and then change it to new password. If the Keychain password is same as the login password then it will also change else Keychain password will remain unchanged. Now if an administrator tries to change your login password in order to change Keychain. Choose Apple menu System Preferences, then click Apple ID. Click Password & Security. If you're asked to enter your Apple ID password, click 'Forgot Apple ID or password' and follow the onscreen instructions. You can skip the final steps below. Click Change Password. Reset password with Apple ID. If you have an Apple ID tied to your user account on Mac, you can use it to reset password from the login window. The option should be available by default. Otherwise, you can enable it in System Preferences Users & Groups Allows user to reset password using Apple ID.
Update May, 2019
Now that there are SecureToken users, the command below no longer works to reset another user's password. Thanks to mario on the MacAdmins Slack for testing.
Acknowledgements
Just a cleaned-up version of directions from Mac Script to change Administrator password
Changing a user password via terminal command
If you ever want to—perhaps for scripting purposes?—change a user's password from the command-line (despite what it says in the link above, you don't have to be logged in as the user to change the user's password, but you do have to be logged in as an admin user), these are the commands you'd use:
sudo security set-keychain-password -o oldpassword -p newpassword /Users/username/Library/Keychains/login.keychain
How To Reset The Password For Macbook
If you don't know the old password..
If, for some reason, you (and the user both) have forgotten the user's old password and don't want to deal with keychains issues, you can also just delete the existing keychain (instead of running the second command to update the keychain password):
Security issues
One strong caveat is that the terminal, by default, will save commands to ~/.bash_history in plain text, so you're essentially storing a user's password in plain text, unless you temporarily disable bash history or later go into the ~/.bash_history file with a text editor (like nano) and delete the offending lines manually.
If you distribute this as part of a .pkg, nothing will be visible in a .bash_history file, but make sure you keep that .pkg extra secure or delete it after deploying it.
Related
Keychain Access User Guide
How To Change The Admin Password For Mac
Your login keychain password is normally the same as your user password (the password you use to log in to the computer). At login, if your keychain password somehow differs from your user password, it doesn't automatically unlock, and you're asked to enter the keychain's password. It's recommended that you enter your previous user password. If this doesn't unlock the keychain, the keychain automatically resets.
If you don't remember your previous user password, you need to reset your default keychain. Resetting the default keychain deletes all the passwords saved in the keychain, but lets you sync your login password and the password stored in the keychain.
How To Change The Password For Mac
To do this, change your password in Users & Groups preferences, and the keychain password is automatically changed to match it.
It's recommended that you manually reset your keychain only when advised to by Apple Support. Resetting default keychains requires you to log out and log back in to your Mac to complete the process.
In the Keychain Access app on your Mac, choose Keychain Access > Preferences.
Click Reset Default Keychains.
In the Finder on your Mac, choose Apple menu > Log Out. When you log in again, save your current login password in a keychain.
If your user password was reset because you forgot your password, and you can't provide the old password for the keychain, you won't be able to access the information in the old keychain, and a new blank keychain is created.
Now that there are SecureToken users, the command below no longer works to reset another user's password. Thanks to mario on the MacAdmins Slack for testing.
Acknowledgements
Just a cleaned-up version of directions from Mac Script to change Administrator password
Changing a user password via terminal command
If you ever want to—perhaps for scripting purposes?—change a user's password from the command-line (despite what it says in the link above, you don't have to be logged in as the user to change the user's password, but you do have to be logged in as an admin user), these are the commands you'd use:
sudo security set-keychain-password -o oldpassword -p newpassword /Users/username/Library/Keychains/login.keychain
How To Reset The Password For Macbook
If you don't know the old password..
If, for some reason, you (and the user both) have forgotten the user's old password and don't want to deal with keychains issues, you can also just delete the existing keychain (instead of running the second command to update the keychain password):
Security issues
One strong caveat is that the terminal, by default, will save commands to ~/.bash_history in plain text, so you're essentially storing a user's password in plain text, unless you temporarily disable bash history or later go into the ~/.bash_history file with a text editor (like nano) and delete the offending lines manually.
If you distribute this as part of a .pkg, nothing will be visible in a .bash_history file, but make sure you keep that .pkg extra secure or delete it after deploying it.
Related
Keychain Access User Guide
How To Change The Admin Password For Mac
Your login keychain password is normally the same as your user password (the password you use to log in to the computer). At login, if your keychain password somehow differs from your user password, it doesn't automatically unlock, and you're asked to enter the keychain's password. It's recommended that you enter your previous user password. If this doesn't unlock the keychain, the keychain automatically resets.
If you don't remember your previous user password, you need to reset your default keychain. Resetting the default keychain deletes all the passwords saved in the keychain, but lets you sync your login password and the password stored in the keychain.
How To Change The Password For Mac
To do this, change your password in Users & Groups preferences, and the keychain password is automatically changed to match it.
It's recommended that you manually reset your keychain only when advised to by Apple Support. Resetting default keychains requires you to log out and log back in to your Mac to complete the process.
In the Keychain Access app on your Mac, choose Keychain Access > Preferences.
Click Reset Default Keychains.
In the Finder on your Mac, choose Apple menu > Log Out. When you log in again, save your current login password in a keychain.
If your user password was reset because you forgot your password, and you can't provide the old password for the keychain, you won't be able to access the information in the old keychain, and a new blank keychain is created.