4 NEGOEX interface definition
5 See http://ietfreport.isoc.org/all-ids/draft-zhu-negoex-04.txt
11 uuid("fcc30ddc-98d0-11e5-8a56-83e9a6706f2f"),
12 helper
("../librpc/ndr/ndr_negoex.h"),
13 helpstring("NEGOEX messages")
17 typedef [nopush
,nopull
,noprint
] struct {
19 [relative
,size_is(length
)] uint8
*data
;
24 * internal helper variable */
27 * the dummy pointer is needed in order to let the
28 * callers use NDR_BUFFERS
30 [relative
] uint8
*_dummy
;
34 typedef [public] struct {
38 typedef [nopush
,nopull
] struct {
39 [relative
,size_is(count
)] negoex_AUTH_SCHEME
*array
;
41 } negoex_AUTH_SCHEME_VECTOR
;
43 typedef [v1_enum] enum {
44 NEGOEX_EXTENSION_TYPE_TODO
= 0 /* TODO */
45 } negoex_ExtensionTypes
;
47 typedef [public] struct {
48 negoex_ExtensionTypes type
;
49 negoex_BYTE_VECTOR value
;
52 typedef [nopush
,nopull
] struct {
53 [relative
,size_is(count
)] negoex_EXTENSION
*array
;
55 } negoex_EXTENSION_VECTOR
;
57 typedef [v1_enum] enum {
58 NEGOEX_CHECKSUM_SCHEME_RFC3961
= 1
59 } negoex_ChecksumSchemes
;
62 [value
(20)] uint32 header_length
;
63 negoex_ChecksumSchemes scheme
;
65 negoex_BYTE_VECTOR value
;
68 typedef [v1_enum] enum {
69 NEGOEX_ALERT_VERIFY_NO_KEY
= 1
72 typedef [public] struct {
73 [value
(4)] uint32 header_length
; /* TODO: is 4 correct? */
74 negoex_AlertReason reason
;
77 typedef [v1_enum] enum {
78 NEGOEX_ALERT_TYPE_PULSE
= 1
81 typedef [public] struct {
82 negoex_AlertTypes type
;
83 negoex_BYTE_VECTOR value
;
86 typedef [nopush
,nopull
] struct {
87 [relative
,size_is(count
)] negoex_ALERT
*array
;
89 } negoex_ALERT_VECTOR
;
91 typedef [public,v1_enum] enum {
92 NEGOEX_MESSAGE_TYPE_INITIATOR_NEGO
= 0,
93 NEGOEX_MESSAGE_TYPE_ACCEPTOR_NEGO
= 1,
94 NEGOEX_MESSAGE_TYPE_INITIATOR_META_DATA
= 2,
95 NEGOEX_MESSAGE_TYPE_ACCEPTOR_META_DATA
= 3,
96 NEGOEX_MESSAGE_TYPE_CHALLENGE
= 4,
97 NEGOEX_MESSAGE_TYPE_AP_REQUEST
= 5,
98 NEGOEX_MESSAGE_TYPE_VERIFY
= 6,
99 NEGOEX_MESSAGE_TYPE_ALERT
= 7
100 } negoex_MESSAGE_TYPE
;
102 const uint32 NEGOEX_PROTOCOL_VERSION_0
= 0;
104 typedef [flag
(NDR_PAHEX
)] struct {
105 [flag
(NDR_PAHEX
)] uint8 random
[32];
106 [value
(NEGOEX_PROTOCOL_VERSION_0
)] udlong protocol_version
;
107 negoex_AUTH_SCHEME_VECTOR auth_schemes
;
108 negoex_EXTENSION_VECTOR extensions
;
109 } negoex_NEGO_PAYLOAD
;
112 negoex_AUTH_SCHEME auth_scheme
;
113 negoex_BYTE_VECTOR exchange
;
114 } negoex_EXCHANGE_PAYLOAD
;
117 negoex_AUTH_SCHEME auth_scheme
;
118 negoex_CHECKSUM checksum
;
119 } negoex_VERIFY_PAYLOAD
;
122 negoex_AUTH_SCHEME auth_scheme
;
124 negoex_ALERT_VECTOR alerts
;
125 } negoex_ALERT_PAYLOAD
;
127 typedef [public,nodiscriminant
] union {
128 [case(NEGOEX_MESSAGE_TYPE_INITIATOR_NEGO
)] negoex_NEGO_PAYLOAD nego
;
129 [case(NEGOEX_MESSAGE_TYPE_ACCEPTOR_NEGO
)] negoex_NEGO_PAYLOAD nego
;
130 [case(NEGOEX_MESSAGE_TYPE_INITIATOR_META_DATA
)] negoex_EXCHANGE_PAYLOAD exchange
;
131 [case(NEGOEX_MESSAGE_TYPE_ACCEPTOR_META_DATA
)] negoex_EXCHANGE_PAYLOAD exchange
;
132 [case(NEGOEX_MESSAGE_TYPE_CHALLENGE
)] negoex_EXCHANGE_PAYLOAD exchange
;
133 [case(NEGOEX_MESSAGE_TYPE_AP_REQUEST
)] negoex_EXCHANGE_PAYLOAD exchange
;
134 [case(NEGOEX_MESSAGE_TYPE_VERIFY
)] negoex_VERIFY_PAYLOAD verify
;
135 [case(NEGOEX_MESSAGE_TYPE_ALERT
)] negoex_ALERT_PAYLOAD alert
;
138 typedef [public,relative_base
,gensize
,nopull
] struct {
139 [charset
(DOS
),value
("NEGOEXTS")] uint8 signature
[8];
140 negoex_MESSAGE_TYPE type
;
141 uint32 sequence_number
;
142 [value
(ndr_negoex_MESSAGE_header_length
(r
))] uint32 header_length
;
143 [value
(ndr_size_negoex_MESSAGE
(r
, ndr
->flags
))] uint32 message_length
;
144 GUID conversation_id
;
145 [switch_is(type
)] negoex_PAYLOAD p
;
148 typedef [public,nopush
,nopull
,flag
(NDR_NOALIGN
)] struct {
150 negoex_MESSAGE messages
[count
];
151 } negoex_MESSAGE_ARRAY
;
153 void decode_negoex_MESSAGE
(
154 [in] negoex_MESSAGE_ARRAY array