X-Git-Url: http://www.project-moonshot.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=moonshot%2Fmech_eap%2Futil_lucid.c;fp=moonshot%2Fmech_eap%2Futil_lucid.c;h=f9e9941f97561cbef5950ef41f455d2c6851f702;hb=76a9dc1b58c74932e284ec24f37a21d0659598ab;hp=359058c1963acddec65ab11e7523fcf12a8fd967;hpb=6196f93aaca970f23276407af0812179c51a29ea;p=moonshot.git diff --git a/moonshot/mech_eap/util_lucid.c b/moonshot/mech_eap/util_lucid.c index 359058c..f9e9941 100644 --- a/moonshot/mech_eap/util_lucid.c +++ b/moonshot/mech_eap/util_lucid.c @@ -136,7 +136,10 @@ cleanup: lctx->version = 1; lctx->initiate = CTX_IS_INITIATOR(ctx); - lctx->endtime = ctx->expiryTime; + if (ctx->expiryTime == 0) + lctx->endtime = KRB_TIME_FOREVER; + else + lctx->endtime = ctx->expiryTime; lctx->send_seq = ctx->sendSeq; lctx->recv_seq = ctx->recvSeq; lctx->protocol = 1; @@ -144,8 +147,8 @@ cleanup: lctx->cfx_kd.have_acceptor_subkey = haveAcceptorSubkey; lkey = haveAcceptorSubkey - ? &lctx->cfx_kd.ctx_key - : &lctx->cfx_kd.acceptor_subkey; + ? &lctx->cfx_kd.acceptor_subkey + : &lctx->cfx_kd.ctx_key; lkey->type = KRB_KEY_TYPE(&ctx->rfc3961Key); lkey->data = GSSEAP_MALLOC(KRB_KEY_LENGTH(&ctx->rfc3961Key));