40楼#
发布于:2007-09-18 23:00
谢谢楼主。能给我发一份代码学习一下么?tianzhengmail@163.com
|
|
|
41楼#
发布于:2007-09-19 10:17
呵呵,看得眼晕中
下回整个正着的哦 支持一下 |
|
42楼#
发布于:2007-09-19 11:31
楼主,给我一份hyzimbtb@163.com
|
|
43楼#
发布于:2007-09-20 10:18
楼主认真,我最偷懒
直接在FileSpy上改了改 |
|
44楼#
发布于:2007-10-05 08:59
楼主,给我一份hoposky@163.com
谢谢了 |
|
|
45楼#
发布于:2007-10-05 16:28
代码已经放出来了,我没想到还有这么多跟我一样的新人,呵呵!
http://bbs.driverdevelop.com/htm_data/39/0709/105273.html |
|
46楼#
发布于:2007-11-05 08:32
|
|
47楼#
发布于:2007-12-17 15:36
好啊。学习一下。
|
|
|
48楼#
发布于:2007-12-17 15:44
//准备绑定C:\的设备
RtlInitUnicodeString(&nameString, L"\\DosDevices\\C:\\"); if (!AttachToDiskDevice(&nameString, &FilterDevice)) 这一段实现跟我发布的函数Attach2C_Volume很像。 |
|
|
49楼#
发布于:2007-12-17 15:48
BOOLEAN Attach2C_Volume()
{ UNICODE_STRING nameString; PDEVICE_OBJECT VolumeDeviceObject; PFILE_OBJECT fileObject; NTSTATUS ntStatus; PSFILTER_DEVICE_EXTENSION sfExtention; PDEVICE_OBJECT fileSysDevice; IO_STATUS_BLOCK ioStatus; HANDLE ntFileHandle; OBJECT_ATTRIBUTES objectAttributes; PAGED_CODE(); RtlInitUnicodeString( &nameString, L"\\DosDevices\\C:\\" ); InitializeObjectAttributes( &objectAttributes, &nameString, OBJ_CASE_INSENSITIVE, NULL, NULL ); ntStatus = ZwCreateFile( &ntFileHandle, SYNCHRONIZE|FILE_ANY_ACCESS, &objectAttributes, &ioStatus, NULL, 0, FILE_SHARE_READ|FILE_SHARE_WRITE, FILE_OPEN, FILE_SYNCHRONOUS_IO_NONALERT|FILE_DIRECTORY_FILE, NULL, 0 ); if( !NT_SUCCESS( ntStatus ) ) { //DbgPrint(("Filemon: Could not open drive %c: \n", 'C'+0)); return FALSE; } DbgPrint(("Filemon: opened the root directory!!! handle: %x\n", ntFileHandle)); ntStatus = ObReferenceObjectByHandle( ntFileHandle, FILE_READ_DATA, NULL, KernelMode, &fileObject, NULL ); if( !NT_SUCCESS( ntStatus )) { ZwClose( ntFileHandle ); return FALSE; } fileSysDevice = IoGetRelatedDeviceObject( fileObject ); if( ! fileSysDevice ) { ObDereferenceObject( fileObject ); ZwClose( ntFileHandle ); return FALSE; } ntStatus = IoCreateDevice( gSFilterDriverObject, sizeof(SFILTER_DEVICE_EXTENSION), NULL, fileSysDevice->DeviceType, 0, FALSE, &VolumeDeviceObject ); if( !NT_SUCCESS(ntStatus) ) { ObDereferenceObject( fileObject ); ZwClose( ntFileHandle ); return FALSE; } VolumeDeviceObject->Flags &= ~DO_DEVICE_INITIALIZING; sfExtention = VolumeDeviceObject->DeviceExtension; sfExtention->AttachedToDeviceObject = fileSysDevice; RtlInitUnicodeString(&sfExtention->DeviceName, sfExtention->DeviceNameBuffer); RtlCopyUnicodeString(&sfExtention->DeviceName, &nameString); ntStatus = IoAttachDeviceByPointer( VolumeDeviceObject, fileSysDevice ); if( !NT_SUCCESS(ntStatus) ) { ObDereferenceObject( fileObject ); ZwClose( ntFileHandle ); return FALSE; } ObDereferenceObject( fileObject ); ZwClose( ntFileHandle ); return TRUE; } |
|
|
50楼#
发布于:2007-12-18 16:13
fancylf ,我也是用了虚的隐藏,不过会有问题的
|
|
51楼#
发布于:2007-12-25 10:26
楼主 能给我一份你的代码 本人正在学习中 谢谢
zhou_huawen@hotmail.com |
|
52楼#
发布于:2008-04-21 11:02
楼主可以给我发一份源码么,最近刚刚开始学这个,感觉一塌糊涂,china.jiangdong@163.com
|
|
53楼#
发布于:2008-04-30 13:30
目前还没碰到这个问题
不过楼主的共享精神 超赞! |
|
54楼#
发布于:2008-06-14 20:48
我想知道怎么文件重定向,比如访问d:\aa\33.dll 变成e:\bb\44.dll,有源码学习最好,goyanjie@21cn.com
|
|
55楼#
发布于:2008-06-14 20:53
怎么实现文件重定向,比如访问 d:\aa\33.dll 变成 e:\bb\44.dll,有源码学习吗,goyanjie@21cn.com
|
|
上一页
下一页