Certificate a Smart card minidriver
We are developer of a Windows smart card minidriver. We are preparing the driver package for WHCP/HLK certification on x86, x64 and ARM64 (ARM64X build, with an x86 minidriver DLL for 32-bit applications).
Scenario
As documented in the Smart Card Minidriver Specification, the card is registered under:
HKLM\SOFTWARE\Microsoft\Cryptography\Calais\SmartCards<CardName>
ATR, ATRMask, Crypto Provider, Smart Card Key Storage Provider, 80000001, ...
On 64-bit systems the registration must exist in both registry views: the native view, pointing to the native minidriver DLL, and the 32-bit view, pointing to the x86 DLL. Without the 32-bit view entries, 32-bit applications cannot use the card.
We have tried two ways of writing the 32-bit view from the INF, and neither of them is accepted by InfVerif /h.
Option A – explicit Wow6432Node path
[AddRegARM64_x86View]
HKLM, SOFTWARE\Wow6432Node\Microsoft\Cryptography\Calais\SmartCards<CardName>,"80000001",0x00000000,%MinidriverDll32%
...
Works at runtime, but InfVerif /h reports:
WARNING(1304) in MiniDriver.inf, line <n>: Found legacy AddReg operation using non-relative key (HKLM\SOFTWARE\Wow6432Node\Microsoft\Cryptography\Calais\SmartCards<CardName>).
The native-view entries (same path without Wow6432Node) do not produce any warning.
Option B – logical path with FLG_ADDREG_32BITKEY (0x00004000)
[AddRegARM64]
HKLM, SOFTWARE\Microsoft\Cryptography\Calais\SmartCards<CardName>,"80000001",0x00000000,%MinidriverDllNative%
...
[AddRegARM64_x86View]
HKLM, SOFTWARE\Microsoft\Cryptography\Calais\SmartCards<CardName>,"80000001",0x00004000,%MinidriverDll32%
...
InfVerif /h reports one warning per value (80000001, Vendor DLL, SmartCardMiniDriver, ATRMask):
WARNING(1331) in MiniDriver.inf, line <n>: Cannot set registry value 'HKLM\SOFTWARE\Microsoft\Cryptography\Calais\SmartCards<CardName>\80000001' differently between sections [AddRegARM64_x86View] and [AddRegARM64].
It seems InfVerif does not take FLG_ADDREG_32BITKEY into account and treats both sections as writing the same key.
On ARM64 the installer behaves the same way: FLG_ADDREG_32BITKEY appears to be ignored. The values from [AddRegARM64_x86View] are written to the native view, overwriting the native minidriver entries with the x86 DLL, and nothing is created in the 32-bit view:
reg query "HKLM\SOFTWARE\Microsoft\Cryptography\Calais\SmartCards<CardName>" /reg:64
...
SmartCardMiniDriver REG_SZ <MinidriverDll32>
80000001 REG_SZ <MinidriverDll32>
Vendor DLL REG_SZ <MinidriverDll32>
reg query "HKLM\SOFTWARE\Microsoft\Cryptography\Calais\SmartCards<CardName>" /reg:32
ERROR: The system was unable to find the specified registry key or value.
As a result, the card stops working for native (ARM64) processes as well.
Environment
WDK / InfVerif version: 10.0.26100.0
Target: Windows 11 ARM64
Driver type: user-mode smart card minidriver (UMPass), Class = SmartCardFilter
Questions
What is the supported, isolation-compliant way for a smart card minidriver INF to register the card in both the native and the 32-bit registry views?
Is FLG_ADDREG_32BITKEY supposed to be honored for driver package AddReg on ARM64? Both InfVerif (warning 1331) and the installer seem to ignore it.
Are warnings 1304 / 1331 in this scenario blocking for WHCP/HLK submission, or planned to become errors?
Any guidance or pointer to updated documentation would be greatly appreciated.