Skip to content

SOLIDPOD: write to pod while preserving encryption state #697

Description

@jesscmoore

Describe the Bug

Files that are changed to unencrypted on the pod, such as during a share to public or auth users, need to maintain that plaintext state when edited and rewritten to the pod. As an app typically uses the default writepod with encrypted by default, when the file is edited, it gets re-encrypted. Which makes it unreadable for signed in users, despite it having been shared and has acl permitting access to signed in users.

writePod() and writeExternalPod() when running on existing files, need to check encrypted status and preserve the encrypted/decrypted status, when writing to the pod.

To Reproduce

Steps to reproduce the behavior:

Using Exper app which contains an index ttl where public files are listed to enable this index look up to occur to make public files discoverable

  1. User 1 creates file (writepod, encrypted by default)
  2. Shares the file to auth users (decrypted)
  3. User 2 who is signed in can now read the file
  4. User 1 edits the file (writepod, encrypted by default)
  5. User 2 can no longer read the file, as they get a no encryption key error
Exception: No encryption key found for https://pods.privateinsights.au/jesscmoore/exper/data/hks9yoglcayk6rkb.ttl

Expected Behaviour

Files shares to public/auth user, can be edited by the owner (or those with write access) and saved (ie a writePod or writeExternalPod), without it affecting access from those authorised to read it: public/auth users.

Context

Where has the issue been observed:

Exper app branch jess/22_index

  • Android
  • Chrome
  • iOS
  • Linux
  • macOS
  • Web
  • Windows

Closing Criteria

Checklist for closing the issue:

  • No errors from make prep
  • All tests pass make qtest
  • A public/auth user shared file can be edited without access to public/auth users being affected.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions