aboutsummaryrefslogtreecommitdiff
path: root/lib/urldata.h
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2005-03-10 23:15:29 +0000
committerDaniel Stenberg <daniel@haxx.se>2005-03-10 23:15:29 +0000
commitd1d35ba85fe6f8a9e6a86d2a6c60109cf90edd6c (patch)
treec06d860dc1025900ec91c85dd09e9989f5aeab4b /lib/urldata.h
parent2ab2e7675c2089b44210d19e92e07fbd5ca9084b (diff)
Christopher R. Palmer made it possible to build libcurl with the
USE_WINDOWS_SSPI on Windows, and then libcurl will be built to use the native way to do NTLM. SSPI also allows libcurl to pass on the current user and its password in the request.
Diffstat (limited to 'lib/urldata.h')
-rw-r--r--lib/urldata.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/lib/urldata.h b/lib/urldata.h
index e270334c0..4540f05c8 100644
--- a/lib/urldata.h
+++ b/lib/urldata.h
@@ -188,10 +188,30 @@ typedef enum {
NTLMSTATE_LAST
} curlntlm;
+#ifdef USE_WINDOWS_SSPI
+/* When including these headers, you must define either SECURITY_WIN32
+ * or SECURITY_KERNEL, indicating who is compiling the code.
+ */
+#define SECURITY_WIN32 1
+#include <sspi.h>
+#include <Security.h>
+#include <rpc.h>
+#endif
+
/* Struct used for NTLM challenge-response authentication */
struct ntlmdata {
curlntlm state;
+#ifdef USE_WINDOWS_SSPI
+ CredHandle handle;
+ CtxtHandle c_handle;
+ SEC_WINNT_AUTH_IDENTITY identity;
+ SEC_WINNT_AUTH_IDENTITY *p_identity;
+ int has_handles;
+ void *type_2;
+ int n_type_2;
+#else
unsigned char nonce[8];
+#endif
};
#ifdef HAVE_GSSAPI