Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

117 track decryption status of files, messages, replies #262

Merged
merged 10 commits into from Mar 14, 2019

Conversation

redshiftzero
Copy link
Contributor

@redshiftzero redshiftzero commented Mar 8, 2019

This PR:

  • Adds a column is_decrypted to the file, message, and reply tables. This field is null until a decryption attempt occurs. After this point, it tracks the status of the last decryption action.
  • When files, messages, and replies are downloaded and decryption is attempted, the status of the decryption action is updated in the database.

@redshiftzero
Copy link
Contributor Author

OK this one should be ready for review

Copy link
Contributor

@heartsucker heartsucker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We might want to change the constraint on content to be CASE WHEN NOT is_decrypted THEN content IS NULL ELSE TRUE END. This would make the most sense in terms of restricting the database to have predictable values.

securedrop_client/db.py Outdated Show resolved Hide resolved
securedrop_client/db.py Outdated Show resolved Hide resolved
securedrop_client/db.py Outdated Show resolved Hide resolved
securedrop_client/storage.py Outdated Show resolved Hide resolved
Copy link
Contributor

@sssoleileraaa sssoleileraaa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants