Hello
How to make Moufiltr as top driver in below list (& above Mouclass), what should be INF or code changes expected. Kindly share any links or tutorials if they are already there.
[
](https://filestore.community.support.microsoft.com/api/images/38c00bf0-304d-47b0-83eb-d519fccdd6b5?upload=true&fud_access=wJJIheezUklbAN2ppeDns8cDNpYs3nCYjgitr%2bfFBh2dqlqMuW7np3F6Utp%2fKMltnRRYFtVjOMO5tpbpW9UyRAwvLeec5emAPixgq9ta07Dgnp2aq5eJbnfd%2fU3qhn54kIhTDuBO%2bj4%2bGFVFVGdRiIbrAe6w6ygVVPDwK8B6gG5M2plSBjPDjV4muqdLPTwjkAk44Z0qVwWGTl%2bJdCy6wUlpjUWPcSnK2%2fOUN3HgmqZYF%2f7C4qAWHaCyyPOVVZN8Z8Y%2fUOhToc6uExP%2fzC7qIO1Xgi9o3Xe9t8%2feu7lt3MqSGC%2fw81eJhRrHPKl0R4m1XlxU3i76ehCk9DcvPDwrZuVJ2%2bYimM2LtZqbPjnJSiXIQLVfK3e0I2r3jC5zMIrkY31EC%2fuucCbbSGt3wM5NGU8ReNGCdsJd2S6ScDnb5RY%3d)
My INF file is as follows,
;/*++
;
; Copyright (c) Microsoft Corporation. All rights reserved.
;
; Module Name:
; moufiltr.inf
;
; Abstract:
; Installation inf for the Device that needs filtering adapter.
;
; Important:
; This INF depends on features for the Driver Store DIRIDs which are available starting Windows 10 1809
;
;--*/
[Version]
Signature="$Windows NT$"
Provider=%ProviderName%
ClassGUID={4D36E96F-E325-11CE-BFC1-08002BE10318}
Class=Mouse
DriverVer=02/05/2008, 1.0.0.0
CatalogFile=KmdfSamples.cat
PnpLockdown=1
[DestinationDirs]
DefaultDestDir = 13
[SourceDisksNames]
1 = %DiskId1%,,,
[SourceDisksFiles]
moufiltr.sys = 1
;
; Driver information
;
[Manufacturer]
%MfgName% = Standard,NT$ARCH$
[Standard.NT$ARCH$]
%HID\VID_17EF&PID_608D.DeviceDesc% = moufiltr, HID\VID_17EF&PID_608D
%HID\VID_17EF&UP:0001_U:0002.DeviceDesc% = moufiltr, HID\VID_17EF&UP:0001_U:0002
;
; General installation section
;
[moufiltr.NT]
; perform port related actions from mouse.inf
Include=msmouse.inf
Needs=HID_Mouse_Inst.NT
; Copy the driver over
CopyFiles=moufiltr.CopyFiles
;
; File sections
;
[moufiltr.CopyFiles]
moufiltr.sys
;
; Service Installation
;
[moufiltr.NT.Services]
AddService = moufiltr, , moufiltr_Service_Inst
; Install the port driver and mouclass from msmouse.inf
Include=msmouse.inf
Needs=HID_Mouse_Inst.NT.Services
[moufiltr_Service_Inst]
DisplayName = %moufiltr.SvcDesc%
ServiceType = 1 ; SERVICE_KERNEL_DRIVER
StartType = 3 ; SERVICE_DEMAND_START
ErrorControl = 0 ; SERVICE_ERROR_IGNORE
ServiceBinary = %13%\moufiltr.sys
[moufiltr.NT.HW]
; Add the device upper filter
AddReg = moufiltr.HW.AddReg
; run the directives need by the port driver
Include=msmouse.inf
Needs=HID_Mouse_Inst.NT.Hw
[moufiltr.HW.AddReg]
HKR,,"UpperFilters",0x00010000,"moufiltr"
[moufiltr.NT.Wdf]
KmdfService = moufiltr, moufiltr_wdfsect
[moufiltr_wdfsect]
KmdfLibraryVersion = $KMDFVERSION$
[Strings]
;
; Non-Localizable Strings
;
REG_SZ = 0x00000000
REG_MULTI_SZ = 0x00010000
REG_EXPAND_SZ = 0x00020000
REG_BINARY = 0x00000001
REG_DWORD = 0x00010001
;
; Localizable Strings
;
ProviderName = "TODO-Set-Provider"
MfgName = "TODO-Set-Manufacturer"
moufiltr.DeviceDesc = "Mouse Filter Sample Device"
; Make sure the service description is unique to avoid collision with another INF.
moufiltr.SvcDesc = "Mouse Filter Sample Driver"
DiskId1 = "Mouse Filter Install Disk"
HID\VID_17EF&PID_608D.DeviceDesc = "Mouse Filter Sample Driver"
HID\VID_17EF&UP:0001_U:0002.DeviceDesc = "Mouse Filter Sample Driver"