[libsoup/wip/tpopela/negotiate: 9/16] Use SPNEGO authentication instead of basic KRB5
- From: Tomas Popela <tpopela src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libsoup/wip/tpopela/negotiate: 9/16] Use SPNEGO authentication instead of basic KRB5
- Date: Fri, 30 Oct 2015 07:54:27 +0000 (UTC)
commit 3949a315138b981ca74178b8904e08468239430c
Author: Tomas Popela <tpopela redhat com>
Date: Mon Oct 5 12:31:47 2015 +0200
Use SPNEGO authentication instead of basic KRB5
As suggested by Dawid Woodhouse in https://bugzilla.gnome.org/show_bug.cgi?id=587145#c54
libsoup/soup-gssapi.c | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/libsoup/soup-gssapi.c b/libsoup/soup-gssapi.c
index 46225e6..b5aa0f6 100644
--- a/libsoup/soup-gssapi.c
+++ b/libsoup/soup-gssapi.c
@@ -26,6 +26,9 @@ soup_gss_client_step (SoupNegotiateConnectionState *conn, const char *host, GErr
void
soup_gss_client_cleanup (SoupNegotiateConnectionState *conn);
+static const char spnego_OID[] = "\x2b\x06\x01\x05\x05\x02";
+static const gss_OID_desc gss_mech_spnego = { 6, (void *)&spnego_OID };
+
static void
soup_gss_error (OM_uint32 err_maj, OM_uint32 err_min, GError **err)
{
@@ -37,7 +40,7 @@ soup_gss_error (OM_uint32 err_maj, OM_uint32 err_min, GError **err)
maj_stat = gss_display_status (&min_stat,
err_maj,
GSS_C_GSS_CODE,
- GSS_C_NO_OID,
+ (gss_OID) &gss_mech_spnego,
&msg_ctx,
&status);
if (GSS_ERROR (maj_stat))
@@ -126,7 +129,7 @@ soup_gss_client_step (SoupNegotiateConnectionState *conn, const char *challenge,
GSS_C_NO_CREDENTIAL,
&conn->context,
conn->server_name,
- GSS_C_NO_OID,
+ (gss_OID) &gss_mech_spnego,
GSS_C_MUTUAL_FLAG,
GSS_C_INDEFINITE,
GSS_C_NO_CHANNEL_BINDINGS,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]