Check for broken KRB5CCNAME.
authorIain Patterson <me@iain.cx>
Fri, 21 Aug 2009 14:14:24 +0000 (15:14 +0100)
committerIain Patterson <me@iain.cx>
Fri, 28 Aug 2009 09:54:47 +0000 (10:54 +0100)
.profile.d/krb5.bashrc

index 586f80d..08dfb53 100644 (file)
@@ -10,6 +10,11 @@ if [ $UID -gt 0 -a -z "$OLDSOLARIS" -a -z "$OLDREDHAT" ]; then
       # Try to find an existing cache but only if we are using FILE: caches.
       default=$((unset KRB5CCNAME; klist 2>&1) | sed -n 's/.*FILE:\([^)]*\).*/\1/p')
       if [ ! -z "$default" ]; then
+        # Check for Exceed onDemand stupidity.
+        if [ "$KRB5CCNAME" = "FILE:" ]; then
+          unset KRB5CCNAME
+        fi
+
         # Check for bogus FILE: KRB5CCNAME.
         if [ ! -z "$KRB5CCNAME" -a "${KRB5CCNAME##*:}" = "$KRB5CCNAME" ]; then 
           export KRB5CCNAME="FILE:$KRB5CCNAME"