Design: encryption at rest for cloud user data #5
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context
Cloud user documents (PDFs, EPUBs) and extracted text chunks stored in SQLite are currently unencrypted on the host filesystem. For users storing proprietary or sensitive documents (e.g. internal rulebooks, private manuscripts), encryption at rest is a reasonable expectation.
Scope
What needs encrypting:
pagepiper.db— document metadata and extracted text chunks (the most sensitive: full extracted text)pagepiper_vecs.db— embedding vectors (lower sensitivity, but linked to user content)uploads/— raw PDFs and EPUBsWhat does NOT need encrypting:
Options
Option A: SQLCipher for DB files
Option B: Filesystem-level encryption
Option C: Application-level field encryption
textcolumn inpage_chunksusing a per-user key before insert, decrypt on readRecommendation: Option B (fscrypt) for cloud instances behind the managed operator model. Option A (SQLCipher) as a stretch goal for self-hosters who want encryption without OS-level setup. Option C is not viable due to BM25 incompatibility.
Notes