1 #ifndef HEADER_CURL_SSPI_H
2 #define HEADER_CURL_SSPI_H
3 /***************************************************************************
5 * Project ___| | | | _ \| |
7 * | (__| |_| | _ <| |___
8 * \___|\___/|_| \_\_____|
10 * Copyright (C) 1998 - 2010, Daniel Stenberg, <daniel@haxx.se>, et al.
12 * This software is licensed as described in the file COPYING, which
13 * you should have received as part of this distribution. The terms
14 * are also available at http://curl.haxx.se/docs/copyright.html.
16 * You may opt to use, copy, modify, merge, publish, distribute and/or sell
17 * copies of the Software, and permit persons to whom the Software is
18 * furnished to do so, under the terms of the COPYING file.
20 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
21 * KIND, either express or implied.
23 ***************************************************************************/
27 #ifdef USE_WINDOWS_SSPI
29 #include <curl/curl.h>
32 * When including the folowing three headers, it is mandatory to define either
33 * SECURITY_WIN32 or SECURITY_KERNEL, indicating who is compiling the code.
37 #undef SECURITY_KERNEL
38 #define SECURITY_WIN32 1
43 /* Provide some definitions missing in MinGW's headers */
45 #ifndef SEC_I_CONTEXT_EXPIRED
46 # define SEC_I_CONTEXT_EXPIRED ((HRESULT)0x00090317L)
48 #ifndef SEC_E_BUFFER_TOO_SMALL
49 # define SEC_E_BUFFER_TOO_SMALL ((HRESULT)0x80090321L)
51 #ifndef SEC_E_CONTEXT_EXPIRED
52 # define SEC_E_CONTEXT_EXPIRED ((HRESULT)0x80090317L)
54 #ifndef SEC_E_CRYPTO_SYSTEM_INVALID
55 # define SEC_E_CRYPTO_SYSTEM_INVALID ((HRESULT)0x80090337L)
57 #ifndef SEC_E_MESSAGE_ALTERED
58 # define SEC_E_MESSAGE_ALTERED ((HRESULT)0x8009030FL)
60 #ifndef SEC_E_OUT_OF_SEQUENCE
61 # define SEC_E_OUT_OF_SEQUENCE ((HRESULT)0x80090310L)
64 CURLcode Curl_sspi_global_init(void);
65 void Curl_sspi_global_cleanup(void);
67 /* Forward-declaration of global variables defined in curl_sspi.c */
69 extern HMODULE s_hSecDll;
70 extern PSecurityFunctionTableA s_pSecFn;
72 #endif /* USE_WINDOWS_SSPI */
73 #endif /* HEADER_CURL_SSPI_H */