I'm implementing Windows -> Linux transparent authentication using Kerberos. On Windows side I use SSPI. And I successfully establish context between Windows client and Windows server, retrieving client's user name like that:
SecPkgContext_Names extraData;
res = QueryContextAttributes(&context, SECPKG_ATTR_NAMES, &extraData);
Now it's time to do the same, but on Linux box. I use gss_accept_sec_context and it returns GSS_S_COMPLETE, and variable with type gss_ctx_id_t gets filled. But I struggle to get client name. I excepted that it can be done using gss_inquire_sec_context_by_oid, however, I can't find what to pass as
const gss_OID /*desired_object*/
Could anyone give me the direction?