auth: fix cellservdb update check
[openafs.git] / doc / man-pages / pod8 / bos_addkey.pod
1 =head1 NAME
2
3 bos_addkey - Adds a new server encryption key to the KeyFile file
4
5 =head1 SYNOPSIS
6
7 =for html
8 <div class="synopsis">
9
10 B<bos addkey> S<<< B<-server> <I<machine name>> >>> S<<< [B<-key> <I<key>>] >>>
11     S<<< B<-kvno> <I<key version number>> >>> S<<< [B<-cell> <I<cell name>>] >>>
12     [B<-noauth>] [B<-localauth>] [B<-help>]
13
14 B<bos addk> S<<< B<-s> <I<machine name>> >>> S<<< [B<-ke> <I<key>>] >>>
15     S<<< B<-kv> <I<key version number>> >>> S<<< [B<-ce> <I<cell name>>] >>> [B<-n>]
16     [B<-l>] [B<-h>]
17
18 =for html
19 </div>
20
21 =head1 DESCRIPTION
22
23 The B<bos addkey> command constructs a server encryption key from the text
24 string provided, assigns it the key version number specified with the
25 B<-kvno> argument, and adds it to the F</usr/afs/etc/KeyFile> file on the
26 machine specified with the B<-server> argument.
27
28 Normally, B<asetkey add> should be used instead of this command; see
29 L<asetkey(8)> for more details. The primary use of B<bos addkey> is for
30 cells that are still using the Authentication Server instead of a Kerberos
31 v5 KDC. It may, however, also be useful in unusual circumstances where a
32 key needs to be added based on a known password rather than via a Kerberos
33 v5 keytab.
34
35 When using B<bos addkey> with an AFS cell that uses the Authentication
36 Server, be sure to use the B<kas setpassword> or B<kas setkey> command to
37 add the same key to the C<afs> entry in the Authentication Database.
38
39 Do not use the B<-key> argument, which echoes the password string visibly
40 on the screen. If the argument is omitted, the BOS Server prompts for the
41 string and does not echo it visibly:
42
43    Input key:
44    Retype input key:
45
46 The BOS Server prohibits reuse of any key version number already listed in
47 the F</usr/afs/etc/KeyFile> file. This ensures that users who still have
48 tickets sealed with the current key are not prevented from communicating
49 with a server process because the current key is overwritten with a new
50 key. Use the B<bos listkeys> command to display the key version numbers in
51 the F</usr/afs/etc/KeyFile> file.
52
53 =head1 CAUTIONS
54
55 In the unusual case of using B<bos addkey> to add a key with a known
56 password matching a password used to generate Kerberos v5 keys, the key in
57 the Kerberos v5 KDC database must have only the DES encryption type and
58 must use C<afs3> salt, not the default Kerberos v5 salt. Otherwise, the
59 key generated by B<bos addkey> will not match the key generated by the
60 Kerberos v5 KDC.
61
62 =head1 OPTIONS
63
64 =over 4
65
66 =item B<-server> <I<machine name>>
67
68 Indicates the server machine on which to change the
69 F</usr/afs/etc/KeyFile> file. Identify the machine by IP address or its
70 host name (either fully-qualified or abbreviated unambiguously). For
71 details, see L<bos(8)>.
72
73 In cells that use the Update Server to distribute the contents of the
74 F</usr/afs/etc> directory, it is conventional to specify only the system
75 control machine as a value for the B<-server> argument. Otherwise, repeat
76 the command for each file server machine. For further discussion, see
77 L<bos(8)>.
78
79 =item B<-key> <I<key>>
80
81 Specifies a character string just like a password; the BOS Server calls a
82 DES conversion function to encode it into a form appropriate for use as an
83 encryption key. Omit this argument to have the BOS Server prompt for the
84 string instead.
85
86 =item B<-kvno> <I<key version number>>
87
88 Defines the new key's key version number. It must be an integer in the
89 range from C<0> (zero) through C<255>.  For the sake of simplicity, use
90 the number one higher than the current highest key version number; use the
91 B<bos listkeys> command to display key version numbers.
92
93 =item B<-cell> <I<cell name>>
94
95 Names the cell in which to run the command. Do not combine this argument
96 with the B<-localauth> flag. For more details, see L<bos(8)>.
97
98 =item B<-noauth>
99
100 Assigns the unprivileged identity C<anonymous> to the issuer. Do not combine
101 this flag with the B<-localauth> flag. For more details, see L<bos(8)>.
102
103 =item B<-localauth>
104
105 Constructs a server ticket using a key from the local
106 F</usr/afs/etc/KeyFile> file. The B<bos> command interpreter presents the
107 ticket to the BOS Server during mutual authentication. Do not combine this
108 flag with the B<-cell> or B<-noauth> options. For more details, see
109 L<bos(8)>.
110
111 =item B<-help>
112
113 Prints the online help for this command. All other valid options are
114 ignored.
115
116 =back
117
118 =head1 OUTPUT
119
120 If the strings typed at the C<Input key> and C<Retype input key> prompts
121 do not match, the following message appears, and the command exits without
122 adding a new key:
123
124    Input key mismatch
125
126 =head1 EXAMPLES
127
128 The following command adds a new server encryption key with key version
129 number 14 to the B<KeyFile> file kept on the machine C<fs1.example.com> (the
130 system control machine). The issuer omits the B<-key> argument, as
131 recommended, and provides the password at the prompts.
132
133    % bos addkey -server fs1.example.com -kvno 14
134    Input key:
135    Retype input key:
136
137 =head1 PRIVILEGE REQUIRED
138
139 The issuer must be listed in the F</usr/afs/etc/UserList> file on the
140 machine named by the B<-server> argument, or must be logged onto a server
141 machine as the local superuser C<root> if the B<-localauth> flag is
142 included.
143
144 =head1 SEE ALSO
145
146 L<KeyFile(5)>,
147 L<UserList(5)>,
148 L<asetkey(8)>,
149 L<bos(8)>,
150 L<bos_listkeys(8)>,
151 L<bos_removekey(8)>
152
153 =head1 COPYRIGHT
154
155 IBM Corporation 2000. <http://www.ibm.com/> All Rights Reserved.
156
157 This documentation is covered by the IBM Public License Version 1.0.  It
158 was converted from HTML to POD by software written by Chas Williams and
159 Russ Allbery, based on work by Alf Wachsmann and Elizabeth Cassell.