Documents for @litert/otp / URL / IUrlInfoForHOTP
Interface: IUrlInfoForHOTP
Defined in: URL.ts:81
Extends
Properties
betterCompatibility?
optional
betterCompatibility:boolean
Defined in: URL.ts:31
Do not escape '=' in the key/secret, to improve compatibility with some authenticator apps.
Default
false
Inherited from
digest?
optional
digest:EDigest
Defined in: URL.ts:78
The digest algorithm used to generate the OTP code.
Warning
Not all authenticator apps support SHA256 or SHA512.
Default
'SHA1'
See
- https://datatracker.ietf.org/doc/html/rfc4226#section-5
- https://datatracker.ietf.org/doc/html/rfc6238#section-1.2
Inherited from
digits?
optional
digits:number
Defined in: URL.ts:56
The output width of OTP.
Default
6
Warning
Not all authenticator apps support digits other than 6.
See
https://datatracker.ietf.org/doc/html/rfc4226#section-5
Inherited from
issuer?
optional
issuer:null
|string
Defined in: URL.ts:66
The issuer of OTP code to display in OTP authenticator app.
Inherited from
key
key:
string
|Buffer
<ArrayBufferLike
>
Defined in: URL.ts:40
The key of OTP code.
If the key is a string, it must be BASE32-encoded.
See
https://datatracker.ietf.org/doc/html/rfc4226#section-5.1
Inherited from
label
label:
string
Defined in: URL.ts:61
The label of OTP code to display in OTP authenticator app.
Inherited from
sequence?
optional
sequence:number
Defined in: URL.ts:91
The base sequence of HOTP code.
Default
1
See
https://datatracker.ietf.org/doc/html/rfc4226#appendix-E.3
type
type:
"hotp"
Defined in: URL.ts:83
The type of OTP.