feat(HomeController): Funktion zur Überprüfung des Authenticator-Codes hinzugefügt.
This commit is contained in:
@@ -4,7 +4,7 @@ namespace EnvelopeGenerator.Extensions
|
||||
{
|
||||
public static class StringExtension
|
||||
{
|
||||
public static bool IsValidTotp(string totp, string secret)
|
||||
public static bool IsValidTotp(this string totp, string secret)
|
||||
{
|
||||
var secret_bytes = Base32Encoding.ToBytes(secret);
|
||||
var secret_totp = new Totp(secret_bytes);
|
||||
|
||||
Reference in New Issue
Block a user