diff options
author | Marcel Roelofs <Marcel.Roelofs@aimms.com> | 2011-01-05 17:01:07 +0100 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2011-01-07 23:48:40 +0100 |
commit | 1d28efb9d1759bcbc81d28e462c2e3a5d60a17e4 (patch) | |
tree | 415e7ca19589d7f8e4ef6532f2bab5e1236d9ce6 /lib/urldata.h | |
parent | 9ba42a023d6df26ac7ad2dde992f212ed3b05f8f (diff) |
HTTP: HTTP Negotiate authentication using SSPI
Only under Windows
Diffstat (limited to 'lib/urldata.h')
-rw-r--r-- | lib/urldata.h | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/lib/urldata.h b/lib/urldata.h index 2765c3ebe..55167fbc3 100644 --- a/lib/urldata.h +++ b/lib/urldata.h @@ -7,7 +7,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2010, Daniel Stenberg, <daniel@haxx.se>, et al. + * Copyright (C) 1998 - 2011, Daniel Stenberg, <daniel@haxx.se>, et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -358,17 +358,29 @@ struct ntlmdata { #endif }; -#ifdef HAVE_GSSAPI +#ifdef USE_HTTP_NEGOTIATE struct negotiatedata { /* when doing Negotiate we first need to receive an auth token and then we need to send our header */ enum { GSS_AUTHNONE, GSS_AUTHRECV, GSS_AUTHSENT } state; bool gss; /* Whether we're processing GSS-Negotiate or Negotiate */ const char* protocol; /* "GSS-Negotiate" or "Negotiate" */ +#ifdef HAVE_GSSAPI OM_uint32 status; gss_ctx_id_t context; gss_name_t server_name; gss_buffer_desc output_token; +#else +#ifdef USE_WINDOWS_SSPI + DWORD status; + CtxtHandle *context; + CredHandle *credentials; + char server_name[1024]; + size_t max_token_length; + BYTE *output_token; + size_t output_token_length; +#endif +#endif }; #endif @@ -1127,7 +1139,7 @@ struct UrlState { struct digestdata digest; /* state data for host Digest auth */ struct digestdata proxydigest; /* state data for proxy Digest auth */ -#ifdef HAVE_GSSAPI +#ifdef USE_HTTP_NEGOTIATE struct negotiatedata negotiate; /* state data for host Negotiate auth */ struct negotiatedata proxyneg; /* state data for proxy Negotiate auth */ #endif |