SlideShare ist ein Scribd-Unternehmen logo
1 von 41
Downloaden Sie, um offline zu lesen
Reverse Engineering
The Windows Kernel (2)
Kent Huang
Asynchronous and
Ad-Hoc Execution
Introduce the Component
inside Windows Kernel
1. Usage
2. Introduce the data structure
3. How it work inside Windows Kernel
4. What’s the usage in root-kit
5. Exercises
System Threads
• Driver may create multiple threads handling
different requests from kernel or user.
• Call API PsCreateSystemThread
NTSTATUS PsCreateSystemThread(
_Out_ PHANDLE ThreadHandle,
_In_ ULONG DesiredAccess,
_In_opt_ POBJECT_ATTRIBUTES ObjectAttributes,
_In_opt_ HANDLE ProcessHandle,
_Out_opt_ PCLIENT_ID ClientId,
_In_ PKSTART_ROUTINE StartRoutine,
_In_opt_ PVOID StartContext
);
System Threads
• If process handle is not NULL, thread will be
created under that process.
• Someone say, if call PsCreateSystemThread in an
IOCTL handler, the new thread will be in the user-
mode application ???
Exercises
• Determine whether any of them pass a non-NULL
ProcessHandle parameter. Explain the purpose of
these routines. Repeat the exercise for as many
functions as possible.
Work Items
• Similar to system threads
• Except that no physical thread object
• Common driver programming pattern to queue
work items inside a DPC
PIO_WORKITEM IoAllocateWorkItem(
_In_ PDEVICE_OBJECT DeviceObject
);
VOID IoQueueWorkItem(
_In_ PIO_WORKITEM IoWorkItem,
_In_ PIO_WORKITEM_ROUTINE WorkerRoutine,
_In_ WORK_QUEUE_TYPE QueueType,
_In_opt_ PVOID Context
);
Structure
1: kd> dt _IO_WORKITEM
nt!_IO_WORKITEM
+0x000 WorkItem : _WORK_QUEUE_ITEM
+0x010 Routine : Ptr32 void
+0x014 IoObject : Ptr32 Void
+0x018 Context : Ptr32 Void
+0x01c Type : Uint4B
+0x020 ActivityId : _GUID
1: kd> dt _WORK_QUEUE_ITEM
nt!_WORK_QUEUE_ITEM
+0x000 List : _LIST_ENTRY
+0x008 WorkerRoutine : Ptr32 void
+0x00c Parameter : Ptr32 Void
1: kd> dt _WORK_QUEUE_TYPE
TmXPFlt!_WORK_QUEUE_TYPE
CriticalWorkQueue = 0n0
DelayedWorkQueue = 0n1
HyperCriticalWorkQueue = 0n2
MaximumWorkQueue = 0n3
1: kd> dt _KPRCB ParentNode
nt!_KPRCB
+0x338 ParentNode : Ptr32 _KNODE
1: kd> dt _KNODE
nt!_KNODE
+0x000 DeepIdleSet : Uint4B
+0x004 SharedReadyQueueLeaders : Uint4B
+0x040 ProximityId : Uint4B
+0x044 NodeNumber : Uint2B
…
1: kd> dt _ENODE
nt!_ENODE
+0x000 Ncb : _KNODE
+0x0c0 ExWorkQueue : [2] _EX_WORK_QUEUE
…
1: kd> dt _EX_WORK_QUEUE
nt!_EX_WORK_QUEUE
+0x000 WorkPriQueue : _KPRIQUEUE
+0x19c WorkItemsProcessed : Uint4B
+0x1a0 WorkItemsProcessedLastPass : Uint4B
+0x1a4 ThreadCount : Int4B
+0x1a8 TryFailed : UChar
kd> !thread
THREAD 865b2da8 Cid 0004.003c Teb: 00000000 Win32Thread: 00000000 RUNNING on processor 0
Not impersonating
DeviceMap e1004438
Owning Process 0 Image: <Unknown>
Attached Process 865b5490 Image: System
Wait Start TickCount 19549 Ticks: 0
Context Switch Count 901 IdealProcessor: 0
UserTime 00:00:00.000
KernelTime 00:00:01.062
Start Address nt!ExpWorkerThread (0x80534b02)
Stack Init f78eb000 Current f78ead1c Base f78eb000 Limit f78e8000 Call 0
Priority 13 BasePriority 12 PriorityDecrement 0 DecrementCount 16
ChildEBP RetAddr Args to Child
f78ead60 8056bcc5 86124338 00000000 8055b0fc NotYourFault!TesterWorkerItemRoutine+0x52 (FPO: [Non-Fpo])
(CONV: stdcall) [c:userskent_huangperforcepd_kent_huangcorevsapipdkent_huangvsapitools
notyourfaultnotyourfaultreverseengineeringworkeritem.c @ 19]
f78ead74 80534c02 86121548 00000000 865b2da8 nt!IopProcessWorkItem+0x13 (FPO: [Non-Fpo])
f78eadac 805c6160 86121548 00000000 00000000 nt!ExpWorkerThread+0x100 (FPO: [Non-Fpo])
f78eaddc 80541dd2 80534b02 00000001 00000000 nt!PspSystemThreadStartup+0x34 (FPO: [Non-Fpo])
00000000 00000000 00000000 00000000 00000000 nt!KiThreadStartup+0x16
Reverse follow API (Win8)
• IoAllocateWorkItem
• IoInitializeWorkItem
• IoQueueWorkItem
• IopQueueWorkItemProlog
• ExQueueWorkItem
Asynchronous Procedure
Calls
• Asynchronous I/O completion, thread suspension, and
process shutdown
• Undocumented API
• Kernel Mode (PASSIVE_LEVEL , APC_LEVEL)
• User Mode (PASSIVE_LEVEL)
• Rootkits achieve this by queueing a user-mode APC to
a thread in the process in which they want to inject
code.
Structure
1: kd> dt _KAPC
nt!_KAPC
+0x000 Type : UChar
+0x001 SpareByte0 : UChar
+0x002 Size : UChar
+0x003 SpareByte1 : UChar
+0x004 SpareLong0 : Uint4B
+0x008 Thread : Ptr32 _KTHREAD
+0x00c ApcListEntry : _LIST_ENTRY
+0x014 KernelRoutine : Ptr32 void
+0x018 RundownRoutine : Ptr32 void
+0x01c NormalRoutine : Ptr32 void
+0x014 Reserved : [3] Ptr32 Void
+0x020 NormalContext : Ptr32 Void
+0x024 SystemArgument1 : Ptr32 Void
+0x028 SystemArgument2 : Ptr32 Void
+0x02c ApcStateIndex : Char
+0x02d ApcMode : Char
+0x02e Inserted : UChar
1: kd> dt _KTHREAD ApcState
nt!_KTHREAD
+0x070 ApcState : _KAPC_STATE
1: kd> dt _KAPC_STATE
nt!_KAPC_STATE
+0x000 ApcListHead : [2] _LIST_ENTRY
+0x010 Process : Ptr32 _KPROCESS
+0x014 InProgressFlags : UChar
+0x014 KernelApcInProgress : Pos 0, 1 Bit
+0x014 SpecialApcInProgress : Pos 1, 1 Bit
+0x015 KernelApcPending : UChar
+0x016 UserApcPending : UChar
Deferred Procedure Calls
• Routines executed at DISPATCH_LEVEL
• Hardware drivers use them to process interrupts
coming from the device
• Some rootkits use DPCs to synchronize access to
global linked lists
IRQL
Structure
1: kd> dt _KDPC
nt!_KDPC
+0x000 TargetInfoAsUlong : Uint4B
+0x000 Type : UChar
+0x001 Importance : UChar
+0x002 Number : Uint2B
+0x004 DpcListEntry : _SINGLE_LIST_ENTRY
+0x008 ProcessorHistory : Uint4B
+0x00c DeferredRoutine : Ptr32 void
+0x010 DeferredContext : Ptr32 Void
+0x014 SystemArgument1 : Ptr32 Void
+0x018 SystemArgument2 : Ptr32 Void
+0x01c DpcData : Ptr32 Void
1: kd> dt _KPRCB DpcData
nt!_KPRCB
+0x21e0 DpcData : [2] _KDPC_DATA
1: kd> dt _KDPC_DATA
nt!_KDPC_DATA
+0x000 DpcList : _KDPC_LIST
+0x008 DpcLock : Uint4B
+0x00c DpcQueueDepth : Int4B
+0x010 DpcCount : Uint4B
+0x014 ActiveDpc : Ptr32 _KDPC
138 Chapter 3 ■ The Windows Kernel
KPRCB KDPC KDPC KDPC
Type Type Type
DpcData[0]
DpcData[1] DpcListEntry DpcListEntry DpcListEntry
DeferredRoutine DeferredRoutine DeferredRoutine
…
… … …
…… …
…
kd> !thread
THREAD 8649d020 Cid 0134.032c Teb: 7ffdf000 Win32Thread: e1634008 RUNNING on processor 0
IRP List:
8692cf68: (0006,0094) Flags: 40000000 Mdl: 00000000
Not impersonating
DeviceMap e21e88b0
Owning Process 0 Image: <Unknown>
Attached Process 864a07f0 Image: ReverseEngineer
Wait Start TickCount 20134 Ticks: 0
Context Switch Count 23 IdealProcessor: 0 LargeStack
UserTime 00:00:00.000
KernelTime 00:00:00.015
Win32 Start Address ReverseEngineeringTester!ILT+1240(_wmainCRTStartup) (0x0042e4dd)
Start Address kernel32!BaseProcessStartThunk (0x7c8106f5)
Stack Init f7517000 Current f7516b8c Base f7517000 Limit f7513000 Call 0
Priority 8 BasePriority 8 PriorityDecrement 0 DecrementCount 0
ChildEBP RetAddr Args to Child
f78b2fd0 80541b8d f7516bc8 00000000 00000000 NotYourFault!TestDpcRoutine+0x52 (FPO: [Non-Fpo]) (CONV:
stdcall) [c:userskent_huangperforcepd_kent_huangcorevsapipdkent_huangvsapitoolsnotyourfault
notyourfaultreverseengineeringworkeritem.c @ 57]
f78b2ff4 8054185a f7516b20 00000000 00000000 nt!KiRetireDpcList+0x46 (FPO: [0,0,0])
f78b2ff8 f7516b20 00000000 00000000 00000000 nt!KiDispatchInterrupt+0x2a (FPO: [Uses EBP] [0,0,1])
WARNING: Frame IP not in any known module. Following frames may be wrong.
8054185a 00000000 00000009 bb835675 00000128 0xf7516b20
Timer
• Signal the expiration of a certain amount of time
• Periodically or at some time in the future
VOID KeInitializeTimer(
_Out_ PKTIMER Timer
);
BOOLEAN KeSetTimer(
_Inout_ PKTIMER Timer,
_In_ LARGE_INTEGER DueTime,
_In_opt_ PKDPC Dpc
);
BOOLEAN KeSetTimerEx(
_Inout_ PKTIMER Timer,
_In_ LARGE_INTEGER DueTime,
_In_ LONG Period,
_In_opt_ PKDPC Dpc
);
Structure
1: kd> dt _KPRCB TimerTable
nt!_KPRCB
+0x2260 TimerTable : _KTIMER_TABLE
1: kd> dt _KTIMER_TABLE
nt!_KTIMER_TABLE
+0x000 TimerExpiry : [16] Ptr32 _KTIMER
+0x040 TimerEntries : [256] _KTIMER_TABLE_ENTRY
1: kd> dt _KTIMER
nt!_KTIMER
+0x000 Header : _DISPATCHER_HEADER
+0x010 DueTime : _ULARGE_INTEGER
+0x018 TimerListEntry : _LIST_ENTRY
+0x020 Dpc : Ptr32 _KDPC
+0x024 Period : Uint4B
1: kd> dt _KTIMER_TABLE_ENTRY
nt!_KTIMER_TABLE_ENTRY
+0x000 Lock : Uint4B
+0x004 Entry : _LIST_ENTRY
+0x010 Time : _ULARGE_INTEGER
Process and Thread
Callbacks
• Callback function when create or terminate process
or thread
• PsSetCreateProcessNotifyRoutine
• PsSetCreateThreadNotifyRoutine
• PsSetLoadImageNotifyRoutine
• Many anti-virus software products register these
callbacks to monitor system behavior.
• Kernel-mode root-kits sometimes use them in
conjunction with APCs to inject code into new
processes
Completion Routines
• Completion routines are used to notify drivers that
their I/O request has been completed
• Use when low-level driver complete a IRP
• IoCompleteRequest, IoSetCompletionRoutine
Structure
1: kd> dt _IO_STACK_LOCATION
nt!_IO_STACK_LOCATION
+0x000 MajorFunction : UChar
+0x001 MinorFunction : UChar
+0x002 Flags : UChar
+0x003 Control : UChar
+0x004 Parameters : <unnamed-tag>
+0x014 DeviceObject : Ptr32 _DEVICE_OBJECT
+0x018 FileObject : Ptr32 _FILE_OBJECT
+0x01c CompletionRoutine : Ptr32 long
+0x020 Context : Ptr32 Void
I/O Request Packets
• Windows uses I/O request packets (IRPs) to
describe I/O requests to kernel- mode components
(like drivers)
• IRP can be divided into two areas
• static, dynamic
• Ex. IRP_MJ_CREATE, IRP_MJ_READ, etc…
146 Chapter 3 ■ The Windows Kernel
IRPStatic Port
Dynamic Port
StackCount
Tail.Overlay.CurrentStackLocation
IO_STACK_LOCATION IO_STACK_LOCATION
“next” IRP stack location
“current” IRP stack location
IO_STACK_LOCATION
IO_STACK_LOCATION
IO_STACK_LOCATION
IO_STACK_LOCATION
an IO request packet relationship between IRP and IO_STACK_LOCATION
in an IO request packet
…
…
…
…
…
kd> dt _IRP
ntdll!_IRP
+0x000 Type : Int2B
+0x002 Size : Uint2B
+0x004 MdlAddress : Ptr32 _MDL
+0x008 Flags : Uint4B
+0x00c AssociatedIrp : __unnamed
+0x010 ThreadListEntry : _LIST_ENTRY
+0x018 IoStatus : _IO_STATUS_BLOCK
+0x020 RequestorMode : Char
+0x021 PendingReturned : UChar
+0x022 StackCount : Char
+0x023 CurrentLocation : Char
+0x024 Cancel : UChar
+0x025 CancelIrql : UChar
+0x026 ApcEnvironment : Char
+0x027 AllocationFlags : UChar
+0x028 UserIosb : Ptr32 _IO_STATUS_BLOCK
+0x02c UserEvent : Ptr32 _KEVENT
+0x030 Overlay : __unnamed
+0x038 CancelRoutine : Ptr32 void
+0x03c UserBuffer : Ptr32 Void
+0x040 Tail : __unnamed
kd> dt _IO_STACK_LOCATION
ntdll!_IO_STACK_LOCATION
+0x000 MajorFunction : UChar
+0x001 MinorFunction : UChar
+0x002 Flags : UChar
+0x003 Control : UChar
+0x004 Parameters : __unnamed
+0x014 DeviceObject : Ptr32 _DEVICE_OBJECT
+0x018 FileObject : Ptr32 _FILE_OBJECT
+0x01c CompletionRoutine : Ptr32 long
+0x020 Context : Ptr32 Void
Structure of a Driver
Kernel Driver
• Type of Kernel Driver
• Legacy software driver
• Legacy filter driver
• File system minifilter driver
How to Write Kernel Driver
• WDM ( Windows Driver Model )
• Defined since Windows 2000 and all drivers you
analyze are based on it
• KMDF ( kernel-mode driver framework )
• WDF is basically a set of libraries built on top of
WDM that simplifies driver development 

