From fbcb5afa4af6ab2e8be1559ce1654810ecd7fb4b Mon Sep 17 00:00:00 2001 From: Paul Park Date: Wed, 26 Apr 1995 21:53:42 +0000 Subject: [PATCH] Supply the time regardless of whether DO_TIME is set because decryption/deserialization fails if the time is bogus. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@5527 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/krb5/krb/mk_priv.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/src/lib/krb5/krb/mk_priv.c b/src/lib/krb5/krb/mk_priv.c index 40c9bfa57..b29e886f3 100644 --- a/src/lib/krb5/krb/mk_priv.c +++ b/src/lib/krb5/krb/mk_priv.c @@ -161,15 +161,14 @@ krb5_mk_priv(context, auth_context, userdata, outbuf, outdata) /* Need a better error */ return KRB5_RC_REQUIRED; - if ((auth_context->auth_context_flags & KRB5_AUTH_CONTEXT_DO_TIME) || - (auth_context->auth_context_flags & KRB5_AUTH_CONTEXT_RET_TIME)) { - if (retval = krb5_us_timeofday(context, &replaydata.timestamp, - &replaydata.usec)) - return retval; - if (auth_context->auth_context_flags & KRB5_AUTH_CONTEXT_RET_TIME) { - outdata->timestamp = replaydata.timestamp; - outdata->usec = replaydata.usec; - } + /* Do the time, regardless */ + if (retval = krb5_us_timeofday(context, &replaydata.timestamp, + &replaydata.usec)) + return retval; + + if (auth_context->auth_context_flags & KRB5_AUTH_CONTEXT_RET_TIME) { + outdata->timestamp = replaydata.timestamp; + outdata->usec = replaydata.usec; } if ((auth_context->auth_context_flags & KRB5_AUTH_CONTEXT_DO_SEQUENCE) || (auth_context->auth_context_flags & KRB5_AUTH_CONTEXT_RET_SEQUENCE)) { -- 2.26.2