Remove SHA-1 dependency from production library #871
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Use of SHA-1 is not permitted in production code anymore by SDL (it hasn't been for years and getting exception has become increasingly difficult). Hash collisions are computationally feasible for these algorithms, which effectively "breaks" them.
There were two scenarios where our libraries took dependency on SHA-1 protocols:
PKeyAuth response when server provides CertificateThumbrint. This is only supported by ADFS and not supported by AAD. It is not feasible to update older versions of ADFS to get rid of SHA-1 dependency. However, it is confirmed by ADFS that thumbprint is only meant to be used as a hint. Since it is SHA-1 thumbprint and it is not meant to be used as a reliable thumbprint by any production code, this code is now removed and certificate is sent to ADFS for final validation.
Client credential request for automation token requests. This is not production code and sha-1 can be used there.