Repository navigation
docs: fix offline lease sealing flow and specify encryption primitive in ADR 006 - #110
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the offline lease issuance process, shifting the responsibility of sealing the lease from the app server to the client using a device-bound key. The review feedback highlights a potential security downgrade by sending keys in plaintext over TLS compared to the online flow, suggests including a nonce in the AEAD pseudocode for completeness, and points out a contradiction regarding hardware-backed key isolation on desktop platforms.
There was a problem hiding this comment.
Pull request overview
This PR updates the design documentation around offline playback lease issuance in ADR 006 to ensure leases are constructed server-side but sealed client-side using the device keystore, and aligns the higher-level architecture summary accordingly.
Changes:
- Correct the offline lease flow so the server builds/returns the lease and the client seals it locally via the platform keystore.
- Replace the underspecified
encrypt(device_key, lease)step with an explicit AEAD sealing operation and expand keystore/primitive notes. - Update
adr/architecture.mdapp server responsibilities to match the revised client-side sealing model.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| adr/architecture.md | Updates app server responsibility wording to reflect client-side lease sealing. |
| adr/006-e2e-encryption.md | Fixes the offline lease issuance pseudocode and clarifies the intended encryption primitive and TLS requirement for lease transit. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
… in ADR 006 (#110) - Fix incorrect flow where app server sealed leases with non-exportable device key — server now builds the lease and returns it over HTTPS; the client seals locally using the platform keystore - Replace underspecified encrypt(device_key, lease) with AEAD_Seal reflecting opaque key handles and platform-dependent primitives - Scope device_key isolation per platform: non-exportable on mobile, zeroize-after-use on desktop - Update architecture.md app server responsibilities accordingly Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
40b1e70 to
bafc4cf
Compare
Summary
encrypt(device_key, lease)withAEAD_Seal(device_key, lease)reflecting opaque key handles and platform-dependent primitives (typically AES-256-GCM)architecture.mdapp server responsibilities to reflect client-side sealingSupersedes #109 (accidentally merged before review fixes).
Test plan
device_keyis never referenced in a server-side context across all ADRsarchitecture.mdsummary is consistent with the updated ADR 006 flow🤖 Generated with Claude Code