0

We are trying to get Windows Hello to work in our Electron.NET application. All we need is a simple keyvaluepair provided by that function.

My first place to look was to check all Nuget packages but found nothing that would work with .Net 7. There were Fido2 and WebAuthn libraries, but I only need the portion that invokes the Windows Hello function. We were able to come up with a simple solution to open the file explorer by importing a function from user32.dll, so I figured why not Windows Hello?

Anyway I've been sifting through documentation for so long I'm reading the same paragraphs twice, and cannot find anything. I created a dump of the user32.dll file to look for anything related to Windows Hello, and found nothing.

powershell "dumpbin /exports C:\Windows\System32\user32.dll | tee user32_functions.txt"

https://pastebin.com/a2cnznCX

Edit, this solution does it. To fix the Referencing a Windows metadata component directly when targeting .NET 5 or higher is not supported. error, you have to specify the version of Windows you want to target in your .csproj.

  • *"All we need is a simple keyvaluepair provided by that function."* - What function? And which key-value pair exactly? Given that Windows Hello was introduced in Windows 10 (I think) it's reasonable to assume that its API is provided by way of Windows Runtime types. Just like (classic) COM you're unlikely to find anything related to it in function exports, other than generic [factory functions](https://learn.microsoft.com/en-us/windows/win32/api/roapi/nf-roapi-rogetactivationfactory). *user32.dll* is certainly the wrong place to be looking for any of this regardless. – IInspectable Oct 29 '22 at 07:45
  • @IInspectable Sorry if I was vague, I'm not exactly sure what I'm looking for and I'm figuring it out as I go. The idea in my head is that Windows Hello can take a 4-digit PIN, or fingerprint, and return some private key I can use for decryption of local data, where that private key will be consistent on the same account on that machine. Bitwarden implements this. The trick is for me it all has to be local, no third party servers or APIs whatsoever. – jamie yello Oct 29 '22 at 08:04

0 Answers0