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