Virtually all Unix systems require passwords to help ensure that your files and data remain your own and that the system itself is secure from hackers and crackers (malicious hackers). Code Listing 1.1 shows how you change your password.
$ passwd
Changing password for ejr
(current) Unix password:
New UNIX password:
Retype new UNIX password:
passwd: all authentication tokens updated
→ successfully
$
|
The SSH Preferences DialogIn the Preferences dialog, you can fix some of the idiosyncrasies that are caused by how your SSH program talks to the Unix system. You can’t identify these idiosyncrasies until you actually start using your Unix system, but you should remember that you can fix most problems here. For example:
Exactly which options you’ll have will vary from program to program, but these are ones that are commonly available. Click OK when you’re done playing with the settings. |
Throughout your Unix adventure, you’ll likely change your password often:
You’ll probably want to change the password provided by your system administrator after you log in for the first time. Hint, hint.
You’ll probably change your password at regular intervals. Many Unix systems require that you change your password every so often—every 30 or 60 days is common.
You might also change your password voluntarily if you think that someone might have learned it or if you tell anyone your password (although you really shouldn’t do that anyway).
1. | passwd To start, type passwd. |
2. | youroldpassword Enter your old password—the one you’re currently using. (Of course, type in your old password, not the sample one we’ve used here!) Note that the password doesn’t show up onscreen when you type it, in case someone is lurking over your shoulder, watching you type, and asking, “whatcha doing?” |
3. | |
4. | yournewpassword Here, you’re verifying the password by typing it again. The system will report that your password was successfully changed (specific terminology depends on the system) after the changes take effect. This is also shown in Code Listing 1.1. |
✓ Tips
Double-check your new password before you log out of the system by typing su - yourid at the prompt. Of course, substitute your real username (or login name) for yourid here. This command (switch user) lets you log in again without having to log out, so if you made a mistake when changing your password and now get a failed login message, you can find out before you actually disconnect from the system. If you have problems, contact your system administrator before you log out so you can get the problem resolved.
In some environments, you will use yppasswd, not passwd, to change your password, or even use a Web page or other means. When in doubt, defer to what your system administrator told you to do. (“The Rays said to use this other command” is likely to get all of us in trouble.)
The Lowdown on PasswordsIn addition to following any password guidelines your system administrator mandates, you should choose a password that is
|