use_dns_kdc.
* lib/krb5/os/accessor.c (krb5int_accessor): Set new field use_dns_kdc.
* lib/krb4/RealmsConfig-glue.c (krb_get_krbhst): Check if DNS should be used
for getting KDC names before actually using it.
ticket: 2772
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16920
dc483132-0cff-0310-8789-
dd5450dbe970
2004-12-08 Ken Raeburn <raeburn@mit.edu>
* k5-int.h (KRB5INT_ACCESS_STRUCT_VERSION): Bump to 9.
+ (struct _krb5int_access): Add function pointer field use_dns_kdc.
2004-12-06 Ken Raeburn <raeburn@mit.edu>
const char *protocol,
struct srv_dns_entry **answers);
void (*free_srv_dns_data)(struct srv_dns_entry *);
+ int (*use_dns_kdc)(krb5_context);
/* krb4 compatibility stuff -- may be null if not enabled */
krb5_int32 (*krb_life_to_time)(krb5_int32, int);
+2004-12-08 Ken Raeburn <raeburn@mit.edu>
+
+ * RealmsConfig-glue.c (krb_get_krbhst): Check if DNS should be
+ used for getting KDC names before actually using it.
+
2004-07-16 Ken Raeburn <raeburn@mit.edu>
* macsock.c: Deleted.
if (err)
break;
- realmdat.data = realm;
- realmdat.length = strlen(realm);
- err = k5.make_srv_query_realm(&realmdat, "_kerberos-iv", "_udp", &srv);
- if (err)
- break;
+ if (k5.use_dns_kdc(krb5__krb4_context)) {
+ realmdat.data = realm;
+ realmdat.length = strlen(realm);
+ err = k5.make_srv_query_realm(&realmdat, "_kerberos-iv", "_udp",
+ &srv);
+ if (err)
+ break;
- if (srv == 0)
- break;
+ if (srv == 0)
+ break;
- if (dnscache.srv)
- k5.free_srv_dns_data(dnscache.srv);
- dnscache.srv = srv;
- strncpy(dnscache.realm, realm, REALM_SZ);
- dnscache.when = now;
- goto get_from_dnscache;
+ if (dnscache.srv)
+ k5.free_srv_dns_data(dnscache.srv);
+ dnscache.srv = srv;
+ strncpy(dnscache.realm, realm, REALM_SZ);
+ dnscache.when = now;
+ goto get_from_dnscache;
+ }
} while (0);
#endif
return KFAILURE;
+2004-12-08 Ken Raeburn <raeburn@mit.edu>
+
+ * accessor.c (krb5int_accessor): Set new field use_dns_kdc.
+
2004-12-06 Tom Yu <tlyu@mit.edu>
* locate_kdc.c (krb5_locate_srv_dns_1): Don't compile if
#ifdef KRB5_DNS_LOOKUP
internals_temp.make_srv_query_realm = krb5int_make_srv_query_realm;
internals_temp.free_srv_dns_data = krb5int_free_srv_dns_data;
+ internals_temp.use_dns_kdc = _krb5_use_dns_kdc;
#else
internals_temp.make_srv_query_realm = 0;
internals_temp.free_srv_dns_data = 0;
+ internals_temp.use_dns_kdc = 0;
#endif
#ifdef KRB5_KRB4_COMPAT
internals_temp.krb_life_to_time = krb5int_krb_life_to_time;