KTUTIL(1) | User Commands | KTUTIL(1) |
ktutil - Kerberos keytab maintenance utility
/usr/bin/ktutil
The ktutil command is an interactive command-line interface utility for managing the keylist in keytab files. You must read in a keytab's keylist before you can manage it. Also, the user running the ktutil command must have read/write permissions on the keytab. For example, if a keytab is owned by root, which it typically is, ktutil must be run as root to have the appropriate permissions.
clear_list
clear
read_kt file
rkt file
write_kt file
wkt file
add_entry number
addent number
delete_entry number
delent number
list
l
list_request
lr
quit
exit
q
Example 1 Deleting a principal from a file
The following example deletes the host/denver@EXAMPLE.com principal from the /etc/krb5/krb5.keytab file. Notice that if you want to delete an entry from an existing keytab, you must first write the keylist to a temporary keytab and then overwrite the existing keytab with the temporary keytab. This is because the wkt command actually appends the current keylist to an existing keytab, so you can't use it to overwrite a keytab.
example# /usr/krb5/bin/ktutil
ktutil: rkt /etc/krb5/krb5.keytab
ktutil: list slot KVNO Principal ---- ---- ---------------------------------------
1 8 host/vail@EXAMPLE.COM
2 5 host/denver@EXAMPLE.COM
ktutil:delent 2
ktutil:l slot KVNO Principal ---- ---- --------------------------------------
1 8 host/vail@EXAMPLE.COM
ktutil:wkt /tmp/krb5.keytab
ktutil:q example# mv /tmp/krb5.keytab /etc/krb5/krb5.keytab
/etc/krb5/krb5.keytab
See attributes(7) for descriptions of the following attributes:
ATTRIBUTE TYPE | ATTRIBUTE VALUE |
Interface Stability | See below. |
The command arguments are Evolving. The command output is Unstable.
November 22, 2021 | OmniOS |