Tick off Phase 2 crypto primitives TODO

This commit is contained in:
2026-05-09 12:45:53 -07:00
parent 8aecf977e9
commit 52c2fa844c

View File

@@ -592,15 +592,17 @@ Phase 1: scaffolding
Phase 2: crypto primitives Phase 2: crypto primitives
- [ ] Wrap libsodium init as an awaitable singleton - [x] Wrap libsodium init as an awaitable singleton
- [ ] `deriveKEK(password, kekSalt, memLimit, opsLimit)` (Argon2id) - [x] `deriveKEK(password, kekSalt, memLimit, opsLimit)` (Argon2id)
- [ ] `deriveLoginSubkey(kek)` (KDF with subkey id 1, context `loginctx`, 16 - [x] `deriveLoginSubkey(kek)` (KDF with subkey id 1, context `loginctx`, 16
bytes) bytes)
- [ ] `decryptBox(ciphertext, nonce, key)` for secretbox - [x] `decryptBox(ciphertext, nonce, key)` for secretbox
- [ ] `decryptSealed(ciphertext, publicKey, secretKey)` for sealed box - [x] `decryptSealed(ciphertext, publicKey, secretKey)` for sealed box
- [ ] `initStreamPull` and `pullStreamChunk` for chunked secretstream (4 MiB - [x] `initStreamPull` and `pullStreamChunk` for chunked secretstream (4 MiB
plaintext chunks, 17-byte overhead) plaintext chunks, 17-byte overhead)
- [ ] Round-trip tests against vectors generated by libsodium directly - [x] Round-trip tests against vectors generated by libsodium directly
- [x] Base64 helpers (`fromBase64`, `toBase64`, `toBase64URL`) accepting all
four sodium variants on input
Phase 3: SRP + auth Phase 3: SRP + auth