Entry Points
• The primary responsibility of DriverEntry
• Initialize driver-specific settings
• Register IRP dispatch routines
DriverEntry:
DriverObject->MajorFunction[IRP_MJ_CREATE] = CreateCloseHandler;
DriverObject->MajorFunction[IRP_MJ_CLOSE] = CreateCloseHandler;
DriverObject->MajorFunction[IRP_MJ_DEVICE_CONTROL] = DeviceControlHandler;
• If you do not initialize the MajorFunction table,
default handler is “IopInvalidDeviceRequest”
• If a driver supports dynamic unloading, it must also
fill out the DriverUnload field
STATUS_INVALID_DEVICE_REQUEST
Driver and Device Objects
typedef struct _DEVICE_OBJECT {
CSHORT Type;
USHORT Size;
LONG ReferenceCount;
struct _DRIVER_OBJECT *DriverObject;
struct _DEVICE_OBJECT *NextDevice;
struct _DEVICE_OBJECT *AttachedDevice;
struct _IRP *CurrentIrp;
...
PVOID DeviceExtension;
DEVICE_TYPE DeviceType;
CCHAR StackSize;
...
ULONG ActiveThreadCount;
PSECURITY_DESCRIPTOR SecurityDescriptor;
...
PVOID Reserved;
} DEVICE_OBJECT, *PDEVICE_OBJECT;
IRP Handling
• The prototype for these dispatch routines
• If the dispatch routine successfully completes:
• Calls IoCompleteRequest and returns
• If it cannot complete:
• Return an error, pass the IRP to another driver, or
pend the IRP
NTSTATUS XXX_Dispatch ( PDEVICE_OBJECT *DeviceObject, PIRP *Irp );
A Common Mechanism for
User-Kernel Communication
• Shared memory region double-mapped in user and
kernel space
• Create an event that a user-mode thread can wait on;
the event state can be used as a trigger for further
action
• Interrupt handling
• IRP_MJ_DEVICE_CONTROL operation and commonly
referred to as device I/O control or simply IOCTL
I/O Control Code
• User-mode code can request these IOCTL
operations through the DeviceIoControl API.
User Mode:
bResult = DeviceIoControl(hDevice, dwIoControlCode, lpInBuffer, nInBufferSize,
lpOutBuffer, nOutBufferSize, lpBytesReturned, &Overlapped);
Kernel Mode:
NTSTATUS DriverEntry(PDRIVER_OBJECT DriverObj, PUNICODE_STRING RegistryPath) {
…
DriverObj->MajorFunction[IRP_MJ_CLEANUP] = DispatchFilter;
DriverObj->MajorFunction[IRP_MJ_DEVICE_CONTROL] = DispatchFilter;
…
}
NTSTATUS DispatchFilter(PDEVICE_OBJECT DeviceObject, PIRP Irp) {
PIO_STACK_LOCATION IrpStack = IoGetCurrentIrpStackLocation(Irp);
switch(IrpStack->MajorFunction) {
…
case IRP_MJ_DEVICE_CONTROL:
// Handle IOCTL
break;
…
}
}
• Buffering Methods
• Buffered I/O
• Direct I/O
• Neither
• I/O Control Code
Miscellaneous System
Mechanisms
• System Control Registers
• Root-kit developers resort to hooking func- tions
in the kernel. But Kernel code is mapped as
Read-Only.
• Protect by hardware level special control register:
CR0
• CPU can write to read-only pages (WP bit)
System Control Registers
KeServiceDescriptorTable
• Many root-kits resort to hooking system calls
• But the system call table (KiServiceTable) is not
exported
• How to access KiServiceTable?
• Ex. Sample G
Sections

