How to retrieve src_name in SSPI
Markus Moeller
huaraz at moeller.plus.com
Wed Jan 23 14:40:27 EST 2008
I think you have to call QueryContextAttribute like shown below for getting
the Username.
maj_stat = AcceptSecurityContext( &server_creds,
context,
&input_desc,
global_asc_flags,
SECURITY_NATIVE_DREP,
&new_context,
&output_desc,
&ret_flags,
&expiry
);
maj_stat = QueryContextAttributes(&new_context, SECPKG_ATTR_NAMES,
&names);
printf("User: %s\n", names.sUserName);
Markus
"Manoj Mohan" <manojm at us.ibm.com> wrote in message
news:OF6A62F810.5F50DE85-ON862573D9.001D3770-862573D9.001D82C5 at us.ibm.com...
>
> Hi,
>
> In GSSAPI we call gss_accept_sec_context on server side which also gives
> us
> the client name as an output.
> For example,
> maj_stat = gss_accept_sec_context(&min_stat,
> &context_handle,
> verifier_cred_handle,
> &gss_input_token,
> input_chan_bindings,,
> &src_name, -------------------->
> Client Name
> &actual_mech_type,
> &gss_output_token,
> &ret_flags,
> &time_ret,,
> &delegated_cred_handle);
>
> I am implementing similar program using SSPI and there the equivalent call
> is AcceptSecurityContext and that
> does not have this as an output. What API should I call after
> AcceptSecurityContext to get that information?
>
> Thanks & Regards,
> Manoj
> ________________________________________________
> Kerberos mailing list Kerberos at mit.edu
> https://mailman.mit.edu/mailman/listinfo/kerberos
>
More information about the Kerberos
mailing list