One Time Password
It's compatible with the Google Authenticator App.
First, we need to create a shared secret (stored on the server and by the client)
var secret = OneTimePassword.CreateSharedSecret();
For a time-based token, we use:
For a counter-based token, we use:
The counter here is 1.
Google Authenticator App
To get a Google Authenticator friendly shared secret:
Referencing from .NET Framework, .NET Core and others
One Time Password targets the .NET Standard 1.6, which should be compatible with .NET Framework 4.6.1 and .NET Core 1.0. For other frameworks, please see this.
It's seems to be important to install NETStandard.Library for everything to work, especially on the .NET Framework.