从调试启动的INF安装文件系统微型过滤器 [英] Installing file system minifilter from INF launched from debug

查看:156
本文介绍了从调试启动的INF安装文件系统微型过滤器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在研究我的第一个文件系统微型过滤器.我正在WDK中使用SwapBuffers示例项目.我已经成功地将该项目从物理笔记本电脑编译并部署到了VM.但是从INF文件安装失败.我在目标计算机上的C:\ DriverTest \ Logs中查看了日志文件,并在日志文件中找到了这些行.

I am working on my first file system mini-filter. I am using the SwapBuffers sample project in the WDK. I have successfully compiled and deployed this project to a VM from a physical laptop. But the installation from the INF file is failing. I looked in the log file in C:\DriverTest\Logs on the target machine and found these lines in the log file.

UserText="WDTF_TARGETS: Query("HardwareIDs='WDTF\NOEXIST'")"
UserText="WDTF_DRIVER_SETUP_SYSTEM: CreateRootEnumeratedDevicesFromPackage()"
UserText="WDTF_DRIVER_SETUP_SYSTEM:
UserText="WDTF_TEST: System has no device the driver package can  be installed onto."

这是INF文件.它与原始样本相同.

Here is the INF file. It is unmodified from the original sample.

;;; SwapBuffers
;;; Copyright (c) 2001, Microsoft Corporation
[Version]
signature   = "$Windows NT$"
Class       = "Encryption"                              ;This is determined by the work this filter driver does
ClassGuid   = {a0a701c0-a511-42ff-aa6c-06dc0395576f}    ;This value is determined by the Class
Provider    = %Msft%
DriverVer   = 06/16/2007,1.0.0.3
CatalogFile = swapbuffers.cat

[DestinationDirs]
DefaultDestDir          = 12
MiniFilter.DriverFiles  = 12            ;%windir%\system32\drivers

;; Default install sections
[DefaultInstall]
OptionDesc          = %ServiceDescription%
CopyFiles           = MiniFilter.DriverFiles

[DefaultInstall.Services]
AddService          = %ServiceName%,,MiniFilter.Service

;; Default uninstall sections
[DefaultUninstall]
DelFiles   = MiniFilter.DriverFiles

[DefaultUninstall.Services]
DelService = SwapBuffers,0x200      ;Ensure service is stopped before deleting

; Services Section
[MiniFilter.Service]
DisplayName      = %ServiceName%
Description      = %ServiceDescription%
ServiceBinary    = %12%\%DriverName%.sys        ;%windir%\system32\drivers\
Dependencies     = "FltMgr"
ServiceType      = 2                            ;SERVICE_FILE_SYSTEM_DRIVER
;StartType        = 0                           ;SERVICE_BOOT_START
StartType        = 3                            ;SERVICE_DEMAND_START
ErrorControl     = 1                            ;SERVICE_ERROR_NORMAL
LoadOrderGroup   = "FSFilter Encryption"
AddReg           = MiniFilter.AddRegistry

; Registry Modifications
[MiniFilter.AddRegistry]
HKR,,"SupportedFeatures",0x00010001,0x3
HKR,"Instances","DefaultInstance",0x00000000,%Instance1.Name%
HKR,"Instances\"%Instance1.Name%,"Altitude",0x00000000,%Instance1.Altitude%
HKR,"Instances\"%Instance1.Name%,"Flags",0x00010001,%Instance1.Flags%

; Copy Files
[MiniFilter.DriverFiles]
%DriverName%.sys

[SourceDisksFiles]
swapbuffers.sys = 1,,

[SourceDisksNames]
1 = %DiskId1%,,,

;; String Section
[Strings]
Msft                    = "Microsoft Corporation"
ServiceDescription      = "Swap Buffers Sample Mini-Filter Driver"
ServiceName             = "SwapBuffers"
DriverName              = "SwapBuffers"
DiskId1                 = "SwapBuffers Device Installation Disk"

;Instances specific information.
Instance1.Name          = "SwapBuffers Instance"
Instance1.Altitude      = "141000"
Instance1.Flags         = 0x0          ; allow automatic attachments

VMware会话有一个硬盘驱动器,在查看DEVCON时显示为SCSI驱动器.

The VMware session has a single hard drive that shows up as a SCSI drive looking at DEVCON.

谁能告诉我我在这里想念的东西吗?

Can anyone tell me what I'm missing here?

推荐答案

如果您的驱动程序不是用于硬件的,请转到

If your driver is not for a piece of hardware, go to

  1. 选择驱动程序包"
  2. 打开配置"
  3. 转到驱动程序安装"->部署"
  4. 选择不安装"

如果需要,请使用自定义命令,例如用所需的参数运行"svcctrl.exe".

If needed use a custom command e.g. to run "svcctrl.exe" with the desired parameters.

这篇关于从调试启动的INF安装文件系统微型过滤器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