summaryrefslogtreecommitdiff
path: root/librpc/idl/eventlog6.idl
blob: 57216cd56b7eee296329a9ef4b06073f14521587 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
#include "idl_types.h"


import "misc.idl";

cpp_quote("#define MAX_RPC_GUID_ARRAY_COUNT (MAX_PAYLOAD / sizeof(struct GUID))")
cpp_quote("#define eventlog6_EvtRpcSubscribePull    0x10000000")
cpp_quote("#define eventlog6_EvtRpcVarFlagsModified 0x00000001")

[
    uuid (f6beaff7-1e19-4fbb-9f8f-b89e2018337c),
    version(1.0),
    endpoint("ncacn_ip_tcp:"),
    helpstring("Eventlog6"),
    pointer_default(unique)
]
interface eventlog6
{
	const int MAX_PAYLOAD                  = 2 * 1024 * 1024;
	const int MAX_RPC_QUERY_LENGTH         = MAX_PAYLOAD / sizeof(uint16_t);
	const int MAX_RPC_CHANNEL_NAME_LENGTH  = 512;
	const int MAX_RPC_QUERY_CHANNEL_SIZE   = 512;
	const int MAX_RPC_EVENT_ID_SIZE        = 256;
	const int MAX_RPC_FILE_PATH_LENGTH     = 32768;
	const int MAX_RPC_CHANNEL_PATH_LENGTH  = 32768;
	const int MAX_RPC_BOOKMARK_LENGTH      = MAX_PAYLOAD / sizeof(uint16_t);
	const int MAX_RPC_PUBLISHER_ID_LENGTH  = 2048;
	const int MAX_RPC_PROPERTY_BUFFER_SIZE = MAX_PAYLOAD;
	const int MAX_RPC_FILTER_LENGTH        = MAX_RPC_QUERY_LENGTH;
	const int MAX_RPC_RECORD_COUNT         = 1024;
	const int MAX_RPC_EVENT_SIZE           = MAX_PAYLOAD;
	const int MAX_RPC_BATCH_SIZE           = MAX_PAYLOAD;
	const int MAX_RPC_RENDERED_STRING_SIZE = MAX_PAYLOAD;
	const int MAX_RPC_CHANNEL_COUNT        = 8192;
	const int MAX_RPC_PUBLISHER_COUNT      = 8192;
	const int MAX_RPC_EVENT_METADATA_COUNT = 256;
	const int MAX_RPC_VARIANT_LIST_COUNT   = 256;
	const int MAX_RPC_BOOLEAN8_ARRAY_COUNT = MAX_PAYLOAD / sizeof(uint8_t);
	const int MAX_RPC_UINT32_ARRAY_COUNT   = MAX_PAYLOAD / sizeof(uint32_t);
	const int MAX_RPC_UINT64_ARRAY_COUNT   = MAX_PAYLOAD / sizeof(uint64_t);
	const int MAX_RPC_STRING_ARRAY_COUNT   = MAX_PAYLOAD / 512;
	const int MAX_RPC_STRING_LENGTH        = MAX_PAYLOAD / sizeof(uint16_t);

	typedef struct {
		uint32 error;
		uint32 sub_err;
		uint32 sub_err_param;
	} eventlog6_RpcInfo;

	typedef struct {
		[range(0, MAX_RPC_BOOLEAN8_ARRAY_COUNT)] uint32 count;
		[size_is(count)] boolean8* ptr;
	} eventlog6_boolean8Array;

	typedef struct {
		[range(0, MAX_RPC_UINT32_ARRAY_COUNT)] uint32 count;
		[size_is(count)] uint32* ptr;
	} eventlog6_UInt32Array;

	typedef struct {
		[range(0, MAX_RPC_UINT64_ARRAY_COUNT)] uint32 count;
		[size_is(count)] hyper* ptr;
	} eventlog6_UInt64Array;

	typedef struct {
		[range(0, MAX_RPC_STRING_ARRAY_COUNT)] uint32 count;
		[size_is(count),charset(UTF16),string] uint16 **ptr;
	} eventlog6_StringArray;

	typedef struct {
		[range(0, MAX_RPC_GUID_ARRAY_COUNT)] uint32 count;
		[size_is(count)] GUID* ptr;
	} eventlog6_GuidArray;

	typedef [v1_enum] enum {
		EvtRpcVarTypeNull          = 0,
		EvtRpcVarTypeboolean8      = 1,
		EvtRpcVarTypeUInt32        = 2,
		EvtRpcVarTypeUInt64        = 3,
		EvtRpcVarTypeString        = 4,
		EvtRpcVarTypeGuid          = 5,
		EvtRpcVarTypeboolean8Array = 6,
		EvtRpcVarTypeUInt32Array   = 7,
		EvtRpcVarTypeUInt64Array   = 8,
		EvtRpcVarTypeStringArray   = 9,
		EvtRpcVarTypeGuidArray     = 10
	} eventlog6_EvtRpcVariantType;

