use the krb5_crypto directly, skipping some per packet calculation, make cfx handling simpler
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24067 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -152,6 +152,11 @@ _gsskrb5_wrap_size_limit (
|
||||
krb5_keytype keytype;
|
||||
const gsskrb5_ctx ctx = (const gsskrb5_ctx) context_handle;
|
||||
|
||||
if (ctx->more_flags & IS_CFX)
|
||||
return _gssapi_wrap_size_cfx(minor_status, ctx, context,
|
||||
conf_req_flag, qop_req,
|
||||
req_output_size, max_input_size);
|
||||
|
||||
GSSAPI_KRB5_INIT (&context);
|
||||
|
||||
HEIMDAL_MUTEX_lock(&ctx->ctx_id_mutex);
|
||||
@@ -177,9 +182,7 @@ _gsskrb5_wrap_size_limit (
|
||||
ret = sub_wrap_size(req_output_size, max_input_size, 8, 34);
|
||||
break;
|
||||
default :
|
||||
ret = _gssapi_wrap_size_cfx(minor_status, ctx, context,
|
||||
conf_req_flag, qop_req,
|
||||
req_output_size, max_input_size, key);
|
||||
abort();
|
||||
break;
|
||||
}
|
||||
krb5_free_keyblock (context, key);
|
||||
@@ -512,6 +515,14 @@ OM_uint32 _gsskrb5_wrap
|
||||
krb5_keytype keytype;
|
||||
const gsskrb5_ctx ctx = (const gsskrb5_ctx) context_handle;
|
||||
|
||||
output_message_buffer->value = NULL;
|
||||
output_message_buffer->length = 0;
|
||||
|
||||
if (ctx->more_flags & IS_CFX)
|
||||
return _gssapi_wrap_cfx (minor_status, ctx, context, conf_req_flag,
|
||||
qop_req, input_message_buffer, conf_state,
|
||||
output_message_buffer);
|
||||
|
||||
GSSAPI_KRB5_INIT (&context);
|
||||
|
||||
HEIMDAL_MUTEX_lock(&ctx->ctx_id_mutex);
|
||||
@@ -541,9 +552,7 @@ OM_uint32 _gsskrb5_wrap
|
||||
output_message_buffer, key);
|
||||
break;
|
||||
default :
|
||||
ret = _gssapi_wrap_cfx (minor_status, ctx, context, conf_req_flag,
|
||||
qop_req, input_message_buffer, conf_state,
|
||||
output_message_buffer, key);
|
||||
abort();
|
||||
break;
|
||||
}
|
||||
krb5_free_keyblock (context, key);
|
||||
|
Reference in New Issue
Block a user