ReactOS 0.4.15-dev-7887-g64a59a1
ntlm.h
Go to the documentation of this file.
1
2#ifndef __WINE_NTLM_H__
3#define __WINE_NTLM_H__
4
5#include <sys/types.h>
6#define CP_UNIXCP CP_ACP
7
9
10typedef enum _helper_mode {
15
16typedef struct tag_arc4_info {
17 unsigned char x, y;
18 unsigned char state[256];
20
21typedef struct _NegoHelper {
22#ifndef __REACTOS__
24#else
26#endif
30 int major;
31 int minor;
32 int micro;
33 char *com_buf;
38 struct {
39 struct {
43 struct {
55
56typedef struct _NtlmCredentials
57{
59
60 /* these are all in the Unix codepage */
63 char *password; /* not nul-terminated */
64 int pwlen;
65 int no_cached_credentials; /* don't try to use cached Samba credentials */
67
68typedef enum _sign_direction {
72
75
76/* NTLMSSP flags indicating the negotiated features */
77#define NTLMSSP_NEGOTIATE_UNICODE 0x00000001
78#define NTLMSSP_NEGOTIATE_OEM 0x00000002
79#define NTLMSSP_REQUEST_TARGET 0x00000004
80#define NTLMSSP_NEGOTIATE_SIGN 0x00000010
81#define NTLMSSP_NEGOTIATE_SEAL 0x00000020
82#define NTLMSSP_NEGOTIATE_DATAGRAM_STYLE 0x00000040
83#define NTLMSSP_NEGOTIATE_LM_SESSION_KEY 0x00000080
84#define NTLMSSP_NEGOTIATE_NTLM 0x00000200
85#define NTLMSSP_NEGOTIATE_DOMAIN_SUPPLIED 0x00001000
86#define NTLMSSP_NEGOTIATE_WORKSTATION_SUPPLIED 0x00002000
87#define NTLMSSP_NEGOTIATE_LOCAL_CALL 0x00004000
88#define NTLMSSP_NEGOTIATE_ALWAYS_SIGN 0x00008000
89#define NTLMSSP_NEGOTIATE_TARGET_TYPE_DOMAIN 0x00010000
90#define NTLMSSP_NEGOTIATE_TARGET_TYPE_SERVER 0x00020000
91#define NTLMSSP_NEGOTIATE_NTLM2 0x00080000
92#define NTLMSSP_NEGOTIATE_TARGET_INFO 0x00800000
93#define NTLMSSP_NEGOTIATE_128 0x20000000
94#define NTLMSSP_NEGOTIATE_KEY_EXCHANGE 0x40000000
95#define NTLMSSP_NEGOTIATE_56 0x80000000
96
112
115
116#endif /* __WINE_NTLM_H__ */
DWORD pid_t
Definition: types.h:91
#define SEC_ENTRY
Definition: stubs.c:6
SecPkgInfoW * ntlm_package_infoW
Definition: ntlm.c:2024
SecPkgInfoA * ntlm_package_infoA
Definition: ntlm.c:2023
GLenum GLsizei len
Definition: glext.h:6722
static WCHAR password[]
Definition: url.c:33
SECURITY_STATUS SEC_ENTRY ntlm_VerifySignature(PCtxtHandle, PSecBufferDesc, ULONG, PULONG) DECLSPEC_HIDDEN
Definition: ntlm.c:1697
SECURITY_STATUS SEC_ENTRY ntlm_DecryptMessage(PCtxtHandle, PSecBufferDesc, ULONG, PULONG) DECLSPEC_HIDDEN
Definition: ntlm.c:1863
SECURITY_STATUS SEC_ENTRY ntlm_QueryContextAttributesA(PCtxtHandle, ULONG, void *) DECLSPEC_HIDDEN
Definition: ntlm.c:1482
struct _NtlmCredentials NtlmCredentials
SECURITY_STATUS SECUR32_CreateNTLM2SubKeys(PNegoHelper helper) DECLSPEC_HIDDEN
Definition: util.c:156
enum _helper_mode HelperMode
_sign_direction
Definition: ntlm.h:68
@ NTLM_RECV
Definition: ntlm.h:70
@ NTLM_SEND
Definition: ntlm.h:69
SECURITY_STATUS SEC_ENTRY ntlm_QueryContextAttributesW(PCtxtHandle, ULONG, void *) DECLSPEC_HIDDEN
Definition: ntlm.c:1427
SecPkgInfoW *ntlm_package_infoW DECLSPEC_HIDDEN
Definition: ntlm.h:114
enum _sign_direction SignDirection
SECURITY_STATUS SEC_ENTRY ntlm_DeleteSecurityContext(PCtxtHandle) DECLSPEC_HIDDEN
Definition: ntlm.c:1398
SECURITY_STATUS SEC_ENTRY ntlm_AcceptSecurityContext(PCredHandle, PCtxtHandle, PSecBufferDesc, ULONG, ULONG, PCtxtHandle, PSecBufferDesc, ULONG *, PTimeStamp) DECLSPEC_HIDDEN
Definition: ntlm.c:1029
struct _NtlmCredentials * PNtlmCredentials
SECURITY_STATUS SEC_ENTRY ntlm_EncryptMessage(PCtxtHandle, ULONG, PSecBufferDesc, ULONG) DECLSPEC_HIDDEN
Definition: ntlm.c:1792
_helper_mode
Definition: ntlm.h:10
@ NUM_HELPER_MODES
Definition: ntlm.h:13
@ NTLM_SERVER
Definition: ntlm.h:11
@ NTLM_CLIENT
Definition: ntlm.h:12
struct _NegoHelper NegoHelper
SECURITY_STATUS SEC_ENTRY ntlm_InitializeSecurityContextW(PCredHandle, PCtxtHandle, SEC_WCHAR *, ULONG fContextReq, ULONG, ULONG, PSecBufferDesc, ULONG, PCtxtHandle, PSecBufferDesc, ULONG *, PTimeStamp) DECLSPEC_HIDDEN
Definition: ntlm.c:484
struct _NegoHelper * PNegoHelper
void SECUR32_initNTLMSP(void) DECLSPEC_HIDDEN
Definition: ntlm.c:2026
struct tag_arc4_info arc4_info
SECURITY_STATUS SEC_ENTRY ntlm_FreeCredentialsHandle(PCredHandle) DECLSPEC_HIDDEN
Definition: ntlm.c:1767
SECURITY_STATUS SEC_ENTRY ntlm_MakeSignature(PCtxtHandle, ULONG, PSecBufferDesc, ULONG) DECLSPEC_HIDDEN
Definition: ntlm.c:1662
SECURITY_STATUS SECUR32_CreateNTLM1SessionKey(PBYTE password, int len, PBYTE session_key) DECLSPEC_HIDDEN
Definition: util.c:122
SECURITY_STATUS SEC_ENTRY ntlm_AcquireCredentialsHandleW(SEC_WCHAR *, SEC_WCHAR *, ULONG, PLUID, PVOID, SEC_GET_KEY_FN, PVOID, PCredHandle, PTimeStamp) DECLSPEC_HIDDEN
Definition: ntlm.c:127
BYTE * PBYTE
Definition: pedump.c:66
LONG SECURITY_STATUS
Definition: sspi.h:34
void(SEC_ENTRY * SEC_GET_KEY_FN)(void *Arg, void *Principal, ULONG KeyVer, void **Key, SECURITY_STATUS *Status)
Definition: sspi.h:189
WCHAR SEC_WCHAR
Definition: sspi.h:29
struct _NegoHelper::@549::@550 ntlm
pid_t helper_pid
Definition: ntlm.h:23
int minor
Definition: ntlm.h:31
BYTE * send_sign_key
Definition: ntlm.h:44
int com_buf_offset
Definition: ntlm.h:35
int pipe_out
Definition: ntlm.h:29
struct _NegoHelper::@549::@551 ntlm2
BYTE * session_key
Definition: ntlm.h:36
int pipe_in
Definition: ntlm.h:28
arc4_info * recv_a4i
Definition: ntlm.h:51
BYTE * recv_sign_key
Definition: ntlm.h:46
char * com_buf
Definition: ntlm.h:33
ULONG seq_num
Definition: ntlm.h:40
ULONG send_seq_no
Definition: ntlm.h:48
int com_buf_size
Definition: ntlm.h:34
BYTE * send_seal_key
Definition: ntlm.h:45
ULONG neg_flags
Definition: ntlm.h:37
BYTE * recv_seal_key
Definition: ntlm.h:47
struct _NegoHelper::@549 crypt
int major
Definition: ntlm.h:30
int micro
Definition: ntlm.h:32
arc4_info * a4i
Definition: ntlm.h:41
ULONG recv_seq_no
Definition: ntlm.h:49
arc4_info * send_a4i
Definition: ntlm.h:50
HelperMode mode
Definition: ntlm.h:27
char * domain_arg
Definition: ntlm.h:62
HelperMode mode
Definition: ntlm.h:58
char * username_arg
Definition: ntlm.h:61
char * password
Definition: ntlm.h:63
int no_cached_credentials
Definition: ntlm.h:65
unsigned char x
Definition: ntlm.h:17
unsigned char y
Definition: ntlm.h:17
unsigned char state[256]
Definition: ntlm.h:18
uint32_t * PULONG
Definition: typedefs.h:59
uint32_t ULONG
Definition: typedefs.h:59
unsigned char BYTE
Definition: xxhash.c:193