- 注册时间
- 2021-4-16
- 最后登录
- 2024-7-3
- 在线时间
- 3 小时
编程入门
- 龙马币
- 48
|
相关代码:
- #pragma once
- #include<ntifs.h>
- #include<windef.h>
- #define READCODE CTL_CODE(FILE_DEVICE_UNKNOWN,0x800,METHOD_BUFFERED,FILE_ALL_ACCESS)
- #define WRITECODE CTL_CODE(FILE_DEVICE_UNKNOWN,0x801,METHOD_BUFFERED,FILE_ALL_ACCESS)
- #define DEVICENAME L"\\Device\\ReadWriteDevice"
- #define SYMBOLNAME L"\\??\\ReadWriteSymbolName"
- typedef struct DATA
- {
- DWORD pid;//要读写的进程ID
- unsigned __int64 address;//要读写的地址
- DWORD size;//读写长度
- BYTE* data;//要读写的数据,
- }Data;
- void DriverUnload(PDRIVER_OBJECT driver);
- NTSTATUS CreateDevice(PDRIVER_OBJECT driver);
- NTSTATUS DriverIrpCtl(PDEVICE_OBJECT device, PIRP pirp);
- BOOL ReadMemory(Data* data);
- BOOL WriteMemory(Data* data);
复制代码
回复后下载源码:
|
|