Weitere ähnliche Inhalte

Was ist angesagt?

イマドキC++erのモテカワリソース管理術
イマドキC++erのモテカワリソース管理術イマドキC++erのモテカワリソース管理術
イマドキC++erのモテカワリソース管理術Kohsuke Yuasa
 
ret2dl resolve
ret2dl resolveret2dl resolve
ret2dl resolvesounakano
 
Master Canary Forging by Yuki Koike - CODE BLUE 2015
Master Canary Forging by Yuki Koike - CODE BLUE 2015Master Canary Forging by Yuki Koike - CODE BLUE 2015
Master Canary Forging by Yuki Koike - CODE BLUE 2015CODE BLUE
 
DeathNote of Microsoft Windows Kernel
DeathNote of Microsoft Windows KernelDeathNote of Microsoft Windows Kernel
DeathNote of Microsoft Windows KernelPeter Hlavaty
 
Practical Windows Kernel Exploitation
Practical Windows Kernel ExploitationPractical Windows Kernel Exploitation
Practical Windows Kernel ExploitationzeroSteiner
 
Control Your Network ASICs, What Benefits switchdev Can Bring Us
Control Your Network ASICs, What Benefits switchdev Can Bring UsControl Your Network ASICs, What Benefits switchdev Can Bring Us
Control Your Network ASICs, What Benefits switchdev Can Bring UsHungWei Chiu
 
Universal Gates - Aneesa N Ali
Universal Gates - Aneesa N AliUniversal Gates - Aneesa N Ali
Universal Gates - Aneesa N AliDipayan Sarkar
 
Binary exploitation - AIS3
Binary exploitation - AIS3Binary exploitation - AIS3
Binary exploitation - AIS3Angel Boy
 
大義のために:趣味と実益のためのVMware RPCインターフェースの活用 by アブドゥル・アジズ・ハリリ, ジャシエル・スペルマン, ブライアン・ゴーレンク
大義のために:趣味と実益のためのVMware RPCインターフェースの活用 by アブドゥル・アジズ・ハリリ, ジャシエル・スペルマン, ブライアン・ゴーレンク大義のために:趣味と実益のためのVMware RPCインターフェースの活用 by アブドゥル・アジズ・ハリリ, ジャシエル・スペルマン, ブライアン・ゴーレンク
大義のために:趣味と実益のためのVMware RPCインターフェースの活用 by アブドゥル・アジズ・ハリリ, ジャシエル・スペルマン, ブライアン・ゴーレンクCODE BLUE
 
Address/Thread/Memory Sanitizer
Address/Thread/Memory SanitizerAddress/Thread/Memory Sanitizer
Address/Thread/Memory SanitizerPlatonov Sergey
 
Open vSwitchソースコードの全体像
Open vSwitchソースコードの全体像 Open vSwitchソースコードの全体像
Open vSwitchソースコードの全体像 Sho Shimizu
 
A look into the sanitizer family (ASAN & UBSAN) by Akul Pillai
A look into the sanitizer family (ASAN & UBSAN) by Akul PillaiA look into the sanitizer family (ASAN & UBSAN) by Akul Pillai
A look into the sanitizer family (ASAN & UBSAN) by Akul PillaiCysinfo Cyber Security Community
 
Deflate
DeflateDeflate
Deflate7shi
 
