Table of Contents

Interface ITotpValidator

Namespace
GastroSky.Services.Totp.TotpValidator
Assembly
GastroSky.dll

2FA TOTP validator service. Implements the ITotpValidator interface.

public interface ITotpValidator

Methods

ValidateTotp(string?, string?)

Validates a TOTP against a given TOTP secret string.

bool ValidateTotp(string? totpSecret, string? totp)

Parameters

totpSecret string

The Base32-encoded TOTP secret.

totp string

TOTP to validate.

Returns

bool

true if the TOTP 2FA validation succeeded, false if the code was not correct.

See Also