The Preview sub-domain now hosts the Users With Device 2FA Project.

ASP.NET Core 6.0 - Users With Device 2FA Project


The Users With Device 2FA Project (UWD2FAP) implements ASP.NET Core 6.0 with Visual Studio 2022. The project implements WebAuthn, also known as FIDO2, instead of authenticator apps for two-factor authentication (2FA). The project implements Bootstrap v5 and Bootstrap Native. After a user registers, they can enable 2FA with Windows Hello, Android Lock Screen, or a FIDO2 security key. If I had this project when I created KenHaggerty. Com three years ago, I would have started with this user authentication template. Windows Hello implements authentication with an IR webcam for facial recognition, a fingerprint scanner, or just by setting up and using a PIN. See Learn about Windows Hello and set it up.

I created a new ASP.NET Core 6.0 Razor Pages Project then integrated the ASP.NET Core 5.0 - Users Without Identity Project and the ASP.NET Core 5.0 - Users Without Passwords Project. I enabled the nullable context and mitigated all warnings and issues. I also implemented global usings and file scoped namespaces. The project supports multiple authenticators and authenticator challenge history including failed attempts. Challenges which fail before associating to a known credential are orphaned. Admins can list users, credentials, and all invalid challenges. The latest version is published at Preview. KenHaggerty. Com. I encourage you to register and evaluate multiple 2FA devices in Manage Account > Two-Factor Authentication. Details, screenshots, and related articles can be found at ASP.NET Core 6.0 - Users With Device 2FA Project. The details page includes the version change log.

Quick Start

Also see QuickStart.txt
  • Open the project with Visual Studio.
  • Configure SQL Connection in appsettings.json.
  • Set ConnectionConfigured to true.
  • Configure EmailSettings in appsettings.json.
  • Build, run and test.
EnsureAdministrator > Database.MigrateAsync, creates and updates the database.

Admin Login

Login Name
EnsureAdministrator creates the Administrator user. The Administrator must change the password at first login and enable 2FA.