コンピュータシステムの理論と実装2
コンピュータシステムの理論と実装2コンピュータシステムの理論と実装2
コンピュータシステムの理論と実装2H T
 
Return to dlresolve
Return to dlresolveReturn to dlresolve
Return to dlresolveAngel Boy
 
CRC-32
CRC-32CRC-32
CRC-327shi
 

Was ist angesagt? (20)

Firewall(linux)
Firewall(linux)Firewall(linux)
Firewall(linux)
 
イマドキC++erのモテカワリソース管理術
イマドキC++erのモテカワリソース管理術イマドキC++erのモテカワリソース管理術
イマドキC++erのモテカワリソース管理術
 
ret2dl resolve
ret2dl resolveret2dl resolve
ret2dl resolve
 
Master Canary Forging by Yuki Koike - CODE BLUE 2015
Master Canary Forging by Yuki Koike - CODE BLUE 2015Master Canary Forging by Yuki Koike - CODE BLUE 2015
Master Canary Forging by Yuki Koike - CODE BLUE 2015
 
DeathNote of Microsoft Windows Kernel
DeathNote of Microsoft Windows KernelDeathNote of Microsoft Windows Kernel
DeathNote of Microsoft Windows Kernel
 
Practical Windows Kernel Exploitation
Practical Windows Kernel ExploitationPractical Windows Kernel Exploitation
Practical Windows Kernel Exploitation
 
Build Programming Language Runtime with LLVM
Build Programming Language Runtime with LLVMBuild Programming Language Runtime with LLVM
Build Programming Language Runtime with LLVM
 
Control Your Network ASICs, What Benefits switchdev Can Bring Us
Control Your Network ASICs, What Benefits switchdev Can Bring UsControl Your Network ASICs, What Benefits switchdev Can Bring Us
Control Your Network ASICs, What Benefits switchdev Can Bring Us
 
Universal Gates - Aneesa N Ali
Universal Gates - Aneesa N AliUniversal Gates - Aneesa N Ali
Universal Gates - Aneesa N Ali
 
Binary exploitation - AIS3
Binary exploitation - AIS3Binary exploitation - AIS3
Binary exploitation - AIS3
 
大義のために:趣味と実益のためのVMware RPCインターフェースの活用 by アブドゥル・アジズ・ハリリ, ジャシエル・スペルマン, ブライアン・ゴーレンク
大義のために:趣味と実益のためのVMware RPCインターフェースの活用 by アブドゥル・アジズ・ハリリ, ジャシエル・スペルマン, ブライアン・ゴーレンク大義のために:趣味と実益のためのVMware RPCインターフェースの活用 by アブドゥル・アジズ・ハリリ, ジャシエル・スペルマン, ブライアン・ゴーレンク
大義のために:趣味と実益のためのVMware RPCインターフェースの活用 by アブドゥル・アジズ・ハリリ, ジャシエル・スペルマン, ブライアン・ゴーレンク
 
Address/Thread/Memory Sanitizer
Address/Thread/Memory SanitizerAddress/Thread/Memory Sanitizer
Address/Thread/Memory Sanitizer
 
Open vSwitchソースコードの全体像
Open vSwitchソースコードの全体像 Open vSwitchソースコードの全体像
Open vSwitchソースコードの全体像
 
A look into the sanitizer family (ASAN & UBSAN) by Akul Pillai
A look into the sanitizer family (ASAN & UBSAN) by Akul PillaiA look into the sanitizer family (ASAN & UBSAN) by Akul Pillai
A look into the sanitizer family (ASAN & UBSAN) by Akul Pillai
 
Deflate
DeflateDeflate
Deflate
 
CPUの同時実行機能
CPUの同時実行機能CPUの同時実行機能
CPUの同時実行機能
 
コンピュータシステムの理論と実装2
コンピュータシステムの理論と実装2コンピュータシステムの理論と実装2
コンピュータシステムの理論と実装2
 
Return to dlresolve
Return to dlresolveReturn to dlresolve
Return to dlresolve
 
Execution
ExecutionExecution
Execution
 
CRC-32
CRC-32CRC-32
CRC-32
 

Andere mochten auch

Windows internals Essentials
Windows internals EssentialsWindows internals Essentials
Windows internals EssentialsJohn Ombagi
 
Information Technology Project Management - part 07
Information Technology Project Management - part 07Information Technology Project Management - part 07
Information Technology Project Management - part 07Rizwan Khurram
 
Windows Internal - Ch9 memory management
Windows Internal - Ch9 memory managementWindows Internal - Ch9 memory management
Windows Internal - Ch9 memory managementKent Huang
 
Clean Code: Chapter 3 Function
Clean Code: Chapter 3 FunctionClean Code: Chapter 3 Function
Clean Code: Chapter 3 FunctionKent Huang
 
Information Technology Project Management - part 10
Information Technology Project Management - part 10Information Technology Project Management - part 10
Information Technology Project Management - part 10Rizwan Khurram
 
Information Technology Project Management - part 04
Information Technology Project Management - part 04Information Technology Project Management - part 04
Information Technology Project Management - part 04Rizwan Khurram
 
Information Technology Project Management - part 08
Information Technology Project Management - part  08Information Technology Project Management - part  08
Information Technology Project Management - part 08Rizwan Khurram
 
Information Technology Project Management - part 12
Information Technology Project Management - part 12Information Technology Project Management - part 12
Information Technology Project Management - part 12Rizwan Khurram
 
Information Technology Project Management - part 09
Information Technology Project Management - part 09Information Technology Project Management - part 09
Information Technology Project Management - part 09Rizwan Khurram
 
Information Technology Project Management - part 05
Information Technology Project Management - part 05Information Technology Project Management - part 05
Information Technology Project Management - part 05Rizwan Khurram
 
Information Technology Project Management - part 01
Information Technology Project Management - part 01Information Technology Project Management - part 01
Information Technology Project Management - part 01Rizwan Khurram
 
Information Technology Project Management - part 11
Information Technology Project Management - part 11Information Technology Project Management - part 11
Information Technology Project Management - part 11Rizwan Khurram
 
Information Technology Project Management
Information Technology Project ManagementInformation Technology Project Management
Information Technology Project ManagementGoutama Bachtiar
 
Information Technology Project Management - part 02
Information Technology Project Management - part 02Information Technology Project Management - part 02
Information Technology Project Management - part 02Rizwan Khurram
 

Andere mochten auch (14)

Windows internals Essentials
Windows internals EssentialsWindows internals Essentials
Windows internals Essentials
 
Information Technology Project Management - part 07
Information Technology Project Management - part 07Information Technology Project Management - part 07
Information Technology Project Management - part 07
 
Windows Internal - Ch9 memory management
Windows Internal - Ch9 memory managementWindows Internal - Ch9 memory management
Windows Internal - Ch9 memory management
 
Clean Code: Chapter 3 Function
Clean Code: Chapter 3 FunctionClean Code: Chapter 3 Function
Clean Code: Chapter 3 Function
 
Information Technology Project Management - part 10
Information Technology Project Management - part 10Information Technology Project Management - part 10
Information Technology Project Management - part 10
 
Information Technology Project Management - part 04
Information Technology Project Management - part 04Information Technology Project Management - part 04
Information Technology Project Management - part 04
 
Information Technology Project Management - part 08
Information Technology Project Management - part  08Information Technology Project Management - part  08
Information Technology Project Management - part 08
 
Information Technology Project Management - part 12
Information Technology Project Management - part 12Information Technology Project Management - part 12
Information Technology Project Management - part 12
 
Information Technology Project Management - part 09
Information Technology Project Management - part 09Information Technology Project Management - part 09
Information Technology Project Management - part 09
 
