diff options
author | Tom Yu <tlyu@mit.edu> | 2005-02-11 23:09:25 +0000 |
---|---|---|
committer | Tom Yu <tlyu@mit.edu> | 2005-02-11 23:09:25 +0000 |
commit | 5cfaec38a8e8f1c4b76228ba0a252987af797ca4 (patch) | |
tree | 14fb66ce4a11aa36644edcc845c2542ddfbfafda /src/tests | |
parent | a585481363f5e7dd50229dd10f8756d5db887fac (diff) | |
download | krb5-5cfaec38a8e8f1c4b76228ba0a252987af797ca4.tar.gz krb5-5cfaec38a8e8f1c4b76228ba0a252987af797ca4.tar.xz krb5-5cfaec38a8e8f1c4b76228ba0a252987af797ca4.zip |
Implement principal name and auth flavor fallback for kadm5 client
library. Adjust test suites to compensate.
ticket: 2913
status: open
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@17099 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/tests')
-rw-r--r-- | src/tests/dejagnu/krb-standalone/ChangeLog | 7 | ||||
-rw-r--r-- | src/tests/dejagnu/krb-standalone/kadmin.exp | 14 |
2 files changed, 19 insertions, 2 deletions
diff --git a/src/tests/dejagnu/krb-standalone/ChangeLog b/src/tests/dejagnu/krb-standalone/ChangeLog index 8e0e4470d9..5817ad3b50 100644 --- a/src/tests/dejagnu/krb-standalone/ChangeLog +++ b/src/tests/dejagnu/krb-standalone/ChangeLog @@ -1,3 +1,10 @@ +2005-02-10 Tom Yu <tlyu@mit.edu> + + * kadmin.exp (kadmin_add_rnd): Add "flags" arg, defaulting to + empty string. + (kadmin_test): Add test for fallback to kadmin/admin if + kadmin/fqdn is missing. + 2005-01-14 Tom Yu <tlyu@mit.edu> * kadmin.exp (kadmin_list): Check for communication failure. diff --git a/src/tests/dejagnu/krb-standalone/kadmin.exp b/src/tests/dejagnu/krb-standalone/kadmin.exp index c72548114f..e3e39168db 100644 --- a/src/tests/dejagnu/krb-standalone/kadmin.exp +++ b/src/tests/dejagnu/krb-standalone/kadmin.exp @@ -128,7 +128,7 @@ proc kadmin_add { pname password } { # # Adds principal $pname with random key. Returns 1 on success. #-- -proc kadmin_add_rnd { pname } { +proc kadmin_add_rnd { pname { flags "" } } { global REALMNAME global KADMIN global KADMIN_LOCAL @@ -137,7 +137,7 @@ proc kadmin_add_rnd { pname } { global tmppwd set good 0 - spawn $KADMIN -p krbtest/admin@$REALMNAME -q "ank -randkey $pname" + spawn $KADMIN -p krbtest/admin@$REALMNAME -q "ank -randkey $flags $pname" expect_after { "Cannot contact any KDC" { fail "kadmin add rnd $pname lost KDC" @@ -952,6 +952,7 @@ proc kdestroy { } { # we get some sort of error. proc kadmin_test { } { + global hostname # Start up the kerberos and kadmind daemons if {![start_kerberos_daemons 0] } { @@ -1049,6 +1050,15 @@ proc kadmin_test { } { if { ![kadmin_list] } { return } + + # test fallback to kadmin/admin + if {![kadmin_delete kadmin/$hostname] \ + || ![kadmin_list] \ + || ![kadmin_add_rnd kadmin/$hostname -allow_tgs_req] \ + || ![kadmin_list]} { + return + } + verbose "kadmin_test succeeded" } |