	typedef [v1_enum] enum {
		EvtRpcChannelPath   = 0,
		EvtRpcPublisherName = 1
	} eventlog6_EvtRpcAssertConfigFlags;

	typedef [switch_type(eventlog6_EvtRpcVariantType)] union {
		[case(EvtRpcVarTypeNull)] int nullVal;
		[case(EvtRpcVarTypeboolean8)] boolean8 boolean8Val;
		[case(EvtRpcVarTypeUInt32)] uint32 uint32Val;
		[case(EvtRpcVarTypeUInt64)] hyper uint64Val;
		[case(EvtRpcVarTypeString)] [charset(UTF16),string] uint16 *stringVal;
		[case(EvtRpcVarTypeGuid)] GUID *guidVal;
		[case(EvtRpcVarTypeboolean8Array)] eventlog6_boolean8Array boolean8Array;
		[case(EvtRpcVarTypeUInt32Array)] eventlog6_UInt32Array uint32Array;
		[case(EvtRpcVarTypeUInt64Array)] eventlog6_UInt64Array uint64Array;
		[case(EvtRpcVarTypeStringArray)] eventlog6_StringArray stringArray;
		[case(EvtRpcVarTypeGuidArray)] eventlog6_GuidArray guidArray;
	} eventlog6_EvtRpcVariantUnion;

	typedef struct {
		eventlog6_EvtRpcVariantType type;
		uint32 flags;
		[in,ref,switch_is(type)] eventlog6_EvtRpcVariantUnion *var;
	} eventlog6_EvtRpcVariant;

	typedef struct {
		[range(0, MAX_RPC_VARIANT_LIST_COUNT)] uint32 count;
		[size_is(count)] eventlog6_EvtRpcVariant* props;
	} eventlog6_EvtRpcVariantList;

	typedef struct {
		[charset(UTF16),string] uint16 *name;
		uint32 status;
	} eventlog6_EvtRpcQueryChannelInfo;

	WERROR eventlog6_EvtRpcRegisterRemoteSubscription(
		[in, unique, range(0, MAX_RPC_CHANNEL_NAME_LENGTH),charset(UTF16),string] uint16 *channelPath,
		[in, range(1, MAX_RPC_QUERY_LENGTH),charset(UTF16),string] uint16 *query,
		[in, unique, range(0, MAX_RPC_BOOKMARK_LENGTH),charset(UTF16),string] uint16 *bookmarkXml,
		[in] uint32 flags,
		[out, ref] policy_handle *handle,
		[out, ref] policy_handle *control,
		[out, ref] uint32 *queryChannelInfoSize,
		[out, size_is(,*queryChannelInfoSize), range(0, MAX_RPC_QUERY_CHANNEL_SIZE)]
		eventlog6_EvtRpcQueryChannelInfo **queryChannelInfo,
		[out, ref] eventlog6_RpcInfo *error);

	WERROR eventlog6_EvtRpcRemoteSubscriptionNextAsync(
		[in, ref] policy_handle *handle,
		[in] uint32 numRequestedRecords,
		[in] uint32 flags,
		[out, ref] uint32 *numActualRecords,
		[out, size_is(,*numActualRecords), range(0, MAX_RPC_RECORD_COUNT)]
		uint32 **eventDataIndices,
		[out, size_is(,*numActualRecords), range(0, MAX_RPC_RECORD_COUNT)]
		uint32 **eventDataSizes,
		[out, ref] uint32* resultBufferSize,
		[out, size_is(,*resultBufferSize), range(0, MAX_RPC_BATCH_SIZE)]
		uint8 **resultBuffer);

	WERROR eventlog6_EvtRpcRemoteSubscriptionNext(
		[in, ref] policy_handle *handle,
		[in] uint32 numRequestedRecords,
		[in] uint32 timeOut,
		[in] uint32 flags,
		[out, ref] uint32 *numActualRecords,
		[out, size_is(,*numActualRecords), range(0, MAX_RPC_RECORD_COUNT)]
		uint32 **eventDataIndices,
		[out, size_is(,*numActualRecords), range(0, MAX_RPC_RECORD_COUNT)]
		uint32 **eventDataSizes,
		[out, ref] uint32 *resultBufferSize,
		[out, size_is(,*resultBufferSize), range(0, MAX_RPC_BATCH_SIZE)]
		uint8 **resultBuffer);

	WERROR eventlog6_EvtRpcRemoteSubscriptionWaitAsync(
		[in, ref] policy_handle *handle);

	WERROR eventlog6_EvtRpcRegisterControllableOperation(
		[out, ref] policy_handle *handle);