Information Technology Project Management - part 05
Information Technology Project Management - part 05Information Technology Project Management - part 05
Information Technology Project Management - part 05
 
Information Technology Project Management - part 01
Information Technology Project Management - part 01Information Technology Project Management - part 01
Information Technology Project Management - part 01
 
Information Technology Project Management - part 11
Information Technology Project Management - part 11Information Technology Project Management - part 11
Information Technology Project Management - part 11
 
Information Technology Project Management
Information Technology Project ManagementInformation Technology Project Management
Information Technology Project Management
 
Information Technology Project Management - part 02
Information Technology Project Management - part 02Information Technology Project Management - part 02
Information Technology Project Management - part 02
 

Ähnlich wie Reverse eningeering

Positive Hack Days. Матросов. Мастер-класс: Проведение криминалистической экс...
Positive Hack Days. Матросов. Мастер-класс: Проведение криминалистической экс...Positive Hack Days. Матросов. Мастер-класс: Проведение криминалистической экс...
Positive Hack Days. Матросов. Мастер-класс: Проведение криминалистической экс...Positive Hack Days
 
Проведение криминалистической экспертизы и анализа руткит-программ на примере...
Проведение криминалистической экспертизы и анализа руткит-программ на примере...Проведение криминалистической экспертизы и анализа руткит-программ на примере...
Проведение криминалистической экспертизы и анализа руткит-программ на примере...Alex Matrosov
 
Windbg랑 친해지기
Windbg랑 친해지기Windbg랑 친해지기
Windbg랑 친해지기Ji Hun Kim
 
Troubleshooting Linux Kernel Modules And Device Drivers
Troubleshooting Linux Kernel Modules And Device DriversTroubleshooting Linux Kernel Modules And Device Drivers
Troubleshooting Linux Kernel Modules And Device DriversSatpal Parmar
 
Troubleshooting linux-kernel-modules-and-device-drivers-1233050713693744-1
Troubleshooting linux-kernel-modules-and-device-drivers-1233050713693744-1Troubleshooting linux-kernel-modules-and-device-drivers-1233050713693744-1
Troubleshooting linux-kernel-modules-and-device-drivers-1233050713693744-1Jagadisha Maiya
 
An Embedded Error Recovery and Debugging Mechanism for Scripting Language Ext...
An Embedded Error Recovery and Debugging Mechanism for Scripting Language Ext...An Embedded Error Recovery and Debugging Mechanism for Scripting Language Ext...
An Embedded Error Recovery and Debugging Mechanism for Scripting Language Ext...David Beazley (Dabeaz LLC)
 
The System of Automatic Searching for Vulnerabilities or how to use Taint Ana...
The System of Automatic Searching for Vulnerabilities or how to use Taint Ana...The System of Automatic Searching for Vulnerabilities or how to use Taint Ana...
The System of Automatic Searching for Vulnerabilities or how to use Taint Ana...Positive Hack Days
 
PE102 - a Windows executable format overview (booklet V1)
PE102 - a Windows executable format overview (booklet V1)PE102 - a Windows executable format overview (booklet V1)
PE102 - a Windows executable format overview (booklet V1)Ange Albertini
 
Jurczyk windows kernel reference count vulnerabilities. case study
Jurczyk   windows kernel reference count vulnerabilities. case studyJurczyk   windows kernel reference count vulnerabilities. case study
Jurczyk windows kernel reference count vulnerabilities. case studyDefconRussia
 
DPDK layer for porting IPS-IDS
DPDK layer for porting IPS-IDSDPDK layer for porting IPS-IDS
DPDK layer for porting IPS-IDSVipin Varghese
 
A New Framework for Detection
A New Framework for DetectionA New Framework for Detection
A New Framework for DetectionSourcefire VRT
 
Debugging linux kernel tools and techniques
Debugging linux kernel tools and  techniquesDebugging linux kernel tools and  techniques
Debugging linux kernel tools and techniquesSatpal Parmar
 
DEF CON 24 - Patrick Wardle - 99 problems little snitch
DEF CON 24 - Patrick Wardle - 99 problems little snitchDEF CON 24 - Patrick Wardle - 99 problems little snitch
DEF CON 24 - Patrick Wardle - 99 problems little snitchFelipe Prado
 
Attack your Trusted Core
Attack your Trusted CoreAttack your Trusted Core
Attack your Trusted CoreDi Shen
 
Reverse engineering20151112
Reverse engineering20151112Reverse engineering20151112
Reverse engineering20151112Bordeaux I
 
BPF: Tracing and more
BPF: Tracing and moreBPF: Tracing and more
BPF: Tracing and moreBrendan Gregg
 
HKG18-TR14 - Postmortem Debugging with Coresight
HKG18-TR14 - Postmortem Debugging with CoresightHKG18-TR14 - Postmortem Debugging with Coresight
HKG18-TR14 - Postmortem Debugging with CoresightLinaro
 
Devirtualizing FinSpy
Devirtualizing FinSpyDevirtualizing FinSpy
Devirtualizing FinSpyjduart
 

Ähnlich wie Reverse eningeering (20)

Positive Hack Days. Матросов. Мастер-класс: Проведение криминалистической экс...
Positive Hack Days. Матросов. Мастер-класс: Проведение криминалистической экс...Positive Hack Days. Матросов. Мастер-класс: Проведение криминалистической экс...
Positive Hack Days. Матросов. Мастер-класс: Проведение криминалистической экс...
 
Проведение криминалистической экспертизы и анализа руткит-программ на примере...
Проведение криминалистической экспертизы и анализа руткит-программ на примере...Проведение криминалистической экспертизы и анализа руткит-программ на примере...
Проведение криминалистической экспертизы и анализа руткит-программ на примере...
 
Windbg랑 친해지기
Windbg랑 친해지기Windbg랑 친해지기
Windbg랑 친해지기
 
SdE2 - Pilot Tock
SdE2 - Pilot TockSdE2 - Pilot Tock
SdE2 - Pilot Tock
 
Troubleshooting Linux Kernel Modules And Device Drivers
Troubleshooting Linux Kernel Modules And Device DriversTroubleshooting Linux Kernel Modules And Device Drivers
Troubleshooting Linux Kernel Modules And Device Drivers
 
Troubleshooting linux-kernel-modules-and-device-drivers-1233050713693744-1
Troubleshooting linux-kernel-modules-and-device-drivers-1233050713693744-1Troubleshooting linux-kernel-modules-and-device-drivers-1233050713693744-1
Troubleshooting linux-kernel-modules-and-device-drivers-1233050713693744-1
 
An Embedded Error Recovery and Debugging Mechanism for Scripting Language Ext...
An Embedded Error Recovery and Debugging Mechanism for Scripting Language Ext...An Embedded Error Recovery and Debugging Mechanism for Scripting Language Ext...
An Embedded Error Recovery and Debugging Mechanism for Scripting Language Ext...
 
The System of Automatic Searching for Vulnerabilities or how to use Taint Ana...
The System of Automatic Searching for Vulnerabilities or how to use Taint Ana...The System of Automatic Searching for Vulnerabilities or how to use Taint Ana...
The System of Automatic Searching for Vulnerabilities or how to use Taint Ana...
 
Linux boot-time
Linux boot-timeLinux boot-time
Linux boot-time
 
PE102 - a Windows executable format overview (booklet V1)
PE102 - a Windows executable format overview (booklet V1)PE102 - a Windows executable format overview (booklet V1)
PE102 - a Windows executable format overview (booklet V1)
 
