12#ifndef __PACKET_DCERPC_NT_H
13#define __PACKET_DCERPC_NT_H
15#include <epan/dissectors/packet-dcerpc.h>
16#include "ws_symbol_export.h"
25#define ALIGN_TO_8_BYTES \
27 if(!di->conformant_run) { \
29 offset=(offset&0xfffffff8)+8; \
33#define ALIGN_TO_4_BYTES \
35 if(!di->conformant_run) { \
37 offset=(offset&0xfffffffc)+4; \
41#define ALIGN_TO_2_BYTES \
43 if(!di->conformant_run) { \
45 offset=(offset&0xfffffffe)+2; \
50#define ALIGN_TO_5_BYTES ALIGN_TO_4_OR_8_BYTES
52#define ALIGN_TO_4_OR_8_BYTES \
54 if (di->call_data->flags & DCERPC_IS_NDR64) { \
61#define ALIGN_TO_3_BYTES ALIGN_TO_2_OR_4_BYTES
63#define ALIGN_TO_2_OR_4_BYTES \
65 if (di->call_data->flags & DCERPC_IS_NDR64) { \
72#define UNION_ALIGN_TO_2_BYTES \
74 if (di->call_data->flags & DCERPC_IS_NDR64) { \
79#define UNION_ALIGN_TO_3_BYTES \
81 if (di->call_data->flags & DCERPC_IS_NDR64) { \
86#define UNION_ALIGN_TO_4_BYTES \
88 if (di->call_data->flags & DCERPC_IS_NDR64) { \
93#define UNION_ALIGN_TO_5_BYTES \
95 if (di->call_data->flags & DCERPC_IS_NDR64) { \
100#define UNION_ALIGN_TO_8_BYTES \
102 if (di->call_data->flags & DCERPC_IS_NDR64) { \
108dissect_ndr_datablob(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
109 proto_tree *tree, dcerpc_info *di, uint8_t *drep,
int hf_index,
110 int use_remaining_space);
113dissect_null_term_string(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
114 proto_tree *tree, uint8_t *drep,
int hf_index,
118dissect_null_term_wstring(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
119 proto_tree *tree, uint8_t *drep,
int hf_index,
123dissect_ndr_counted_ascii_string_cb(tvbuff_t *tvb,
unsigned offset,
125 dcerpc_info *di, uint8_t *drep,
int hf_index,
126 dcerpc_callback_fnct_t *callback,
127 void *callback_args);
129dissect_ndr_counted_ascii_string(tvbuff_t *tvb,
unsigned offset,
131 dcerpc_info *di, uint8_t *drep,
int hf_index,
int levels);
134dissect_ndr_counted_string_cb(tvbuff_t *tvb,
unsigned offset,
136 dcerpc_info *di, uint8_t *drep,
int hf_index,
137 dcerpc_callback_fnct_t *callback,
138 void *callback_args);
141dissect_ndr_counted_string_ptr(tvbuff_t *tvb,
unsigned offset,
143 dcerpc_info *di, uint8_t *drep);
146dissect_ndr_counted_string(tvbuff_t *tvb,
unsigned offset,
148 dcerpc_info *di, uint8_t *drep,
int hf_index,
int levels);
151dissect_ndr_counted_byte_array(tvbuff_t *tvb,
unsigned offset,
153 dcerpc_info *di, uint8_t *drep,
int hf_index,
int levels);
156dissect_ndr_counted_byte_array_cb(tvbuff_t *tvb,
unsigned offset,
158 dcerpc_info *di, uint8_t *drep,
int hf_index,
159 dcerpc_callback_fnct_t *callback,
160 void *callback_args);
163dissect_ndr_nt_acct_ctrl(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
164 proto_tree *parent_tree, dcerpc_info *di, uint8_t *drep);
167dissect_nt_GUID(tvbuff_t *tvb,
unsigned offset,
169 dcerpc_info *di, uint8_t *drep);
172dissect_ndr_lsa_String(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
173 proto_tree *parent_tree, dcerpc_info *di, uint8_t *drep,
174 uint32_t param,
int hfindex);
178dissect_ndr_nt_NTTIME (tvbuff_t *tvb,
unsigned offset,
180 dcerpc_info *di, uint8_t *drep,
int hf_index);
182dissect_ndr_nt_NTTIME_hyper (tvbuff_t *tvb,
unsigned offset,
184 dcerpc_info *di, uint8_t *drep,
int hf_index);
186dissect_ndr_nt_NTTIME_1sec (tvbuff_t *tvb,
unsigned offset,
188 dcerpc_info *di, uint8_t *drep,
int hf_index);
190dissect_ndr_nt_LOGON_HOURS(tvbuff_t *tvb,
unsigned offset,
192 dcerpc_info *di, uint8_t *drep);
194dissect_ndr_nt_SID(tvbuff_t *tvb,
unsigned offset,
196 dcerpc_info *di, uint8_t *drep);
198dissect_ndr_nt_SID_with_options(tvbuff_t *tvb,
unsigned offset,
200 dcerpc_info *di, uint8_t *drep, uint32_t options,
int hf_index);
202dissect_ndr_nt_PSID_cb(tvbuff_t *tvb,
unsigned offset,
204 dcerpc_info *di, uint8_t *drep,
205 dcerpc_callback_fnct_t *callback,
void *callback_args);
207dissect_ndr_nt_PSID(tvbuff_t *tvb,
unsigned offset,
209 dcerpc_info *di, uint8_t *drep);
211dissect_ndr_nt_PSID_ARRAY(tvbuff_t *tvb,
unsigned offset,
213 dcerpc_info *di, uint8_t *drep);
216dissect_ndr_nt_SE_GROUP_ATTRIBUTES(tvbuff_t *tvb,
unsigned offset,
218 dcerpc_info *di, uint8_t *drep);
221dissect_ndr_nt_SID_AND_ATTRIBUTES_ARRAY(tvbuff_t *tvb,
unsigned offset,
223 dcerpc_info *di, uint8_t *drep);
225dissect_ndr_nt_SID_AND_ATTRIBUTES(tvbuff_t *tvb,
unsigned offset,
227 dcerpc_info *di, uint8_t *drep);
230dissect_ndr_nt_SID28(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
231 proto_tree *tree, dcerpc_info *di, uint8_t *drep,
int hf_index);
239dcerpc_smb_store_pol_pkts(e_ctx_hnd *policy_hnd,
packet_info *pinfo,
245dcerpc_store_polhnd_name(e_ctx_hnd *policy_hnd,
packet_info *pinfo,
251dcerpc_fetch_polhnd_data(e_ctx_hnd *policy_hnd,
char **name, uint32_t *type,
252 uint32_t *open_frame, uint32_t *close_frame,
258dissect_ntstatus(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
259 proto_tree *tree, dcerpc_info *di, uint8_t *drep,
260 int hfindex, uint32_t *pdata);
263dissect_doserror(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
264 proto_tree *tree, dcerpc_info *di, uint8_t *drep,
265 int hfindex, uint32_t *pdata);
268dissect_werror(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
269 proto_tree *tree, dcerpc_info *di, uint8_t *drep,
270 int hfindex, uint32_t *pdata);
273dissect_hresult(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
274 proto_tree *tree, dcerpc_info *di, uint8_t *drep,
275 int hfindex, uint32_t *pdata);
278dissect_nt_policy_hnd(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
279 proto_tree *tree, dcerpc_info *di, uint8_t *drep,
int hfindex,
284PIDL_dissect_policy_hnd(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
285 proto_tree *tree, dcerpc_info* di, uint8_t *drep,
int hfindex,
289dissect_nt_guid_hnd(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
290 proto_tree *tree, dcerpc_info *di, uint8_t *drep,
int hfindex,
295dissect_nt_LUID(tvbuff_t *tvb,
unsigned offset,
302unsigned dissect_dcerpc_uint8s(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
303 proto_tree *tree, dcerpc_info *di, uint8_t *drep,
304 int hfindex,
int length,
const uint8_t **pdata);
306unsigned dissect_ndr_uint8s(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
307 proto_tree *tree, dcerpc_info *di, uint8_t *drep,
308 int hfindex,
int length,
const uint8_t **pdata);
310unsigned dissect_dcerpc_uint16s(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
311 proto_tree *tree, uint8_t *drep,
312 int hfindex,
int length);
314unsigned dissect_ndr_uint16s(tvbuff_t *tvb,
unsigned offset,
packet_info *pinfo,
315 proto_tree *tree, dcerpc_info *di, uint8_t *drep,
316 int hfindex,
int length);
318unsigned dissect_ndr_str_pointer_item(tvbuff_t *tvb,
unsigned offset,
320 dcerpc_info *di, uint8_t *drep,
int type,
const char *text,
321 int hf_index,
int levels);
323unsigned nt_dissect_MIDL_NDRHEADERBLOB(proto_tree *parent_tree, tvbuff_t *tvb,
unsigned offset, uint8_t *drep);
330#define CB_STR_ITEM_LEVELS(x) ((x) & 0xFFFF)
331#define CB_STR_SAVE 0x20000000
332#define CB_STR_COL_INFO 0x10000000
334void cb_wstr_postprocess(
packet_info *pinfo, proto_tree *tree _U_,
335 proto_item *item, dcerpc_info *di, tvbuff_t *tvb,
336 unsigned start_offset,
unsigned end_offset,
337 void *callback_args);
338void cb_str_postprocess(
packet_info *pinfo, proto_tree *tree _U_,
339 proto_item *item, dcerpc_info *di, tvbuff_t *tvb,
340 unsigned start_offset,
unsigned end_offset,
341 void *callback_args);
345void dcerpc_smb_init(
int proto_dcerpc);
348extern int hf_nt_cs_len;
349extern int hf_nt_cs_size;
struct _packet_info packet_info
Represents the metadata and indexing information for a single captured frame.
proto_node proto_item
Definition proto.h:927
struct _value_string value_string
Mapping between a 32-bit integer value and its string representation.