Table of Contents

TCustomOtp Class

Base class for generating OTP (One-Time Password) with various configurations.

Syntax

Unit: Sphinx.Otp

TCustomOtp = class(TObject);

Constructors

Name Description
Create Initializes a new instance of the TCustomOtp class.

Properties

Name Description
Secret Gets or sets the secret key used for OTP generation. The value is Base32-encoded.
HashMode Gets or sets the hash mode for OTP generation.
DigitCount Gets or sets the number of digits in the generated OTP. Value must be between 6 and 8. Default is 6.
WindowLowerDelta Gets or sets the lower delta window for OTP verification.
The value indicates how many past codes will be accepted besides the current one.
WindowUpperDelta Gets or sets the upper delta window for OTP verification.
The value indicates how many future codes will be accepted besides the current one.