Modified CLI update function to use keys.openpgp.org for release key#4585
Conversation
85bb1bb to
aefda8c
Compare
kushaldas
left a comment
There was a problem hiding this comment.
It is still failing for me. Here is the output from the manual command.
$ gpg --batch --no-tty --recv-key --keyserver hkps://keys.opengpg.org 22245C81E3BAEB4138B36061310F561200F4AD77
gpg: keyserver receive failed: Server indicated a failure
It seeems there was typo in my manual command, but, the |
|
It might make sense to add a test case for the updated key (with UID) the introduced in #4578, a test similar to https://github.com/freedomofpress/securedrop/blob/develop/admin/tests/test_securedrop-admin.py#L193 with different output, containing the new style key : In cases where the key is directly imported or the key is refreshed, the (good) signature output should be as above. The existing case should cover non refreshed key. |
The error message. |
609307a to
3b7d05c
Compare
|
@emkll makes a good point, parametrizing
would be good to add prior to merge |
admin/securedrop_admin/__init__.py
Outdated
| gpg_lines = sig_result.split('\n') | ||
| if RELEASE_KEY in gpg_lines[1] and \ | ||
| sig_result.count(good_sig_text) == 1 and \ | ||
| len([s for s in gpg_lines if |
There was a problem hiding this comment.
To me, these two new lines introduced appear complex, especially for such a critical part of the verification code. Do you think it makes sense to clarify the logic here (either through comments or making the logic more explicit)?
There was a problem hiding this comment.
I reorganized things to make it a little clearer and added comments.
redshiftzero
left a comment
There was a problem hiding this comment.
tested in Tails, this looks good to me
93ecb05 to
ee9b16e
Compare
Dismissing as discussed as this will need to be merged today. I wasn't able to reproduce your issue but if you keep seeing it on latest Tails please file a followup and tag "Release QA"
Status
Ready for review
Description of Changes
Towards #4128.
Updates the securedrop-admin tool to use only hkps://keys.openpgp.org when retrieving the release key for tag signature verification.
Testing
On an Admin Workstation (virtual or USB stick):
Deployment
This will be deployed via the GUI updater, CLI update as above, or directly by checking out the release tag containing the change. Nothing special required.
Checklist
If you made changes to
securedrop-admin:make -C admin test) pass in the admin development containerIf you made non-trivial code changes: