From 2acec63b2ed75bf4b71ad257db573c4b8f9639e7 Mon Sep 17 00:00:00 2001 From: tumagonx Date: Tue, 8 Aug 2017 10:54:53 +0700 Subject: initial commit --- vdm.h | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 vdm.h (limited to 'vdm.h') diff --git a/vdm.h b/vdm.h new file mode 100644 index 0000000..260a05e --- /dev/null +++ b/vdm.h @@ -0,0 +1,72 @@ +/* + * Copyright (c) 2004 Security Architects Corporation. All rights reserved. + * + * Module Name: + * + * vdm.h + * + * Abstract: + * + * This module implements various VDM (Virtual Dos Machine) hooking routines. + * + * Author: + * + * Eugene Tsyrklevich 06-Apr-2004 + * + * Revision History: + * + * None. + */ + + +#ifndef __VDM_H__ +#define __VDM_H__ + + + +/* + * ZwSetLdtEntries sets Local Descriptor Table (LDT) entries for a Virtual DOS Machine (VDM). [NAR] + */ + +typedef NTSTATUS (*fpZwSetLdtEntries) ( + IN ULONG Selector0, + IN ULONG Entry0Low, + IN ULONG Entry0Hi, + IN ULONG Selector1, + IN ULONG Entry1Low, + IN ULONG Entry1Hi + ); + +NTSTATUS +NTAPI +HookedNtSetLdtEntries( + IN ULONG Selector0, + IN ULONG Entry0Low, + IN ULONG Entry0Hi, + IN ULONG Selector1, + IN ULONG Entry1Low, + IN ULONG Entry1Hi + ); + + +/* + * ZwVdmControl performs a control operation on a VDM. [NAR] + */ + +typedef NTSTATUS (*fpZwVdmControl) ( + IN ULONG ControlCode, + IN PVOID ControlData + ); + +NTSTATUS +NTAPI +HookedNtVdmControl( + IN ULONG ControlCode, + IN PVOID ControlData + ); + + +BOOLEAN InitVdmHooks(); + + +#endif /* __VDM_H__ */ -- cgit v1.3