-
Notifications
You must be signed in to change notification settings - Fork 4
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
Add MD5 checksum integrity check #5790
Conversation
1b04dbc
to
2a8918b
Compare
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.
Great catch @yanchenm. Hopefully this sheds some light onto what's going on.
Code looks great as always.
Codecov Report
@@ Coverage Diff @@
## dev #5790 +/- ##
==========================================
- Coverage 54.22% 54.12% -0.10%
==========================================
Files 190 190
Lines 24752 24696 -56
Branches 31 31
==========================================
- Hits 13422 13367 -55
- Misses 11116 11117 +1
+ Partials 214 212 -2
*This pull request uses carry forward flags. Click here to find out more.
Continue to review full report at Codecov.
|
I tested this PR and got this warning while connecting the client app to my dev instance:
What causes the checksum to not be supported? Does this mean that, in this case, there is still a possibility for a mismatch that will not be detected? Aside from that, the code is great and everything else works nice! |
Yeah I saw this warning too and it's from the AWS SDK not our code. I'll look into what it means and why it happens |
according to: aws/aws-sdk-go-v2#1606 it's just an issue in v 1.25 which we are using, which has apparently been fixed. If we upgrade our go-sdk this should be fixed? |
Good catch, I'll try that |
Ticket(s) Closed
Description
Deals with https://sentry.io/organizations/whist/issues/2963782777/events/?project=5461239&referrer=slack. Error given in Sentry is that the salt header is missing (an indicator of a malformed config file). However, upon manual inspection of all the possible candidate files for both occurrences of the error, the salt header was present in all of them. I suspect then that the cause could be because of corrupted downloads which we do not currently check for.
This PR adds MD5 checksum validation to the config download process and allows up to 3 retries on checksum mismatches.
Implementation
Adds an
md5
key to the object metadata in S3.Documentation & Tests Added
Testing Instructions
md5
tagPR Checklist