]> git.ipfire.org Git - thirdparty/krb5.git/commitdiff
Allow full ccache name in k5test's K5Realm.klist
authorGreg Hudson <ghudson@mit.edu>
Wed, 11 Jul 2012 19:33:02 +0000 (15:33 -0400)
committerGreg Hudson <ghudson@mit.edu>
Wed, 11 Jul 2012 19:33:02 +0000 (15:33 -0400)
src/util/k5test.py

index b5f6d15100e3840168c3ac7cae39b5f8a97902c7..f7716194691833a25c5da81e384b07a3781a585f 100644 (file)
@@ -922,8 +922,11 @@ class K5Realm(object):
             service_princ = self.krbtgt_princ
         if ccache is None:
             ccache = self.ccache
+        ccachestr = ccache
+        if len(ccachestr) < 2 or ':' not in ccachestr[2:]:
+            ccachestr = 'FILE:' + ccachestr
         output = self.run_as_client([klist, ccache], **keywords)
-        if (('Ticket cache: FILE:%s\n' % ccache) not in output or
+        if (('Ticket cache: %s\n' % ccachestr) not in output or
             ('Default principal: %s\n' % client_princ) not in output or
             service_princ not in output):
             fail('Unexpected klist output.')