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

Check existing recipients before trying to add a new one #2487

Merged
merged 5 commits into from
Dec 24, 2022

Conversation

dominikschulz
Copy link
Member

@dominikschulz dominikschulz commented Dec 23, 2022

This should avoid bad suprises when adding new recipients.

  • Manually test this
  • Add a nice error message
  • Add a test case for this
  • Add a warning when there is such a thing, and proper documentation about what is possible to do in that case (namely: extend the private key expiration date OR remove the expired key and add a new key with a expiration date in the future)
  • Add a flag to "ignore" expired keys upon re-encryption as long as there are still valid keys in the recipient list (or maybe provided we are working with a non-expired subkey related to the same master key as the expired key?)
  • Make sure we cannot add or create or generate new secrets if we have an expired key: Warn the user they need to add a new non-expired key and remove the expired key.

Some of these are from @AnomalRoil in #1918 (comment)

Fixes #1918

RELEASE_NOTES=[ENHANCEMENT] Check recipients before adding a new one.

Signed-off-by: Dominik Schulz dominik.schulz@gauner.org

Fixes gopasspw#1918

RELEASE_NOTES=[ENHANCEMENT] Check recipients before adding a new one.

Signed-off-by: Dominik Schulz <dominik.schulz@gauner.org>
@dominikschulz dominikschulz self-assigned this Dec 23, 2022
Signed-off-by: Dominik Schulz <dominik.schulz@gauner.org>
Signed-off-by: Dominik Schulz <dominik.schulz@gauner.org>
@dominikschulz dominikschulz marked this pull request as ready for review December 24, 2022 16:55
Signed-off-by: Dominik Schulz <dominik.schulz@gauner.org>
Signed-off-by: Dominik Schulz <dominik.schulz@gauner.org>
@dominikschulz dominikschulz merged commit 5d5e83d into gopasspw:master Dec 24, 2022
@dominikschulz dominikschulz deleted the fix/issue-1918 branch December 24, 2022 18:16
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.

Check all the keys in .gpg-id are valid before adding a new key
1 participant