diff options
author | Florian Dold <florian@dold.me> | 2021-11-04 16:53:04 +0100 |
---|---|---|
committer | Florian Dold <florian@dold.me> | 2021-11-04 16:53:11 +0100 |
commit | 6d6679e33849d551b9da07d5058dc09c474c66b7 (patch) | |
tree | 192410793b30057a0c52612f513c007ecabbfacc /packages/anastasis-core/src/recovery-document-types.ts | |
parent | 83622bd65a0ebd7c22555fb2cfdb542e20d044b9 (diff) | |
download | wallet-core-6d6679e33849d551b9da07d5058dc09c474c66b7.tar.xz |
anastasis-core: support pin-type answers
Diffstat (limited to 'packages/anastasis-core/src/recovery-document-types.ts')
-rw-r--r-- | packages/anastasis-core/src/recovery-document-types.ts | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/packages/anastasis-core/src/recovery-document-types.ts b/packages/anastasis-core/src/recovery-document-types.ts index 74003ccb1..3dc4481ff 100644 --- a/packages/anastasis-core/src/recovery-document-types.ts +++ b/packages/anastasis-core/src/recovery-document-types.ts @@ -1,5 +1,14 @@ import { TruthKey, TruthSalt, TruthUuid } from "./crypto.js"; +export enum ChallengeType { + Question = "question", + Sms = "sms", + Email = "email", + Post = "post", + Totp = "totp", + Iban = "iban", +} + export interface RecoveryDocument { /** * Human-readable name of the secret @@ -9,7 +18,7 @@ export interface RecoveryDocument { /** * Encrypted core secret. - * + * * Variable-size length, base32-crock encoded. */ encrypted_core_secret: string; @@ -56,7 +65,7 @@ export interface EscrowMethod { /** * Type of the escrow method (e.g. security question, SMS etc.). */ - escrow_type: string; + escrow_type: ChallengeType; /** * UUID of the escrow method. |