-
Notifications
You must be signed in to change notification settings - Fork 375
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
Accommodate the new OpenSSL behavior when failed to decrypt certs #3197
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
one minor comment
@@ -99,6 +109,13 @@ def decrypt_p7m(self, p7m_file, trans_prv_file, trans_cert_file, pem_file): | |||
except shellutil.CommandError as command_error: | |||
logger.error("Failed to decrypt {0} (return code: {1})\n[stdout]\n{2}\n[stderr]\n{3}", | |||
p7m_file, command_error.returncode, command_error.stdout, command_error.stderr) | |||
# If the decryption fails, old version of openssl overwrite the output file(if exist) with empty data while | |||
# new version of openssl does not overwrite the output file, So output file may contain old certs data. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's add the "new version" value to the comment, in case we ever need it in the future
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #3197 +/- ##
===========================================
+ Coverage 71.97% 72.30% +0.32%
===========================================
Files 103 114 +11
Lines 15692 16953 +1261
Branches 2486 2448 -38
===========================================
+ Hits 11295 12258 +963
- Misses 3881 4131 +250
- Partials 516 564 +48 ☔ View full report in Codecov by Sentry. |
Description
fixing #3163
If the decryption fails, old version of openssl overwrite the output file(if exist) with empty data while
new version of openssl does not overwrite the output file, so output file may contain old certs data and agent process the old certs again. Correcting the behavior by removing temporary state certificate files.
Issue #
PR information
Quality of Code and Contribution Guidelines