	WERROR eventlog6_EvtRpcRegisterLogQuery(
		[in, unique, range(0, MAX_RPC_CHANNEL_PATH_LENGTH),charset(UTF16),string] uint16 *path,
		[in, range(1, MAX_RPC_QUERY_LENGTH),charset(UTF16),string] uint16 *query,
		[in] uint32 flags,
		[out, ref] policy_handle *handle,
		[out, ref] policy_handle *opControl,
		[out, ref] uint32 *queryChannelInfoSize,
		[out, size_is(,*queryChannelInfoSize), range(0, MAX_RPC_QUERY_CHANNEL_SIZE)]
		eventlog6_EvtRpcQueryChannelInfo **queryChannelInfo,
		[out, ref] eventlog6_RpcInfo *error);

	WERROR eventlog6_EvtRpcClearLog(
		[in, ref] policy_handle *control,
		[in, range(0, MAX_RPC_CHANNEL_NAME_LENGTH),charset(UTF16),string] uint16 *channelPath,
		[in, unique, range(0, MAX_RPC_FILE_PATH_LENGTH),charset(UTF16),string] uint16 *backupPath,
		[in] uint32 flags,
		[out, ref] eventlog6_RpcInfo *error);

	WERROR 	eventlog6_EvtRpcExportLog(
		[in, ref] policy_handle *control,
		[in, unique, range(0, MAX_RPC_CHANNEL_NAME_LENGTH),charset(UTF16),string] uint16 *channelPath,
		[in, range(1, MAX_RPC_QUERY_LENGTH),charset(UTF16),string] uint16 *query,
		[in, range(1, MAX_RPC_FILE_PATH_LENGTH),charset(UTF16),string] uint16 *backupPath,
		[in] uint32 flags,
		[out, ref] eventlog6_RpcInfo *error);

	WERROR eventlog6_EvtRpcLocalizeExportLog(
		[in, ref] policy_handle *control,
		[in, range(1, MAX_RPC_FILE_PATH_LENGTH),charset(UTF16),string] uint16 *logFilePath,
		[in] uint32 locale,
		[in] uint32 flags,
		[out, ref] eventlog6_RpcInfo *error);

	WERROR eventlog6_EvtRpcMessageRender(
		[in, ref] policy_handle *pubCfgObj,
		[in, range(1, MAX_RPC_EVENT_ID_SIZE)] uint32 sizeEventId,
		[in, size_is(sizeEventId)] uint8 *eventId,
		[in] uint32 messageId,
		[in] eventlog6_EvtRpcVariantList *values,
		[in] uint32 flags,
		[in] uint32 maxSizeString,
		[out, ref] uint32 *actualSizeString,
		[out, ref] uint32 *neededSizeString,
		[out, size_is(,*actualSizeString), range(0, MAX_RPC_RENDERED_STRING_SIZE)]
		uint8 **string,
		[out, ref] eventlog6_RpcInfo *error);

	WERROR eventlog6_EvtRpcMessageRenderDefault(
		[in, range(1, MAX_RPC_EVENT_ID_SIZE)] uint32 sizeEventId,
		[in, size_is(sizeEventId)] uint8 *eventId,
		[in] uint32 messageId,
		[in] eventlog6_EvtRpcVariantList *values,
		[in] uint32 flags,
		[in] uint32 maxSizeString,
		[out, ref] uint32 *actualSizeString,
		[out, ref] uint32 *neededSizeString,
		[out, size_is(,*actualSizeString), range(0, MAX_RPC_RENDERED_STRING_SIZE)]
		uint8 **string,
		[out, ref] eventlog6_RpcInfo *error);

	WERROR eventlog6_EvtRpcQueryNext(
		[in, ref] policy_handle *logQuery,
		[in] uint32 numRequestedRecords,
		[in] uint32 timeOutEnd,
		[in] uint32 flags,
		[out, ref] uint32 *numActualRecords,
		[out, size_is(,*numActualRecords), range(0, MAX_RPC_RECORD_COUNT)]
		uint32 **eventDataIndices,
		[out, size_is(,*numActualRecords), range(0, MAX_RPC_RECORD_COUNT)]
		uint32 **eventDataSizes,
		[out, ref] uint32 *resultBufferSize,
		[out, size_is(,*resultBufferSize), range(0, MAX_RPC_BATCH_SIZE)]
		uint8 **resultBuffer);

	WERROR eventlog6_EvtRpcQuerySeek(
		[in, ref] policy_handle *logQuery,
		[in] hyper pos,
		[in, unique, range(0, MAX_RPC_BOOKMARK_LENGTH),charset(UTF16),string] uint16 *bookmarkXml,
		[in] uint32 timeOut,
		[in] uint32 flags,
		[out, ref] eventlog6_RpcInfo *error);

	WERROR eventlog6_EvtRpcClose(
		[in, out, ref] policy_handle **handle);

	WERROR eventlog6_EvtRpcCancel(
		[in, ref] policy_handle *handle);

