[libsoup/wip/tpopela/negotiate: 4/8] Use GSS_C_NT_HOSTBASED_SERVICE and "HTTP host" in gss_import_name



commit c4dc761323a1e838f19ccdeea4eedb5d5a809082
Author: Tomas Popela <tpopela redhat com>
Date:   Mon Oct 5 12:34:10 2015 +0200

    Use GSS_C_NT_HOSTBASED_SERVICE and "HTTP host" in gss_import_name
    
    As suggested by Dawid Woodhouse in https://bugzilla.gnome.org/show_bug.cgi?id=587145#c54

 libsoup/soup-gssapi.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/libsoup/soup-gssapi.c b/libsoup/soup-gssapi.c
index b5aa0f6..3dc0284 100644
--- a/libsoup/soup-gssapi.c
+++ b/libsoup/soup-gssapi.c
@@ -87,13 +87,13 @@ soup_gss_client_init (SoupNegotiateConnectionState *conn, const char *host, GErr
        conn->context = GSS_C_NO_CONTEXT;
 
        h = g_ascii_strdown (host, -1);
-       service = g_strconcat ("HTTP/", h, NULL);
+       service = g_strconcat ("HTTP@", h, NULL);
        token.length = strlen (service);
        token.value = (char *) service;
 
        maj_stat = gss_import_name (&min_stat,
                                    &token,
-                                   (gss_OID) GSS_KRB5_NT_PRINCIPAL_NAME,
+                                   (gss_OID) GSS_C_NT_HOSTBASED_SERVICE,
                                    &conn->server_name);
 
        if (GSS_ERROR (maj_stat)) {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]