lib/krb5: let krb5_init_creds_step() return an out_realm
This matches krb5_init_creds_step() from MIT. The only
difference is the type 'krb5_realm' (Heimdal) vs. 'krb5_data' (MIT).
krb5_error_code KRB5_CALLCONV
krb5_init_creds_step(krb5_context context,
krb5_init_creds_context ctx,
krb5_data *in,
krb5_data *out,
krb5_data *realm,
unsigned int *flags);
NOTE: commit 1cdc9d5f3c
"krb5: export krb5_init_creds_step()" exported
krb5_init_creds_step() the first time, but that's
not in any released version, so it should be fine
to fix up the prototype in order to make the
function actually useful for external callers.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
This commit is contained in:

committed by
Jeffrey Altman

parent
b0bc54c921
commit
fd75c3e23c
@@ -856,7 +856,7 @@ _krb5_fast_anon_pkinit_step(krb5_context context,
|
||||
struct krb5_fast_state *state,
|
||||
krb5_data *in,
|
||||
krb5_data *out,
|
||||
const void *_unused,
|
||||
krb5_realm *out_realm,
|
||||
unsigned int *flags)
|
||||
{
|
||||
krb5_error_code ret;
|
||||
@@ -867,6 +867,9 @@ _krb5_fast_anon_pkinit_step(krb5_context context,
|
||||
krb5_creds cred;
|
||||
krb5_data data = { 3, rk_UNCONST("yes") };
|
||||
|
||||
krb5_data_zero(out);
|
||||
*out_realm = NULL;
|
||||
|
||||
memset(&cred, 0, sizeof(cred));
|
||||
|
||||
if (state->anon_pkinit_opt == NULL) {
|
||||
@@ -902,7 +905,7 @@ _krb5_fast_anon_pkinit_step(krb5_context context,
|
||||
|
||||
anon_pk_ctx = state->anon_pkinit_ctx;
|
||||
|
||||
ret = krb5_init_creds_step(context, anon_pk_ctx, in, out, NULL, flags);
|
||||
ret = krb5_init_creds_step(context, anon_pk_ctx, in, out, out_realm, flags);
|
||||
if (ret ||
|
||||
(*flags & KRB5_INIT_CREDS_STEP_FLAG_CONTINUE))
|
||||
goto out;
|
||||
|
Reference in New Issue
Block a user