1PASSWD(1)                       User utilities                       PASSWD(1)
2
3
4

NAME

6       passwd - update user's authentication tokens
7
8

SYNOPSIS

10       passwd  [-k]  [-l]  [-u  [-f]]  [-d] [-e] [-n mindays] [-x maxdays] [-w
11       warndays] [-i inactivedays] [-S] [--stdin] [username]
12
13
14

DESCRIPTION

16       The passwd utility is used to update user's authentication token(s).
17
18       This task is achieved through calls to the Linux-PAM and  Libuser  API.
19       Essentially, it initializes itself as a "passwd" service with Linux-PAM
20       and utilizes configured  password  modules  to  authenticate  and  then
21       update a user's password.
22
23
24       A simple entry in the global Linux-PAM configuration file for this ser‐
25       vice would be:
26
27        #
28        # passwd service entry that does strength checking of
29        # a proposed password before updating it.
30        #
31        passwd password requisite pam_cracklib.so retry=3
32        passwd password required pam_unix.so use_authtok
33        #
34
35
36       Note, other module types are not required for this application to func‐
37       tion correctly.
38
39

OPTIONS

41       -k     The  option  -k, is used to indicate that the update should only
42              be for  expired  authentication  tokens  (passwords);  the  user
43              wishes to keep their non-expired tokens as before.
44
45
46       -l     This  option  is  used  to  lock the specified account and it is
47              available to root only. The locking is  performed  by  rendering
48              the  encrypted password into an invalid string (by prefixing the
49              encrypted string with an !).
50
51
52       --stdin
53              This option is used to indicate that passwd should read the  new
54              password from standard input, which can be a pipe.
55
56
57       -u     This  is  the  reverse  of  the  -l  option - it will unlock the
58              account password by removing the ! prefix. This option is avail‐
59              able  to  root  only.  By default passwd will refuse to create a
60              passwordless account (it will not unlock  an  account  that  has
61              only  "!" as a password). The force option -f will override this
62              protection.
63
64
65       -d     This is a quick way to delete a password for an account. It will
66              set the named account passwordless. Available to root only.
67
68
69       -e     This  is  a  quick  way to expire a password for an account. The
70              user will be forced to change the password during the next login
71              attempt.  Available to root only.
72
73
74       -n     This  will  set  the  minimum password lifetime, in days, if the
75              user's account supports password lifetimes.  Available  to  root
76              only.
77
78
79       -x     This  will  set  the  maximum password lifetime, in days, if the
80              user's account supports password lifetimes.  Available  to  root
81              only.
82
83
84       -w     This  will set the number of days in advance the user will begin
85              receiving warnings that her password will expire, if the  user's
86              account supports password lifetimes.  Available to root only.
87
88
89       -i     This  will  set  the  number  of  days which will pass before an
90              expired password for this account will be taken to mean that the
91              account  is  inactive  and  should  be  disabled,  if the user's
92              account supports password lifetimes.  Available to root only.
93
94
95       -S     This will output a short information about  the  status  of  the
96              password for a given account. Available to root user only.
97
98

Remember the following two principles

100       Protect your password.
101              Don't  write  down  your password - memorize it.  In particular,
102              don't write it down and leave it anywhere, and don't place it in
103              an  unencrypted  file!  Use unrelated passwords for systems con‐
104              trolled by different organizations.  Don't give  or  share  your
105              password,  in particular to someone claiming to be from computer
106              support or a vendor.  Don't let  anyone  watch  you  enter  your
107              password.   Don't  enter  your  password to a computer you don't
108              trust or if things Use the  password  for  a  limited  time  and
109              change it periodically.
110
111
112       Choose a hard-to-guess password.
113              passwd through the calls to the pam_cracklib PAM module will try
114              to prevent you from choosing a really bad password, but it isn't
115              foolproof;  create  your  password  wisely.  Don't use something
116              you'd find in a dictionary (in any language or  jargon).   Don't
117              use a name (including that of a spouse, parent, child, pet, fan‐
118              tasy character, famous person, and location) or any variation of
119              your personal or account name.  Don't use accessible information
120              about you (such as your phone number, license plate,  or  social
121              security number) or your environment.  Don't use a birthday or a
122              simple pattern (such as backwards, followed by a digit, or  pre‐
123              ceded by a digit. Instead, use a mixture of upper and lower case
124              letters, as well as digits or punctuation.  When choosing a  new
125              password, make sure it's unrelated to any previous password. Use
126              long passwords (say at least 8 characters long).  You might  use
127              a  word  pair with punctuation inserted, a passphrase (an under‐
128              standable sequence of words), or the first letter of  each  word
129              in a passphrase.
130
131
132
133       These  principles are partially enforced by the system, but only partly
134       so.  Vigilence on your part will make the system much more secure.
135
136

EXIT CODE

138       On successful completion of its task, passwd will  complete  with  exit
139       code 0.  An exit code of 1 indicates an error occurred.  Textual errors
140       are written to the standard error stream.
141
142

CONFORMING TO

144       Linux-PAM (Pluggable Authentication modules for Linux).
145
146

FILES

148       /etc/pam.d/passwd - the Linux-PAM configuration file
149
150

BUGS

152       None known.
153
154

SEE ALSO

156       pam(8), pam.d(5), libuser.conf(5), and pam_chauthtok(3).
157
158
159       For more complete information on how to configure this application with
160       Linux-PAM, see the Linux-PAM System Administrators' Guide.
161
162

AUTHOR

164       Cristian Gafton <gafton@redhat.com>
165
166
167
168GNU/Linux                         Jan 26 2012                        PASSWD(1)
Impressum