	WERROR eventlog6_EvtRpcAssertConfig(
		[in, range(1, MAX_RPC_CHANNEL_NAME_LENGTH),charset(UTF16),string] uint16 *path,
		[in] uint32 flags);

	WERROR eventlog6_EvtRpcRetractConfig(
		[in, range(1, MAX_RPC_CHANNEL_NAME_LENGTH),charset(UTF16),string] uint16 *path,
		[in] uint32 flags );

	WERROR eventlog6_EvtRpcOpenLogHandle(
		[in, range(1, MAX_RPC_CHANNEL_NAME_LENGTH),charset(UTF16),string] uint16 *channel,
		[in] uint32 flags,
		[out, ref] policy_handle *handle,
		[out, ref] eventlog6_RpcInfo *error);

	WERROR eventlog6_EvtRpcGetLogFileInfo(
		[in, ref] policy_handle *logHandle,
		[in] uint32 propertyId,
		[in, range(0, MAX_RPC_PROPERTY_BUFFER_SIZE)]
		uint32 propertyValueBufferSize,
		[out, size_is(propertyValueBufferSize)] uint8 *propertyValueBuffer,
		[out, ref] uint32 *propertyValueBufferLength);

	WERROR eventlog6_EvtRpcGetChannelList(
		[in] uint32 flags,
		[out, ref] uint32 *numChannelPaths,
		[out, size_is(,*numChannelPaths), range(0, MAX_RPC_CHANNEL_COUNT),charset(UTF16),string]
		uint16 ***channelPaths);

	WERROR eventlog6_EvtRpcGetChannelConfig(
		[in, range(1, MAX_RPC_CHANNEL_NAME_LENGTH),charset(UTF16),string] uint16 *channelPath,
		[in] uint32 flags,
		[out, ref] eventlog6_EvtRpcVariantList* props);

	WERROR eventlog6_EvtRpcPutChannelConfig(
		[in, range(1, MAX_RPC_CHANNEL_NAME_LENGTH),charset(UTF16),string] uint16 *channelPath,
		[in] uint32 flags,
		[in] eventlog6_EvtRpcVariantList* props,
		[out, ref] eventlog6_RpcInfo *error);

	WERROR eventlog6_EvtRpcGetPublisherList(
		[in] uint32 flags,
		[out, ref] uint32 *numPublisherIds,
		[out, size_is(,*numPublisherIds), range(0, MAX_RPC_PUBLISHER_COUNT),charset(UTF16),string]
		uint16 ***publisherIds);

	WERROR eventlog6_EvtRpcGetPublisherListForChannel(
		[in] uint16 *channelName,
		[in] uint32 flags,
		[out, ref] uint32* numPublisherIds,
		[out, size_is(,*numPublisherIds), range(0, MAX_RPC_PUBLISHER_COUNT),charset(UTF16),string]
		uint16 ***publisherIds);

	WERROR eventlog6_EvtRpcGetPublisherMetadata(
		[in, unique, range(0, MAX_RPC_PUBLISHER_ID_LENGTH),charset(UTF16),string] uint16 *publisherId,
		[in, unique, range(0, MAX_RPC_FILE_PATH_LENGTH),charset(UTF16),string] uint16 *logFilePath,
		[in] uint32 locale,
		[in] uint32 flags,
		[out, ref] eventlog6_EvtRpcVariantList* pubMetadataProps,
		[out, ref] policy_handle *pubMetadata);

	WERROR eventlog6_EvtRpcGetPublisherResourceMetadata(
		[in, ref] policy_handle *handle,
		[in] uint32 propertyId,
		[in] uint32 flags,
		[out, ref] eventlog6_EvtRpcVariantList *pubMetadataProps);

	WERROR eventlog6_EvtRpcGetEventMetadataEnum(
		[in, ref] policy_handle *pubMetadata,
		[in] uint32 flags,
		[in, unique, range(0, MAX_RPC_FILTER_LENGTH),charset(UTF16),string] uint16 *reservedForFilter,
		[out, ref] policy_handle *eventMetaDataEnum);

	WERROR eventlog6_EvtRpcGetNextEventMetadata(
		[in, ref] policy_handle *eventMetaDataEnum,
		[in] uint32 flags,
		[in] uint32 numRequested,
		[out, ref] uint32 *numReturned,
		[out, size_is(,*numReturned), range(0, MAX_RPC_EVENT_METADATA_COUNT)]
		eventlog6_EvtRpcVariantList **eventMetadataInstances);

	WERROR eventlog6_EvtRpcGetClassicLogDisplayName(
		[in, range(1, MAX_RPC_CHANNEL_NAME_LENGTH),charset(UTF16),string] uint16 *logName,
		[in] uint32 locale,
		[in] uint32 flags,
		[out] uint16 **displayName);
}