1
# bash completion for heimdal
7
COMPREPLY=( $( compgen -W "$( kadmin -l dump 2>/dev/null | \
8
awk '{print $1}' )" -- "$cur" ) )
14
COMPREPLY=( $( compgen -W "( kadmin -l dump 2>/dev/null | \
15
awk '{print $1}' | awk -F@ '{print $2}' )" -- "$cur" ) )
21
COMPREPLY=( $( compgen -W 'des-cbc-mcrc des-cbc-md4 des-cbc-md5 \
22
des3-cbc-sha1 arcfour-hmac-md5 aes128-cts-hmac-sha1-96 \
23
aes256-cts-hmac-sha1-96' -- "$cur" ) )
28
local cur prev command options split=false
31
_get_comp_words_by_ref cur prev
33
_split_longopt && split=true
45
_known_hosts_real "$cur"
52
-s|-k|--srvtab|--keytab)
60
commands='add change copy get list remove rename purge srvconvert \
61
srv2keytab srvcreate key2srvtab'
63
for (( i=1; i < COMP_CWORD; i++ )); do
64
case ${COMP_WORDS[i]} in
71
command=${COMP_WORDS[i]}
77
if [[ "$cur" == -* ]]; then
80
options='-p --principal -V -e --enctype -w --password -r \
81
--random -s --no-salt -h --hex'
84
options='-r --realm -a --admin-server -s --server-port'
87
options='-p --principal -e --enctype -r --realm -a \
88
--admin-server -s server --server-port'
91
options='--keys --timestamp'
94
options='-p --principal -V --kvno -e --enctype'
99
srv2keytab|key2srvtab)
100
options='-s --srvtab'
103
options='-k --keytab -v --verbose --version -v --help'
106
COMPREPLY=( $( compgen -W "$options" -- "$cur" ) )
119
COMPREPLY=( $( compgen -W "$commands" -- "$cur" ) )
124
complete -F _ktutil ktutil
130
# sh-indent-comment: t
131
# indent-tabs-mode: nil
133
# ex: ts=4 sw=4 et filetype=sh