524 and NAT
Ken Hornstein
kenh at cmf.nrl.navy.mil
Fri Jan 17 10:50:00 EST 2003
>I don't suppose you have a patch you wouldn't mind handing out?
This should do it. IIRC, you need to definately build a new client library,
and possibly a new krb524d as well.
--Ken
Index: conv_creds.c
===================================================================
RCS file: conv_creds.c,v
retrieving revision 1.1.1.4
retrieving revision 1.5
diff -u -r1.1.1.4 -r1.5
--- conv_creds.c 25 Sep 2002 19:06:21 -0000 1.1.1.4
+++ conv_creds.c 25 Sep 2002 19:18:31 -0000 1.5
@@ -181,14 +181,15 @@
/* XXX perhaps we should use the addr of the client host if */
/* v5creds contains more than one addr. Q: Does V4 support */
/* non-INET addresses? */
- if (!v5creds->addresses || !v5creds->addresses[0] ||
- v5creds->addresses[0]->addrtype != ADDRTYPE_INET ||
- v5creds->addresses[0]->length != sizeof(addr)) {
+ if (v5creds->addresses && v5creds->addresses[0] &&
+ (v5creds->addresses[0]->addrtype != ADDRTYPE_INET ||
+ v5creds->addresses[0]->length != sizeof(addr))) {
if (krb524_debug)
fprintf(stderr, "Invalid v5creds address information.\n");
return KRB524_BADADDR;
} else
- memcpy((char *) &addr, v5creds->addresses[0]->contents,
+ if (v5creds->addresses && v5creds->addresses[0])
+ memcpy((char *) &addr, v5creds->addresses[0]->contents,
sizeof(addr));
#endif
return 0;
More information about the krbdev
mailing list