From becaa9d9f9263e828cbf5b47dcb4d817970b436b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Love=20H=C3=B6rnquist=20=C3=85strand?= Date: Sat, 26 Jul 2008 18:38:14 +0000 Subject: [PATCH] check client code git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23421 ec53bebd-3082-4978-b11e-865c3cabbd6b --- tests/gss/check-context.in | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/tests/gss/check-context.in b/tests/gss/check-context.in index 14061043d..b83a8a367 100644 --- a/tests/gss/check-context.in +++ b/tests/gss/check-context.in @@ -51,6 +51,7 @@ cache="FILE:krb5ccfile" kinit="${TESTS_ENVIRONMENT} ../../kuser/kinit -c $cache --no-afslog" klist="${TESTS_ENVIRONMENT} ../../kuser/klist -c $cache" +kgetcred="${TESTS_ENVIRONMENT} ../../kuser/kgetcred -c $cache" kadmin="${TESTS_ENVIRONMENT} ../../kadmin/kadmin -l -r $R" kdc="${TESTS_ENVIRONMENT} ../../kdc/kdc --addresses=localhost -P $port" @@ -276,8 +277,10 @@ ${context} \ --name-type=hostbased-service host@lucid.test.h5l.se || \ { exitcode=1 ; echo "test failed"; } +echo "Getting client initial ticket" +${kinit} --password-file=${objdir}/foopassword user1@${R} || exitcode=1 + echo "Server time offset" -../../libtool --mode=execute gdb --arg \ ${context} \ --verbose \ --mech-type=krb5 \ @@ -286,8 +289,20 @@ ${context} \ --name-type=hostbased-service host@lucid.test.h5l.se || \ { exitcode=1 ; echo "test failed"; } -${klist} --hidden +echo "Getting client initial ticket" +${kinit} --password-file=${objdir}/foopassword user1@${R} || exitcode=1 +# Pre-poplute the cache since tgs-req will fail since our time is wrong +${kgetcred} host/lucid.test.h5l.se@${R} || exitcode=1 +echo "Client time offset" +../../libtool --mode=execute gdb --arg \ +${context} \ + --verbose \ + --mech-type=krb5 \ + --mutual-auth \ + --client-time-offset=3600 \ + --name-type=hostbased-service host@lucid.test.h5l.se || \ + { exitcode=1 ; echo "test failed"; } echo "killing kdc (${kdcpid})" kill ${kdcpid} 2> /dev/null