getting tokens for a remote cell (PATCH INCLUDED)

Assar Westerlund assar at stacken.kth.se
Fri Mar 17 17:39:05 CET 2000


Love <lha at stacken.kth.se> writes:
> > I don't think that kth-krb's behavior is quite right though, it should be
> > using the ticket file specified by krb_set_tkt_string() preferentially
> > over KRBTKFILE.
> 
> That sounds about right. Think assar will fix that.

Yes, Both Christopher and Love are right.

The appended patch to krb4 should take care of it.  I've also fixed
krb_get_default_principal to use tkt_string.

If people are still having problems after having patched klog or
libkafs, please tell us.

/assar

Index: afskrb.c
===================================================================
RCS file: /afs/pdc.kth.se/src/packages/kth-krb/SourceRepository/lib/kafs/afskrb.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -w -u -w -r1.13 -r1.14
--- afskrb.c	1999/12/02 16:58:39	1.13
+++ afskrb.c	2000/03/16 05:35:56	1.14
@@ -33,7 +33,7 @@
 
 #include "kafs_locl.h"
 
-RCSID("$Id: afskrb.c,v 1.13 1999/12/02 16:58:39 joda Exp $");
+RCSID("$Id: afskrb.c,v 1.14 2000/03/16 05:35:56 assar Exp $");
 
 struct krb_kafs_data {
     const char *realm;
@@ -69,13 +69,9 @@
 	return _kafs_afslog_all_local_cells (data, uid, homedir);
 
     /* Extract realm from ticket file. */
-    {
-        char name[ANAME_SZ], inst[INST_SZ];
-
-	ret = krb_get_default_principal(name, inst, realm);
+    ret = krb_get_tf_fullname(tkt_string(), NULL, NULL, realm);
 	if (ret != KSUCCESS)
 	    return ret;
-    }
 
     ret = _kafs_get_cred(data, cell, realm_hint, realm, &c);
     





More information about the Arla-drinkers mailing list