You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Mobile flows: https://excalidraw.com/#json=pJTLrSff6hYYAI0fztR2v,F8_Z-kkzbVN1Icd37CMV6Q
6
6
7
7
### High-level description
8
8
9
9
Backup Service stores and manages authentication for encrypted backups represented as binary blobs. The data is stored
10
10
on S3. The service also uses DynamoDB for mapping between factors and backups, as well as for some ephemeral data (e.g. used challenges).
11
11
12
12
A typical backup lifecycle:
13
+
13
14
1.**Creation** (`/create`): Client creates a backup with an authentication factor (passkey, OIDC, or keypair) and a sync factor (EC keypair)
14
-
3.**Retrieval** (`/retrieve/from-challenge`): Client retrieves backup using an authentication factor
15
-
4.**Add sync factor** (`/add-sync-factor`): Client adds new sync factor after performing recovery.
15
+
2.**Retrieval** (`/retrieve/from-challenge`): Client retrieves backup using an authentication factor
16
+
3.**Add sync factor** (`/add-sync-factor`): Client adds new sync factor after performing recovery.
16
17
4.**Sync** (`/sync`): Client updates backup content using a sync factor
17
18
5.**Management**: Client can add factors (`/add-factor`), or delete factors (`/delete-factor`). It can also view backup metadata (`/retrieve-metadata`).
18
19
19
20
### Definitions
20
21
21
-
***Sealed Backup**: Binary blob from user device with backup ciphertext.
22
-
***Backup Metadata**: Information about a backup including its ID, authentication factors, sync factors, and encrypted keys
23
-
***Main Factor**: Authentication method that can access a backup and **manage the backup** (add new factors, and perform recovery). It is a passkey, OIDC account, or EC keypair.
24
-
***Sync Factor**: Special factor (EC keypair) that can update backup content, delete factors and read metadata, but cannot add new factors or perform recovery
25
-
***Encrypted Backup Key**: Encryption key for the backup data, encrypted separately for each factor kind. The encrypted key is coming from user's device and is stored in the backup metadata.
26
-
***Turnkey Shared Passkey Challenge**: A passkey challenge that is a valid [Webauthn Turnkey stamp](https://docs.turnkey.com/developer-reference/api-overview/stamps#webauthn) and can be used to add a new factor to backup-service. Allows to add new factor with authorization to Turnkey & backup-service in a single passkey prompt.
22
+
-**Sealed Backup**: Binary blob from user device with backup ciphertext.
23
+
-**Backup Metadata**: Information about a backup including its ID, authentication factors, sync factors, and encrypted keys
24
+
-**Main Factor**: Authentication method that can access a backup and **manage the backup** (add new factors, and perform recovery). It is a passkey, OIDC account, or EC keypair.
25
+
-**Sync Factor**: Special factor (EC keypair) that can update backup content, delete factors and read metadata, but cannot add new factors or perform recovery
26
+
-**Encrypted Backup Key**: Encryption key for the backup data, encrypted separately for each factor kind. The encrypted key is coming from user's device and is stored in the backup metadata.
27
+
-**Turnkey Shared Passkey Challenge**: A passkey challenge that is a valid [Webauthn Turnkey stamp](https://docs.turnkey.com/developer-reference/api-overview/stamps#webauthn) and can be used to add a new factor to backup-service. Allows to add new factor with authorization to Turnkey & backup-service in a single passkey prompt.
27
28
28
29
### Running Locally
29
30
@@ -53,10 +54,9 @@ docker compose down
53
54
54
55
An end-to-end Python test script is available to test the complete backup flow against remote environments:
0 commit comments