ReactOS  0.4.14-dev-317-g96040ec
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 
10 typedef enum _helper_mode {
14 } HelperMode;
15 
16 typedef struct tag_arc4_info {
17  unsigned char x, y;
18  unsigned char state[256];
19 } arc4_info;
20 
21 typedef struct _NegoHelper {
22 #ifndef __REACTOS__
24 #else
26 #endif
28  int pipe_in;
29  int pipe_out;
30  int major;
31  int minor;
32  int micro;
33  char *com_buf;
38  struct {
39  struct {
42  } ntlm;
43  struct {
52  } ntlm2;
53  } crypt;
55 
56 typedef struct _NtlmCredentials
57 {
59 
60  /* these are all in the Unix codepage */
61  char *username_arg;
62  char *domain_arg;
63  char *password; /* not nul-terminated */
64  int pwlen;
65  int no_cached_credentials; /* don't try to use cached Samba credentials */
67 
68 typedef 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__ */
SECURITY_STATUS SEC_ENTRY ntlm_EncryptMessage(PCtxtHandle, ULONG, PSecBufferDesc, ULONG) DECLSPEC_HIDDEN
Definition: ntlm.c:1792
BYTE * recv_sign_key
Definition: ntlm.h:46
unsigned char x
Definition: ntlm.h:17
int major
Definition: ntlm.h:30
struct _NtlmCredentials NtlmCredentials
pid_t helper_pid
Definition: ntlm.h:23
struct _NegoHelper * PNegoHelper
SECURITY_STATUS SEC_ENTRY ntlm_DeleteSecurityContext(PCtxtHandle) DECLSPEC_HIDDEN
Definition: ntlm.c:1398
SecPkgInfoW * ntlm_package_infoW
Definition: ntlm.c:2024
WCHAR SEC_WCHAR
Definition: sspi.h:29
SecPkgInfoA * ntlm_package_infoA
Definition: ntlm.c:2023
HelperMode mode
Definition: ntlm.h:27
int pipe_out
Definition: ntlm.h:29
char * password
Definition: ntlm.h:63
BYTE * send_sign_key
Definition: ntlm.h:44
BYTE * recv_seal_key
Definition: ntlm.h:47
DWORD pid_t
Definition: types.h:91
arc4_info * recv_a4i
Definition: ntlm.h:51
struct _NegoHelper::@536::@538 ntlm2
SecPkgInfoW *ntlm_package_infoW DECLSPEC_HIDDEN
Definition: ntlm.h:113
unsigned char state[256]
Definition: ntlm.h:18
SECURITY_STATUS SEC_ENTRY ntlm_QueryContextAttributesW(PCtxtHandle, ULONG, void *) DECLSPEC_HIDDEN
Definition: ntlm.c:1427
SECURITY_STATUS SECUR32_CreateNTLM2SubKeys(PNegoHelper helper) DECLSPEC_HIDDEN
Definition: util.c:156
struct _NegoHelper::@536 crypt
int minor
Definition: ntlm.h:31
char * com_buf
Definition: ntlm.h:33
struct _NtlmCredentials * PNtlmCredentials
ULONG seq_num
Definition: ntlm.h:40
_sign_direction
Definition: ntlm.h:68
LONG SECURITY_STATUS
Definition: sspi.h:34
#define SEC_ENTRY
Definition: stubs.c:6
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
int com_buf_offset
Definition: ntlm.h:35
SECURITY_STATUS SEC_ENTRY ntlm_QueryContextAttributesA(PCtxtHandle, ULONG, void *) DECLSPEC_HIDDEN
Definition: ntlm.c:1482
int pipe_in
Definition: ntlm.h:28
enum _helper_mode HelperMode
_helper_mode
Definition: ntlm.h:10
arc4_info * a4i
Definition: ntlm.h:41
BYTE * send_seal_key
Definition: ntlm.h:45
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
struct _NegoHelper::@536::@537 ntlm
ULONG neg_flags
Definition: ntlm.h:37
arc4_info * send_a4i
Definition: ntlm.h:50
ULONG recv_seq_no
Definition: ntlm.h:49
SECURITY_STATUS SEC_ENTRY ntlm_VerifySignature(PCtxtHandle, PSecBufferDesc, ULONG, PULONG) DECLSPEC_HIDDEN
Definition: ntlm.c:1697
T1_FIELD_DICT_PRIVATE password
Definition: t1tokens.h:64
struct tag_arc4_info arc4_info
GLenum GLsizei len
Definition: glext.h:6722
unsigned char BYTE
Definition: mem.h:68
BYTE * session_key
Definition: ntlm.h:36
SECURITY_STATUS SEC_ENTRY ntlm_FreeCredentialsHandle(PCredHandle) DECLSPEC_HIDDEN
Definition: ntlm.c:1767
void(SEC_ENTRY * SEC_GET_KEY_FN)(void *Arg, void *Principal, ULONG KeyVer, void **Key, SECURITY_STATUS *Status)
Definition: sspi.h:175
int micro
Definition: ntlm.h:32
char * username_arg
Definition: ntlm.h:61
SECURITY_STATUS SECUR32_CreateNTLM1SessionKey(PBYTE password, int len, PBYTE session_key) DECLSPEC_HIDDEN
Definition: util.c:122
HelperMode mode
Definition: ntlm.h:58
unsigned int * PULONG
Definition: retypes.h:1
SECURITY_STATUS SEC_ENTRY ntlm_DecryptMessage(PCtxtHandle, PSecBufferDesc, ULONG, PULONG) DECLSPEC_HIDDEN
Definition: ntlm.c:1863
int no_cached_credentials
Definition: ntlm.h:65
int com_buf_size
Definition: ntlm.h:34
ULONG send_seq_no
Definition: ntlm.h:48
unsigned char y
Definition: ntlm.h:17
enum _sign_direction SignDirection
unsigned int ULONG
Definition: retypes.h:1
Definition: ntlm.h:69
SECURITY_STATUS SEC_ENTRY ntlm_AcceptSecurityContext(PCredHandle, PCtxtHandle, PSecBufferDesc, ULONG, ULONG, PCtxtHandle, PSecBufferDesc, ULONG *, PTimeStamp) DECLSPEC_HIDDEN
Definition: ntlm.c:1029
struct _NegoHelper NegoHelper
BYTE * PBYTE
Definition: pedump.c:66
SECURITY_STATUS SEC_ENTRY ntlm_MakeSignature(PCtxtHandle, ULONG, PSecBufferDesc, ULONG) DECLSPEC_HIDDEN
Definition: ntlm.c:1662
void SECUR32_initNTLMSP(void) DECLSPEC_HIDDEN
Definition: ntlm.c:2026
char * domain_arg
Definition: ntlm.h:62
Definition: ntlm.h:70