2 * Copyright (c) 2004 - 2007 Kungliga Tekniska Högskolan
3 * (Royal Institute of Technology, Stockholm, Sweden).
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
10 * 1. Redistributions of source code must retain the above copyright
11 * notice, this list of conditions and the following disclaimer.
13 * 2. Redistributions in binary form must reproduce the above copyright
14 * notice, this list of conditions and the following disclaimer in the
15 * documentation and/or other materials provided with the distribution.
17 * 3. Neither the name of the Institute nor the names of its contributors
18 * may be used to endorse or promote products derived from this software
19 * without specific prior written permission.
21 * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
22 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24 * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE
25 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
42 help = "encryption type"
43 default = "des3-cbc-sha1"
50 help = "master key file"
55 help = "just convert keyfile to new format"
58 long = "random-password"
60 help = "use a random password (and print the password to stdout)"
63 long = "master-key-fd"
66 help = "filedescriptor to read passphrase from"
69 help = "Writes the Kerberos master key to a file used by the KDC. \nLocal (-l) mode only."
83 help = "dump format, mit or heimdal (default: heimdal)"
85 argument = "[dump-file]"
88 help = "Dumps the database in a human readable format to the specified file, \nor the standard out. Local (-l) mode only."
94 long = "realm-max-ticket-life"
96 help = "realm max ticket lifetime"
99 long = "realm-max-renewable-life"
101 help = "realm max renewable lifetime"
106 help = "only create krbtgt for realm"
108 argument = "realm..."
110 help = "Initializes the default principals for a realm. Creates the database\nif necessary. Local (-l) mode only."
117 help = "Loads a previously dumped file. Local (-l) mode only."
124 help = "Merges the contents of a dump file into the database. Local (-l) mode only."
130 function = "add_new_key"
135 help = "set random key"
138 long = "random-password"
140 help = "set random password"
146 help = "encryption type(s)"
152 help = "principal's password"
157 help = "DES-key in hex"
160 long = "max-ticket-life"
163 help = "max ticket lifetime"
166 long = "max-renewable-life"
168 argument = "lifetime"
169 help = "max renewable life"
174 argument = "attributes"
175 help = "principal attributes"
178 long = "expiration-time"
181 help = "principal expiration time"
184 long = "pw-expiration-time"
187 help = "password expiration time"
190 long = "hist-kvno-diff-clnt"
192 argument = "kvno diff"
193 help = "historic keys allowed for client"
197 long = "hist-kvno-diff-svc"
199 argument = "kvno diff"
200 help = "historic keys allowed for service"
204 long = "use-defaults"
206 help = "use default values"
214 argument = "principal..."
216 help = "Adds a principal to the database."
219 name = "add_namespace"
221 function = "add_new_namespace"
226 help = "encryption type(s)"
229 long = "max-ticket-life"
232 help = "max ticket lifetime"
235 long = "max-renewable-life"
237 argument = "lifetime"
238 help = "max renewable life"
241 long = "key-rotation-epoch"
244 help = "absolute start time (or +timespec for relative to now with default unit of month)"
247 long = "key-rotation-period"
250 help = "automatic key rotation period"
255 argument = "attributes"
256 help = "principal attributes"
258 argument = "principal..."
260 help = "Adds a namespace of virtual principals with derived keys to the database."
263 name = "modify_namespace"
265 function = "modify_namespace"
270 help = "encryption type(s)"
273 long = "max-ticket-life"
276 help = "max ticket lifetime"
279 long = "max-renewable-life"
281 argument = "lifetime"
282 help = "max renewable life"
287 argument = "attributes"
288 help = "principal attributes"
291 long = "krb5-config-file"
294 help = "filename to save the principal's krb5.confg in"
296 argument = "principal..."
298 help = "Modifies a namespace of virtual principals with derived keys to the database."
301 name = "modify_namespace_key_rotation"
303 function = "modify_ns_kr"
308 help = "change schedule even if it would revoke some extant tickets"
311 long = "keep-base-key"
314 help = "keep current base key for new key rotation schedule"
321 help = "delete base keys older than this to revoke old tickets"
324 long = "new-key-rotation-epoch"
327 help = "new start time relative to now"
330 long = "new-key-rotation-period"
333 help = "new automatic key rotation period"
335 argument = "principal..."
338 help = "Adds or changes new key rotation schedule for the given namespace."
343 name = "change_password"
344 function = "cpw_entry"
349 help = "set random key"
352 long = "random-password"
354 help = "set random password"
360 help = "encryption type(s)"
366 help = "principal's password"
371 help = "DES key in hex"
376 help = "keep old keys/password needed to decrypt extant tickets (default)"
381 help = "keep all old keys/password"
386 help = "delete all old keys"
388 argument = "principal..."
390 help = "Changes the password of one or more principals matching the expressions."
396 function = "del_entry"
397 argument = "principal..."
399 help = "Deletes all principals matching the expressions."
402 name = "delete_namespace"
404 function = "del_namespace"
405 argument = "principal..."
407 help = "Deletes the given virtual principal namespaces"
411 argument = "principal enctype..."
413 help = "Delete all the mentioned enctypes for principal."
421 help = "set random key"
423 argument = "principal enctype..."
425 help = "Add new enctypes for principal."
433 help = "keytab to use"
440 help = "set random key"
446 help = "encryption type(s)"
451 help = "keep old keys/password needed to decrypt extant tickets (default)"
456 help = "keep all old keys/password"
461 help = "delete all old keys"
463 argument = "principal..."
465 help = "Extracts the keys of all principals matching the expressions, and stores them in a keytab."
470 function = "get_entry"
471 /* Options added to list should be added here; not the reverse */
483 help = "short format"
489 help = "terse format"
495 help = "columns to print for short output"
498 long = "krb5-config-file"
501 help = "filename to save the principal's krb5.conf in"
507 help = "maximum number of principals to get/list"
509 argument = "principal..."
511 help = "Shows information about principals matching the expressions."
515 function = "rename_entry"
519 help = "Renames a principal."
524 function = "mod_entry"
526 long = "max-ticket-life"
529 help = "max ticket lifetime"
532 long = "max-renewable-life"
534 argument = "lifetime"
535 help = "max renewable life"
541 argument = "attributes"
542 help = "principal attributes"
545 long = "expiration-time"
548 help = "principal expiration time"
551 long = "pw-expiration-time"
554 help = "password expiration time"
559 help = "key version number"
563 long = "constrained-delegation"
565 argument = "principal"
566 help = "allowed target principals"
571 argument = "principal"
577 argument = "subject dn"
587 long = "service-enctypes"
591 help = "set enctypes supported by service"
594 long = "hist-kvno-diff-clnt"
596 argument = "kvno diff"
597 help = "historic keys allowed for client"
601 long = "hist-kvno-diff-svc"
603 argument = "kvno diff"
604 help = "historic keys allowed for service"
608 long = "krb5-config-file"
611 help = "krb5.conf to save in principal record"
613 argument = "principal"
616 help = "Modifies some attributes of the specified principal."
620 function = "add_alias"
621 argument = "principal"
623 help = "Add one or more aliases to the given principal."
627 function = "del_alias"
628 argument = "principal"
630 help = "Delete one or more aliases without deleting their canonical principals."
634 argument = "principal"
638 help = "key version number"
643 help = "Delete keys from history by max-ticket-life or kvno."
648 function = "get_privs"
649 help = "Shows which operations you are allowed to perform."
653 function = "list_princs"
654 /* XXX sync options with "get" */
665 help = "short format"
671 help = "terse format"
678 help = "columns to print for short output"
681 long = "krb5-config-file"
683 help = "only use this option with the get command"
689 help = "maximum number of principals to get/list"
691 argument = "principal..."
693 help = "Lists principals in a terse format. Equivalent to \"get -t\"."
696 name = "verify-password-quality"
698 function = "password_quality"
699 argument = "principal password"
702 help = "Try run the password quality function locally (not doing RPC out to server)."
710 help = "Check the realm (if not given, the default realm) for configuration errors."
718 help = "Lock the database for writing (use with care)."
726 help = "Unlock the database."
731 argument = "[command]"
734 help = "Help! I need somebody."
739 function = "exit_kadmin"