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

Protectors can be improperly reverted #1

Closed
josephlr opened this issue Jul 12, 2017 · 0 comments · Fixed by #15
Closed

Protectors can be improperly reverted #1

josephlr opened this issue Jul 12, 2017 · 0 comments · Fixed by #15
Assignees
Labels

Comments

@josephlr
Copy link
Member

josephlr commented Jul 12, 2017

In cmd/fscrypt/commands.go, Protectors should be reverted if they are created. The reversion on failure is here. But this has a problem.

If the protector is selected (not created) in selectOrCreateProtector() the protector will be reverted regardless on any error. This means a failure after selection can result in data loss. The documentation for selectOrCreateProtector() is also wrong, leading to this confusion.

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

Successfully merging a pull request may close this issue.

1 participant