Jurczyk windows kernel reference count vulnerabilities. case study
Jurczyk   windows kernel reference count vulnerabilities. case studyJurczyk   windows kernel reference count vulnerabilities. case study
Jurczyk windows kernel reference count vulnerabilities. case study
 
DPDK layer for porting IPS-IDS
DPDK layer for porting IPS-IDSDPDK layer for porting IPS-IDS
DPDK layer for porting IPS-IDS
 
A New Framework for Detection
A New Framework for DetectionA New Framework for Detection
A New Framework for Detection
 
Debugging linux kernel tools and techniques
Debugging linux kernel tools and  techniquesDebugging linux kernel tools and  techniques
Debugging linux kernel tools and techniques
 
DEF CON 24 - Patrick Wardle - 99 problems little snitch
DEF CON 24 - Patrick Wardle - 99 problems little snitchDEF CON 24 - Patrick Wardle - 99 problems little snitch
DEF CON 24 - Patrick Wardle - 99 problems little snitch
 
Attack your Trusted Core
Attack your Trusted CoreAttack your Trusted Core
Attack your Trusted Core
 
Reverse engineering20151112
Reverse engineering20151112Reverse engineering20151112
Reverse engineering20151112
 
BPF: Tracing and more
BPF: Tracing and moreBPF: Tracing and more
BPF: Tracing and more
 
HKG18-TR14 - Postmortem Debugging with Coresight
HKG18-TR14 - Postmortem Debugging with CoresightHKG18-TR14 - Postmortem Debugging with Coresight
HKG18-TR14 - Postmortem Debugging with Coresight
 
Devirtualizing FinSpy
Devirtualizing FinSpyDevirtualizing FinSpy
Devirtualizing FinSpy
 

Kürzlich hochgeladen

Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdfPearlKirahMaeRagusta1
 
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...Jittipong Loespradit
 
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesVictorSzoltysek
 
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrainmasabamasaba
 
%in Midrand+277-882-255-28 abortion pills for sale in midrand
%in Midrand+277-882-255-28 abortion pills for sale in midrand%in Midrand+277-882-255-28 abortion pills for sale in midrand
%in Midrand+277-882-255-28 abortion pills for sale in midrandmasabamasaba
 
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfonteinmasabamasaba
 
Pharm-D Biostatistics and Research methodology
Pharm-D Biostatistics and Research methodologyPharm-D Biostatistics and Research methodology
Pharm-D Biostatistics and Research methodologyAnusha Are
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️Delhi Call girls
 
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfonteinmasabamasaba
 
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park %in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park masabamasaba
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech studentsHimanshiGarg82
 
BUS PASS MANGEMENT SYSTEM USING PHP.pptx
BUS PASS MANGEMENT SYSTEM USING PHP.pptxBUS PASS MANGEMENT SYSTEM USING PHP.pptx
BUS PASS MANGEMENT SYSTEM USING PHP.pptxalwaysnagaraju26
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfproinshot.com
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfkalichargn70th171
 
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdfPayment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdfkalichargn70th171
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...ICS
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...Shane Coughlan
 
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park %in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park masabamasaba
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...Health
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVshikhaohhpro
 

Kürzlich hochgeladen (20)

Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdf
 
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
 
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
 
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
 
%in Midrand+277-882-255-28 abortion pills for sale in midrand
%in Midrand+277-882-255-28 abortion pills for sale in midrand%in Midrand+277-882-255-28 abortion pills for sale in midrand
%in Midrand+277-882-255-28 abortion pills for sale in midrand
 
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
 
Pharm-D Biostatistics and Research methodology
Pharm-D Biostatistics and Research methodologyPharm-D Biostatistics and Research methodology
Pharm-D Biostatistics and Research methodology
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
 
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park %in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students
 
BUS PASS MANGEMENT SYSTEM USING PHP.pptx
BUS PASS MANGEMENT SYSTEM USING PHP.pptxBUS PASS MANGEMENT SYSTEM USING PHP.pptx
BUS PASS MANGEMENT SYSTEM USING PHP.pptx
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdf
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdfPayment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
 
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park %in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 

