FreeRDP
Loading...
Searching...
No Matches
negotiate.h
1
20#ifndef WINPR_SSPI_NEGOTIATE_PRIVATE_H
21#define WINPR_SSPI_NEGOTIATE_PRIVATE_H
22
23#include <winpr/sspi.h>
24
25#include "../sspi.h"
26
27#define NTLM_OID "1.3.6.1.4.1.311.2.2.10"
28
29typedef enum
30{
31 NEGOTIATE_STATE_INITIAL,
32 NEGOTIATE_STATE_FINAL_OPTIMISTIC,
33 NEGOTIATE_STATE_NEGORESP,
34 NEGOTIATE_STATE_MIC,
35 NEGOTIATE_STATE_FINAL,
36} NEGOTIATE_STATE;
37
38typedef struct Mech_st Mech;
39
40typedef struct
41{
42 NEGOTIATE_STATE state;
43 CtxtHandle sub_context;
44 SecBuffer mechTypes;
45 const Mech* mech;
46 BOOL mic;
47 BOOL spnego;
49
50static inline NEGOTIATE_CONTEXT NEGOTIATE_CONTEXT_init(void)
51{
52 const NEGOTIATE_CONTEXT empty = { .state = NEGOTIATE_STATE_INITIAL,
53 .sub_context = { 0 },
54 .mechTypes = { 0 },
55 .mech = NULL,
56 .mic = FALSE,
57 .spnego = FALSE };
58 return empty;
59}
60
61extern const SecPkgInfoA NEGOTIATE_SecPkgInfoA;
62extern const SecPkgInfoW NEGOTIATE_SecPkgInfoW;
63extern const SecurityFunctionTableA NEGOTIATE_SecurityFunctionTableA;
64extern const SecurityFunctionTableW NEGOTIATE_SecurityFunctionTableW;
65
66BOOL NEGOTIATE_init(void);
67
68#endif /* WINPR_SSPI_NEGOTIATE_PRIVATE_H */