随笔分类 - Kernel
摘要:获取ssdt表中所有函数的地址for (int i = 0; i NumberOfServices; i++){KdPrint(("NumberOfService[%d]-------%X\n", i, KeServiceDescriptorTable->ServiceTableBase[i]));}需要这样定义typedef struct _ServiceDescriptorTable {unsigned int* ServiceTableBase; //System Service Dispatch Table 的基地址 unsigned int* Service
阅读全文
摘要:1 #ifdef __cplusplus 2 extern "C" 3 { 4 #endif 5 #include 6 #ifdef __cplusplus 7 } 8 #endif 9 10 11 typedef struct _ServiceDescriptorTable { 12 unsigned int *ServiceTableBase; //System Service Dispatch Table 的基地址 13 unsigned int *ServiceCounterTable; 14 //包含着 SSDT 中每个服务被调用...
阅读全文
摘要:常识:IRP:I/O Request Package 即输入输出请求包exe和sys通信时,exe会发出I/O请求。操作系统会将I/O请求转化为相应的IRP数据,不同类型传递到不同的dispatch function过程:DeviceIoControl函数产生IRP_MJ_DEVICE_CONTROL 派遣例程DeviceIoControl函数是用来向指定设备发送控制码,当指定的设备接收到DeviceIoControl函数发来的控制码后会调用IRP_MJ_DEVICE_CONTROL对应的派遣例程,针对不同的控制码进行处理。BOOL DeviceIoControl( HANDLE hDevic
阅读全文