Reverse eningeering

  • 1. Reverse Engineering The Windows Kernel (2) Kent Huang
  • 3. Introduce the Component inside Windows Kernel 1. Usage 2. Introduce the data structure 3. How it work inside Windows Kernel 4. What’s the usage in root-kit 5. Exercises
  • 4. System Threads • Driver may create multiple threads handling different requests from kernel or user. • Call API PsCreateSystemThread NTSTATUS PsCreateSystemThread( _Out_ PHANDLE ThreadHandle, _In_ ULONG DesiredAccess, _In_opt_ POBJECT_ATTRIBUTES ObjectAttributes, _In_opt_ HANDLE ProcessHandle, _Out_opt_ PCLIENT_ID ClientId, _In_ PKSTART_ROUTINE StartRoutine, _In_opt_ PVOID StartContext );
  • 5. System Threads • If process handle is not NULL, thread will be created under that process. • Someone say, if call PsCreateSystemThread in an IOCTL handler, the new thread will be in the user- mode application ???
  • 6. Exercises • Determine whether any of them pass a non-NULL ProcessHandle parameter. Explain the purpose of these routines. Repeat the exercise for as many functions as possible.
  • 7. Work Items • Similar to system threads • Except that no physical thread object • Common driver programming pattern to queue work items inside a DPC PIO_WORKITEM IoAllocateWorkItem( _In_ PDEVICE_OBJECT DeviceObject ); VOID IoQueueWorkItem( _In_ PIO_WORKITEM IoWorkItem, _In_ PIO_WORKITEM_ROUTINE WorkerRoutine, _In_ WORK_QUEUE_TYPE QueueType, _In_opt_ PVOID Context );
  • 8. Structure 1: kd> dt _IO_WORKITEM nt!_IO_WORKITEM +0x000 WorkItem : _WORK_QUEUE_ITEM +0x010 Routine : Ptr32 void +0x014 IoObject : Ptr32 Void +0x018 Context : Ptr32 Void +0x01c Type : Uint4B +0x020 ActivityId : _GUID 1: kd> dt _WORK_QUEUE_ITEM nt!_WORK_QUEUE_ITEM +0x000 List : _LIST_ENTRY +0x008 WorkerRoutine : Ptr32 void +0x00c Parameter : Ptr32 Void 1: kd> dt _WORK_QUEUE_TYPE TmXPFlt!_WORK_QUEUE_TYPE CriticalWorkQueue = 0n0 DelayedWorkQueue = 0n1 HyperCriticalWorkQueue = 0n2 MaximumWorkQueue = 0n3 1: kd> dt _KPRCB ParentNode nt!_KPRCB +0x338 ParentNode : Ptr32 _KNODE 1: kd> dt _KNODE nt!_KNODE +0x000 DeepIdleSet : Uint4B +0x004 SharedReadyQueueLeaders : Uint4B +0x040 ProximityId : Uint4B +0x044 NodeNumber : Uint2B … 1: kd> dt _ENODE nt!_ENODE +0x000 Ncb : _KNODE +0x0c0 ExWorkQueue : [2] _EX_WORK_QUEUE … 1: kd> dt _EX_WORK_QUEUE nt!_EX_WORK_QUEUE +0x000 WorkPriQueue : _KPRIQUEUE +0x19c WorkItemsProcessed : Uint4B +0x1a0 WorkItemsProcessedLastPass : Uint4B +0x1a4 ThreadCount : Int4B +0x1a8 TryFailed : UChar
  • 9. kd> !thread THREAD 865b2da8 Cid 0004.003c Teb: 00000000 Win32Thread: 00000000 RUNNING on processor 0 Not impersonating DeviceMap e1004438 Owning Process 0 Image: <Unknown> Attached Process 865b5490 Image: System Wait Start TickCount 19549 Ticks: 0 Context Switch Count 901 IdealProcessor: 0 UserTime 00:00:00.000 KernelTime 00:00:01.062 Start Address nt!ExpWorkerThread (0x80534b02) Stack Init f78eb000 Current f78ead1c Base f78eb000 Limit f78e8000 Call 0 Priority 13 BasePriority 12 PriorityDecrement 0 DecrementCount 16 ChildEBP RetAddr Args to Child f78ead60 8056bcc5 86124338 00000000 8055b0fc NotYourFault!TesterWorkerItemRoutine+0x52 (FPO: [Non-Fpo]) (CONV: stdcall) [c:userskent_huangperforcepd_kent_huangcorevsapipdkent_huangvsapitools notyourfaultnotyourfaultreverseengineeringworkeritem.c @ 19] f78ead74 80534c02 86121548 00000000 865b2da8 nt!IopProcessWorkItem+0x13 (FPO: [Non-Fpo]) f78eadac 805c6160 86121548 00000000 00000000 nt!ExpWorkerThread+0x100 (FPO: [Non-Fpo]) f78eaddc 80541dd2 80534b02 00000001 00000000 nt!PspSystemThreadStartup+0x34 (FPO: [Non-Fpo]) 00000000 00000000 00000000 00000000 00000000 nt!KiThreadStartup+0x16
  • 10. Reverse follow API (Win8) • IoAllocateWorkItem • IoInitializeWorkItem • IoQueueWorkItem • IopQueueWorkItemProlog • ExQueueWorkItem
  • 11. Asynchronous Procedure Calls • Asynchronous I/O completion, thread suspension, and process shutdown • Undocumented API • Kernel Mode (PASSIVE_LEVEL , APC_LEVEL) • User Mode (PASSIVE_LEVEL) • Rootkits achieve this by queueing a user-mode APC to a thread in the process in which they want to inject code.
  • 12. Structure 1: kd> dt _KAPC nt!_KAPC +0x000 Type : UChar +0x001 SpareByte0 : UChar +0x002 Size : UChar +0x003 SpareByte1 : UChar +0x004 SpareLong0 : Uint4B +0x008 Thread : Ptr32 _KTHREAD +0x00c ApcListEntry : _LIST_ENTRY +0x014 KernelRoutine : Ptr32 void +0x018 RundownRoutine : Ptr32 void +0x01c NormalRoutine : Ptr32 void +0x014 Reserved : [3] Ptr32 Void +0x020 NormalContext : Ptr32 Void +0x024 SystemArgument1 : Ptr32 Void +0x028 SystemArgument2 : Ptr32 Void +0x02c ApcStateIndex : Char +0x02d ApcMode : Char +0x02e Inserted : UChar 1: kd> dt _KTHREAD ApcState nt!_KTHREAD +0x070 ApcState : _KAPC_STATE 1: kd> dt _KAPC_STATE nt!_KAPC_STATE +0x000 ApcListHead : [2] _LIST_ENTRY +0x010 Process : Ptr32 _KPROCESS +0x014 InProgressFlags : UChar +0x014 KernelApcInProgress : Pos 0, 1 Bit +0x014 SpecialApcInProgress : Pos 1, 1 Bit +0x015 KernelApcPending : UChar +0x016 UserApcPending : UChar
  • 13. Deferred Procedure Calls • Routines executed at DISPATCH_LEVEL • Hardware drivers use them to process interrupts coming from the device • Some rootkits use DPCs to synchronize access to global linked lists
  • 14. IRQL
  • 15. Structure 1: kd> dt _KDPC nt!_KDPC +0x000 TargetInfoAsUlong : Uint4B +0x000 Type : UChar +0x001 Importance : UChar +0x002 Number : Uint2B +0x004 DpcListEntry : _SINGLE_LIST_ENTRY +0x008 ProcessorHistory : Uint4B +0x00c DeferredRoutine : Ptr32 void +0x010 DeferredContext : Ptr32 Void +0x014 SystemArgument1 : Ptr32 Void +0x018 SystemArgument2 : Ptr32 Void +0x01c DpcData : Ptr32 Void 1: kd> dt _KPRCB DpcData nt!_KPRCB +0x21e0 DpcData : [2] _KDPC_DATA 1: kd> dt _KDPC_DATA nt!_KDPC_DATA +0x000 DpcList : _KDPC_LIST +0x008 DpcLock : Uint4B +0x00c DpcQueueDepth : Int4B +0x010 DpcCount : Uint4B +0x014 ActiveDpc : Ptr32 _KDPC 138 Chapter 3 ■ The Windows Kernel KPRCB KDPC KDPC KDPC Type Type Type DpcData[0] DpcData[1] DpcListEntry DpcListEntry DpcListEntry DeferredRoutine DeferredRoutine DeferredRoutine … … … … …… … …
  • 16. kd> !thread THREAD 8649d020 Cid 0134.032c Teb: 7ffdf000 Win32Thread: e1634008 RUNNING on processor 0 IRP List: 8692cf68: (0006,0094) Flags: 40000000 Mdl: 00000000 Not impersonating DeviceMap e21e88b0 Owning Process 0 Image: <Unknown> Attached Process 864a07f0 Image: ReverseEngineer Wait Start TickCount 20134 Ticks: 0 Context Switch Count 23 IdealProcessor: 0 LargeStack UserTime 00:00:00.000 KernelTime 00:00:00.015 Win32 Start Address ReverseEngineeringTester!ILT+1240(_wmainCRTStartup) (0x0042e4dd) Start Address kernel32!BaseProcessStartThunk (0x7c8106f5) Stack Init f7517000 Current f7516b8c Base f7517000 Limit f7513000 Call 0 Priority 8 BasePriority 8 PriorityDecrement 0 DecrementCount 0 ChildEBP RetAddr Args to Child f78b2fd0 80541b8d f7516bc8 00000000 00000000 NotYourFault!TestDpcRoutine+0x52 (FPO: [Non-Fpo]) (CONV: stdcall) [c:userskent_huangperforcepd_kent_huangcorevsapipdkent_huangvsapitoolsnotyourfault notyourfaultreverseengineeringworkeritem.c @ 57] f78b2ff4 8054185a f7516b20 00000000 00000000 nt!KiRetireDpcList+0x46 (FPO: [0,0,0]) f78b2ff8 f7516b20 00000000 00000000 00000000 nt!KiDispatchInterrupt+0x2a (FPO: [Uses EBP] [0,0,1]) WARNING: Frame IP not in any known module. Following frames may be wrong. 8054185a 00000000 00000009 bb835675 00000128 0xf7516b20
  • 17. Timer • Signal the expiration of a certain amount of time • Periodically or at some time in the future VOID KeInitializeTimer( _Out_ PKTIMER Timer ); BOOLEAN KeSetTimer( _Inout_ PKTIMER Timer, _In_ LARGE_INTEGER DueTime, _In_opt_ PKDPC Dpc ); BOOLEAN KeSetTimerEx( _Inout_ PKTIMER Timer, _In_ LARGE_INTEGER DueTime, _In_ LONG Period, _In_opt_ PKDPC Dpc );
  • 18. Structure 1: kd> dt _KPRCB TimerTable nt!_KPRCB +0x2260 TimerTable : _KTIMER_TABLE 1: kd> dt _KTIMER_TABLE nt!_KTIMER_TABLE +0x000 TimerExpiry : [16] Ptr32 _KTIMER +0x040 TimerEntries : [256] _KTIMER_TABLE_ENTRY 1: kd> dt _KTIMER nt!_KTIMER +0x000 Header : _DISPATCHER_HEADER +0x010 DueTime : _ULARGE_INTEGER +0x018 TimerListEntry : _LIST_ENTRY +0x020 Dpc : Ptr32 _KDPC +0x024 Period : Uint4B 1: kd> dt _KTIMER_TABLE_ENTRY nt!_KTIMER_TABLE_ENTRY +0x000 Lock : Uint4B +0x004 Entry : _LIST_ENTRY +0x010 Time : _ULARGE_INTEGER
  • 19. Process and Thread Callbacks • Callback function when create or terminate process or thread • PsSetCreateProcessNotifyRoutine • PsSetCreateThreadNotifyRoutine • PsSetLoadImageNotifyRoutine
  • 20. • Many anti-virus software products register these callbacks to monitor system behavior. • Kernel-mode root-kits sometimes use them in conjunction with APCs to inject code into new processes
  • 21. Completion Routines • Completion routines are used to notify drivers that their I/O request has been completed • Use when low-level driver complete a IRP • IoCompleteRequest, IoSetCompletionRoutine
  • 22. Structure 1: kd> dt _IO_STACK_LOCATION nt!_IO_STACK_LOCATION +0x000 MajorFunction : UChar +0x001 MinorFunction : UChar +0x002 Flags : UChar +0x003 Control : UChar +0x004 Parameters : <unnamed-tag> +0x014 DeviceObject : Ptr32 _DEVICE_OBJECT +0x018 FileObject : Ptr32 _FILE_OBJECT +0x01c CompletionRoutine : Ptr32 long +0x020 Context : Ptr32 Void
  • 24. • Windows uses I/O request packets (IRPs) to describe I/O requests to kernel- mode components (like drivers) • IRP can be divided into two areas • static, dynamic • Ex. IRP_MJ_CREATE, IRP_MJ_READ, etc…
  • 25. 146 Chapter 3 ■ The Windows Kernel IRPStatic Port Dynamic Port StackCount Tail.Overlay.CurrentStackLocation IO_STACK_LOCATION IO_STACK_LOCATION “next” IRP stack location “current” IRP stack location IO_STACK_LOCATION IO_STACK_LOCATION IO_STACK_LOCATION IO_STACK_LOCATION an IO request packet relationship between IRP and IO_STACK_LOCATION in an IO request packet … … … … … kd> dt _IRP ntdll!_IRP +0x000 Type : Int2B +0x002 Size : Uint2B +0x004 MdlAddress : Ptr32 _MDL +0x008 Flags : Uint4B +0x00c AssociatedIrp : __unnamed +0x010 ThreadListEntry : _LIST_ENTRY +0x018 IoStatus : _IO_STATUS_BLOCK +0x020 RequestorMode : Char +0x021 PendingReturned : UChar +0x022 StackCount : Char +0x023 CurrentLocation : Char +0x024 Cancel : UChar +0x025 CancelIrql : UChar +0x026 ApcEnvironment : Char +0x027 AllocationFlags : UChar +0x028 UserIosb : Ptr32 _IO_STATUS_BLOCK +0x02c UserEvent : Ptr32 _KEVENT +0x030 Overlay : __unnamed +0x038 CancelRoutine : Ptr32 void +0x03c UserBuffer : Ptr32 Void +0x040 Tail : __unnamed kd> dt _IO_STACK_LOCATION ntdll!_IO_STACK_LOCATION +0x000 MajorFunction : UChar +0x001 MinorFunction : UChar +0x002 Flags : UChar +0x003 Control : UChar +0x004 Parameters : __unnamed +0x014 DeviceObject : Ptr32 _DEVICE_OBJECT +0x018 FileObject : Ptr32 _FILE_OBJECT +0x01c CompletionRoutine : Ptr32 long +0x020 Context : Ptr32 Void
  • 26. Structure of a Driver
  • 27. Kernel Driver • Type of Kernel Driver • Legacy software driver • Legacy filter driver • File system minifilter driver
  • 28. How to Write Kernel Driver • WDM ( Windows Driver Model ) • Defined since Windows 2000 and all drivers you analyze are based on it • KMDF ( kernel-mode driver framework ) • WDF is basically a set of libraries built on top of WDM that simplifies driver development 

  • 29. Entry Points • The primary responsibility of DriverEntry • Initialize driver-specific settings • Register IRP dispatch routines DriverEntry: DriverObject->MajorFunction[IRP_MJ_CREATE] = CreateCloseHandler; DriverObject->MajorFunction[IRP_MJ_CLOSE] = CreateCloseHandler; DriverObject->MajorFunction[IRP_MJ_DEVICE_CONTROL] = DeviceControlHandler;
  • 30. • If you do not initialize the MajorFunction table, default handler is “IopInvalidDeviceRequest” • If a driver supports dynamic unloading, it must also fill out the DriverUnload field
  • 32. Driver and Device Objects typedef struct _DEVICE_OBJECT { CSHORT Type; USHORT Size; LONG ReferenceCount; struct _DRIVER_OBJECT *DriverObject; struct _DEVICE_OBJECT *NextDevice; struct _DEVICE_OBJECT *AttachedDevice; struct _IRP *CurrentIrp; ... PVOID DeviceExtension; DEVICE_TYPE DeviceType; CCHAR StackSize; ... ULONG ActiveThreadCount; PSECURITY_DESCRIPTOR SecurityDescriptor; ... PVOID Reserved; } DEVICE_OBJECT, *PDEVICE_OBJECT;
  • 33. IRP Handling • The prototype for these dispatch routines • If the dispatch routine successfully completes: • Calls IoCompleteRequest and returns • If it cannot complete: • Return an error, pass the IRP to another driver, or pend the IRP NTSTATUS XXX_Dispatch ( PDEVICE_OBJECT *DeviceObject, PIRP *Irp );
  • 34. A Common Mechanism for User-Kernel Communication • Shared memory region double-mapped in user and kernel space • Create an event that a user-mode thread can wait on; the event state can be used as a trigger for further action • Interrupt handling • IRP_MJ_DEVICE_CONTROL operation and commonly referred to as device I/O control or simply IOCTL
  • 35. I/O Control Code • User-mode code can request these IOCTL operations through the DeviceIoControl API. User Mode: bResult = DeviceIoControl(hDevice, dwIoControlCode, lpInBuffer, nInBufferSize, lpOutBuffer, nOutBufferSize, lpBytesReturned, &Overlapped); Kernel Mode: NTSTATUS DriverEntry(PDRIVER_OBJECT DriverObj, PUNICODE_STRING RegistryPath) { … DriverObj->MajorFunction[IRP_MJ_CLEANUP] = DispatchFilter; DriverObj->MajorFunction[IRP_MJ_DEVICE_CONTROL] = DispatchFilter; … } NTSTATUS DispatchFilter(PDEVICE_OBJECT DeviceObject, PIRP Irp) { PIO_STACK_LOCATION IrpStack = IoGetCurrentIrpStackLocation(Irp); switch(IrpStack->MajorFunction) { … case IRP_MJ_DEVICE_CONTROL: // Handle IOCTL break; … } }
  • 36. • Buffering Methods • Buffered I/O • Direct I/O • Neither • I/O Control Code
  • 37. Miscellaneous System Mechanisms • System Control Registers • Root-kit developers resort to hooking func- tions in the kernel. But Kernel code is mapped as Read-Only. • Protect by hardware level special control register: CR0 • CPU can write to read-only pages (WP bit)
  • 39. KeServiceDescriptorTable • Many root-kits resort to hooking system calls • But the system call table (KiServiceTable) is not exported • How to access KiServiceTable? • Ex. Sample G
  • 40.