-
Notifications
You must be signed in to change notification settings - Fork 39
/
amsi.h
executable file
·673 lines (457 loc) · 18 KB
/
amsi.h
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
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
/* this ALWAYS GENERATED file contains the definitions for the interfaces */
/* File created by MIDL compiler version 8.01.0622 */
/* @@MIDL_FILE_HEADING( ) */
/* verify that the <rpcndr.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCNDR_H_VERSION__
#define __REQUIRED_RPCNDR_H_VERSION__ 500
#endif
/* verify that the <rpcsal.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCSAL_H_VERSION__
#define __REQUIRED_RPCSAL_H_VERSION__ 100
#endif
#include "rpc.h"
#include "rpcndr.h"
#ifndef __RPCNDR_H_VERSION__
#error this stub requires an updated version of <rpcndr.h>
#endif /* __RPCNDR_H_VERSION__ */
#ifndef COM_NO_WINDOWS_H
#include "windows.h"
#include "ole2.h"
#endif /*COM_NO_WINDOWS_H*/
#ifndef __amsi_h__
#define __amsi_h__
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
#pragma once
#endif
/* Forward Declarations */
#ifndef __IAmsiStream_FWD_DEFINED__
#define __IAmsiStream_FWD_DEFINED__
typedef interface IAmsiStream IAmsiStream;
#endif /* __IAmsiStream_FWD_DEFINED__ */
#ifndef __IAntimalwareProvider_FWD_DEFINED__
#define __IAntimalwareProvider_FWD_DEFINED__
typedef interface IAntimalwareProvider IAntimalwareProvider;
#endif /* __IAntimalwareProvider_FWD_DEFINED__ */
#ifndef __IAntimalwareUacProvider_FWD_DEFINED__
#define __IAntimalwareUacProvider_FWD_DEFINED__
typedef interface IAntimalwareUacProvider IAntimalwareUacProvider;
#endif /* __IAntimalwareUacProvider_FWD_DEFINED__ */
#ifndef __IAntimalware_FWD_DEFINED__
#define __IAntimalware_FWD_DEFINED__
typedef interface IAntimalware IAntimalware;
#endif /* __IAntimalware_FWD_DEFINED__ */
/* header files for imported files */
#include "oaidl.h"
#include "ocidl.h"
#ifdef __cplusplus
extern "C"{
#endif
/* interface __MIDL_itf_amsi_0000_0000 */
/* [local] */
#include <winapifamily.h>
#pragma region Desktop Family
#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)
typedef /* [v1_enum] */
enum AMSI_RESULT
{
AMSI_RESULT_CLEAN = 0,
AMSI_RESULT_NOT_DETECTED = 1,
AMSI_RESULT_BLOCKED_BY_ADMIN_START = 0x4000,
AMSI_RESULT_BLOCKED_BY_ADMIN_END = 0x4fff,
AMSI_RESULT_DETECTED = 32768
} AMSI_RESULT;
#define AmsiResultIsMalware(r) ((r) >= AMSI_RESULT_DETECTED)
#define AmsiResultIsBlockedByAdmin(r) ((r) >= AMSI_RESULT_BLOCKED_BY_ADMIN_START) && (r) <= AMSI_RESULT_BLOCKED_BY_ADMIN_END
typedef /* [v1_enum] */
enum AMSI_ATTRIBUTE
{
AMSI_ATTRIBUTE_APP_NAME = 0,
AMSI_ATTRIBUTE_CONTENT_NAME = 1,
AMSI_ATTRIBUTE_CONTENT_SIZE = 2,
AMSI_ATTRIBUTE_CONTENT_ADDRESS = 3,
AMSI_ATTRIBUTE_SESSION = 4,
AMSI_ATTRIBUTE_REDIRECT_CHAIN_SIZE = 5,
AMSI_ATTRIBUTE_REDIRECT_CHAIN_ADDRESS = 6,
AMSI_ATTRIBUTE_ALL_SIZE = 7,
AMSI_ATTRIBUTE_ALL_ADDRESS = 8
} AMSI_ATTRIBUTE;
typedef /* [v1_enum] */
enum AMSI_UAC_REQUEST_TYPE
{
AMSI_UAC_REQUEST_TYPE_EXE = 0,
AMSI_UAC_REQUEST_TYPE_COM = 1,
AMSI_UAC_REQUEST_TYPE_MSI = 2,
AMSI_UAC_REQUEST_TYPE_AX = 3,
AMSI_UAC_REQUEST_TYPE_PACKAGED_APP = 4,
AMSI_UAC_REQUEST_TYPE_MAX = 5
} AMSI_UAC_REQUEST_TYPE;
typedef /* [v1_enum] */
enum AMSI_UAC_TRUST_STATE
{
AMSI_UAC_TRUST_STATE_TRUSTED = 0,
AMSI_UAC_TRUST_STATE_UNTRUSTED = 1,
AMSI_UAC_TRUST_STATE_BLOCKED = 2,
AMSI_UAC_TRUST_STATE_MAX = 3
} AMSI_UAC_TRUST_STATE;
typedef /* [v1_enum] */
enum AMSI_UAC_MSI_ACTION
{
AMSI_UAC_MSI_ACTION_INSTALL = 0,
AMSI_UAC_MSI_ACTION_UNINSTALL = 1,
AMSI_UAC_MSI_ACTION_UPDATE = 2,
AMSI_UAC_MSI_ACTION_MAINTENANCE = 3,
AMSI_UAC_MSI_ACTION_MAX = 4
} AMSI_UAC_MSI_ACTION;
typedef struct AMSI_UAC_REQUEST_EXE_INFO
{
ULONG ulLength;
/* [string] */ LPWSTR lpwszApplicationName;
/* [string] */ LPWSTR lpwszCommandLine;
/* [string] */ LPWSTR lpwszDLLParameter;
} AMSI_UAC_REQUEST_EXE_INFO;
typedef struct AMSI_UAC_REQUEST_EXE_INFO *LPAMSI_UAC_REQUEST_EXE_INFO;
typedef struct AMSI_UAC_REQUEST_COM_INFO
{
ULONG ulLength;
/* [string] */ LPWSTR lpwszServerBinary;
/* [string] */ LPWSTR lpwszRequestor;
GUID Clsid;
} AMSI_UAC_REQUEST_COM_INFO;
typedef struct AMSI_UAC_REQUEST_COM_INFO *LPAMSI_UAC_REQUEST_COM_INFO;
typedef struct AMSI_UAC_REQUEST_MSI_INFO
{
ULONG ulLength;
AMSI_UAC_MSI_ACTION MsiAction;
/* [string] */ LPWSTR lpwszProductName;
/* [string] */ LPWSTR lpwszVersion;
/* [string] */ LPWSTR lpwszLanguage;
/* [string] */ LPWSTR lpwszManufacturer;
/* [string] */ LPWSTR lpwszPackagePath;
/* [string] */ LPWSTR lpwszPackageSource;
ULONG ulUpdates;
/* [size_is][size_is][string] */ LPWSTR *ppwszUpdates;
/* [size_is][size_is][string] */ LPWSTR *ppwszUpdateSources;
} AMSI_UAC_REQUEST_MSI_INFO;
typedef struct AMSI_UAC_REQUEST_MSI_INFO *LPAMSI_UAC_REQUEST_MSI_INFO;
typedef struct AMSI_UAC_REQUEST_AX_INFO
{
ULONG ulLength;
/* [string] */ LPWSTR lpwszLocalInstallPath;
/* [string] */ LPWSTR lpwszSourceURL;
} AMSI_UAC_REQUEST_AX_INFO;
typedef struct AMSI_UAC_REQUEST_AX_INFO *LPAMSI_UAC_REQUEST_AX_INFO;
typedef struct AMSI_UAC_REQUEST_PACKAGED_APP_INFO
{
ULONG ulLength;
/* [string] */ LPWSTR lpwszApplicationName;
/* [string] */ LPWSTR lpwszCommandLine;
/* [string] */ LPWSTR lpPackageFamilyName;
/* [string] */ LPWSTR lpApplicationId;
} AMSI_UAC_REQUEST_PACKAGED_APP_INFO;
typedef struct AMSI_UAC_REQUEST_PACKAGED_APP_INFO *LPAMSI_UAC_REQUEST_PACKAGED_APP_INFO;
typedef struct AMSI_UAC_REQUEST_CONTEXT
{
ULONG ulLength;
ULONG ulRequestorProcessId;
AMSI_UAC_TRUST_STATE UACTrustState;
AMSI_UAC_REQUEST_TYPE Type;
/* [switch_is] */ /* [switch_type] */ union
{
/* [case()] */ AMSI_UAC_REQUEST_EXE_INFO ExeInfo;
/* [case()] */ AMSI_UAC_REQUEST_COM_INFO ComInfo;
/* [case()] */ AMSI_UAC_REQUEST_MSI_INFO MsiInfo;
/* [case()] */ AMSI_UAC_REQUEST_AX_INFO ActiveXInfo;
/* [case()] */ AMSI_UAC_REQUEST_PACKAGED_APP_INFO PackagedAppInfo;
} RequestType;
BOOL bAutoElevateRequest;
} AMSI_UAC_REQUEST_CONTEXT;
typedef struct AMSI_UAC_REQUEST_CONTEXT *LPAMSI_UAC_REQUEST_CONTEXT;
extern RPC_IF_HANDLE __MIDL_itf_amsi_0000_0000_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_amsi_0000_0000_v0_0_s_ifspec;
#ifndef __IAmsiStream_INTERFACE_DEFINED__
#define __IAmsiStream_INTERFACE_DEFINED__
/* interface IAmsiStream */
/* [uuid][unique][object][local] */
EXTERN_C const IID IID_IAmsiStream;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("3e47f2e5-81d4-4d3b-897f-545096770373")
IAmsiStream : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE GetAttribute(
/* [in] */ AMSI_ATTRIBUTE attribute,
/* [range][in] */ ULONG dataSize,
/* [length_is][size_is][out] */ unsigned char *data,
/* [out] */ ULONG *retData) = 0;
virtual HRESULT STDMETHODCALLTYPE Read(
/* [in] */ ULONGLONG position,
/* [range][in] */ ULONG size,
/* [length_is][size_is][out] */ unsigned char *buffer,
/* [out] */ ULONG *readSize) = 0;
};
#else /* C style interface */
typedef struct IAmsiStreamVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
IAmsiStream * This,
/* [in] */ REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
IAmsiStream * This);
ULONG ( STDMETHODCALLTYPE *Release )(
IAmsiStream * This);
HRESULT ( STDMETHODCALLTYPE *GetAttribute )(
IAmsiStream * This,
/* [in] */ AMSI_ATTRIBUTE attribute,
/* [range][in] */ ULONG dataSize,
/* [length_is][size_is][out] */ unsigned char *data,
/* [out] */ ULONG *retData);
HRESULT ( STDMETHODCALLTYPE *Read )(
IAmsiStream * This,
/* [in] */ ULONGLONG position,
/* [range][in] */ ULONG size,
/* [length_is][size_is][out] */ unsigned char *buffer,
/* [out] */ ULONG *readSize);
END_INTERFACE
} IAmsiStreamVtbl;
interface IAmsiStream
{
CONST_VTBL struct IAmsiStreamVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IAmsiStream_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IAmsiStream_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IAmsiStream_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define IAmsiStream_GetAttribute(This,attribute,dataSize,data,retData) \
( (This)->lpVtbl -> GetAttribute(This,attribute,dataSize,data,retData) )
#define IAmsiStream_Read(This,position,size,buffer,readSize) \
( (This)->lpVtbl -> Read(This,position,size,buffer,readSize) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IAmsiStream_INTERFACE_DEFINED__ */
#ifndef __IAntimalwareProvider_INTERFACE_DEFINED__
#define __IAntimalwareProvider_INTERFACE_DEFINED__
/* interface IAntimalwareProvider */
/* [uuid][unique][object][local] */
EXTERN_C const IID IID_IAntimalwareProvider;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("b2cabfe3-fe04-42b1-a5df-08d483d4d125")
IAntimalwareProvider : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE Scan(
/* [in] */ IAmsiStream *stream,
/* [out] */ AMSI_RESULT *result) = 0;
virtual void STDMETHODCALLTYPE CloseSession(
/* [in] */ ULONGLONG session) = 0;
virtual HRESULT STDMETHODCALLTYPE DisplayName(
/* [annotation][string][out] */
_Out_ LPWSTR *displayName) = 0;
};
#else /* C style interface */
typedef struct IAntimalwareProviderVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
IAntimalwareProvider * This,
/* [in] */ REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
IAntimalwareProvider * This);
ULONG ( STDMETHODCALLTYPE *Release )(
IAntimalwareProvider * This);
HRESULT ( STDMETHODCALLTYPE *Scan )(
IAntimalwareProvider * This,
/* [in] */ IAmsiStream *stream,
/* [out] */ AMSI_RESULT *result);
void ( STDMETHODCALLTYPE *CloseSession )(
IAntimalwareProvider * This,
/* [in] */ ULONGLONG session);
HRESULT ( STDMETHODCALLTYPE *DisplayName )(
IAntimalwareProvider * This,
/* [annotation][string][out] */
_Out_ LPWSTR *displayName);
END_INTERFACE
} IAntimalwareProviderVtbl;
interface IAntimalwareProvider
{
CONST_VTBL struct IAntimalwareProviderVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IAntimalwareProvider_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IAntimalwareProvider_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IAntimalwareProvider_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define IAntimalwareProvider_Scan(This,stream,result) \
( (This)->lpVtbl -> Scan(This,stream,result) )
#define IAntimalwareProvider_CloseSession(This,session) \
( (This)->lpVtbl -> CloseSession(This,session) )
#define IAntimalwareProvider_DisplayName(This,displayName) \
( (This)->lpVtbl -> DisplayName(This,displayName) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IAntimalwareProvider_INTERFACE_DEFINED__ */
#ifndef __IAntimalwareUacProvider_INTERFACE_DEFINED__
#define __IAntimalwareUacProvider_INTERFACE_DEFINED__
/* interface IAntimalwareUacProvider */
/* [uuid][unique][object] */
EXTERN_C const IID IID_IAntimalwareUacProvider;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("b2cabfe4-fe04-42b1-a5df-08d483d4d125")
IAntimalwareUacProvider : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE UacScan(
/* [in] */ __RPC__in LPAMSI_UAC_REQUEST_CONTEXT context,
/* [out] */ __RPC__out AMSI_RESULT *result) = 0;
virtual HRESULT STDMETHODCALLTYPE DisplayName(
/* [string][out] */ __RPC__deref_out_opt_string LPWSTR *displayName) = 0;
};
#else /* C style interface */
typedef struct IAntimalwareUacProviderVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in IAntimalwareUacProvider * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in IAntimalwareUacProvider * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in IAntimalwareUacProvider * This);
HRESULT ( STDMETHODCALLTYPE *UacScan )(
__RPC__in IAntimalwareUacProvider * This,
/* [in] */ __RPC__in LPAMSI_UAC_REQUEST_CONTEXT context,
/* [out] */ __RPC__out AMSI_RESULT *result);
HRESULT ( STDMETHODCALLTYPE *DisplayName )(
__RPC__in IAntimalwareUacProvider * This,
/* [string][out] */ __RPC__deref_out_opt_string LPWSTR *displayName);
END_INTERFACE
} IAntimalwareUacProviderVtbl;
interface IAntimalwareUacProvider
{
CONST_VTBL struct IAntimalwareUacProviderVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IAntimalwareUacProvider_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IAntimalwareUacProvider_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IAntimalwareUacProvider_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define IAntimalwareUacProvider_UacScan(This,context,result) \
( (This)->lpVtbl -> UacScan(This,context,result) )
#define IAntimalwareUacProvider_DisplayName(This,displayName) \
( (This)->lpVtbl -> DisplayName(This,displayName) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IAntimalwareUacProvider_INTERFACE_DEFINED__ */
#ifndef __IAntimalware_INTERFACE_DEFINED__
#define __IAntimalware_INTERFACE_DEFINED__
/* interface IAntimalware */
/* [uuid][unique][object][local] */
EXTERN_C const IID IID_IAntimalware;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("82d29c2e-f062-44e6-b5c9-3d9a2f24a2df")
IAntimalware : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE Scan(
/* [in] */ IAmsiStream *stream,
/* [out] */ AMSI_RESULT *result,
/* [out] */ IAntimalwareProvider **provider) = 0;
virtual void STDMETHODCALLTYPE CloseSession(
/* [in] */ ULONGLONG session) = 0;
};
#else /* C style interface */
typedef struct IAntimalwareVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
IAntimalware * This,
/* [in] */ REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
IAntimalware * This);
ULONG ( STDMETHODCALLTYPE *Release )(
IAntimalware * This);
HRESULT ( STDMETHODCALLTYPE *Scan )(
IAntimalware * This,
/* [in] */ IAmsiStream *stream,
/* [out] */ AMSI_RESULT *result,
/* [out] */ IAntimalwareProvider **provider);
void ( STDMETHODCALLTYPE *CloseSession )(
IAntimalware * This,
/* [in] */ ULONGLONG session);
END_INTERFACE
} IAntimalwareVtbl;
interface IAntimalware
{
CONST_VTBL struct IAntimalwareVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IAntimalware_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IAntimalware_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IAntimalware_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define IAntimalware_Scan(This,stream,result,provider) \
( (This)->lpVtbl -> Scan(This,stream,result,provider) )
#define IAntimalware_CloseSession(This,session) \
( (This)->lpVtbl -> CloseSession(This,session) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IAntimalware_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_amsi_0000_0004 */
/* [local] */
#ifdef __cplusplus
class DECLSPEC_UUID("fdb00e52-a214-4aa1-8fba-4357bb0072ec") CAntimalware;
#endif
EXTERN_C const CLSID CLSID_Antimalware;
DECLARE_HANDLE(HAMSICONTEXT);
DECLARE_HANDLE(HAMSISESSION);
STDAPI AmsiInitialize(
_In_ LPCWSTR appName,
_Outptr_ HAMSICONTEXT* amsiContext);
STDAPI_(VOID) AmsiUninitialize(
_In_ HAMSICONTEXT amsiContext);
STDAPI AmsiOpenSession(
_In_ HAMSICONTEXT amsiContext,
_Out_ HAMSISESSION* amsiSession);
STDAPI_(VOID) AmsiCloseSession(
_In_ HAMSICONTEXT amsiContext,
_In_ HAMSISESSION amsiSession);
STDAPI AmsiScanBuffer(
_In_ HAMSICONTEXT amsiContext,
_In_reads_bytes_(length) PVOID buffer,
_In_ ULONG length,
_In_opt_ LPCWSTR contentName,
_In_opt_ HAMSISESSION amsiSession,
_Out_ AMSI_RESULT* result);
STDAPI AmsiScanString(
_In_ HAMSICONTEXT amsiContext,
_In_ LPCWSTR string,
_In_opt_ LPCWSTR contentName,
_In_opt_ HAMSISESSION amsiSession,
_Out_ AMSI_RESULT* result);
#endif /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) */
#pragma endregion
extern RPC_IF_HANDLE __MIDL_itf_amsi_0000_0004_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_amsi_0000_0004_v0_0_s_ifspec;
/* Additional Prototypes for ALL interfaces */
/* end of Additional Prototypes */
#ifdef __cplusplus
}
#endif
#endif