+2003-01-09 Sam Hartman <hartmans@mit.edu>
+
+ * get_creds.c (krb5_get_credentials_core): Patch from Ben Cox
+ <cox-work@djehuti.com> to not use expired service credentials if
+ the endtime is null but instead to search for unexpired
+ credentials. If none are found, get new credentials.
+
+
2003-01-08 Sam Hartman <hartmans@mit.edu>
* fwd_tgt.c (krb5_fwd_tgt_creds): Don't require hostname to be supplied unless you are using addresses in the ticket.
memset((char *)mcreds, 0, sizeof(krb5_creds));
mcreds->magic = KV5M_CREDS;
- mcreds->times.endtime = in_creds->times.endtime;
+ if (in_creds->times.endtime != 0) {
+ mcreds->times.endtime = in_creds->times.endtime;
+ } else {
+ krb5_error_code retval;
+ retval = krb5_timeofday(context, &mcreds->times.endtime);
+ if (retval != 0) return retval;
+ }
#ifdef HAVE_C_STRUCTURE_ASSIGNMENT
mcreds->keyblock = in_creds->keyblock;
#else