Closed HTHou closed 2 weeks ago
Attention: Patch coverage is 50.00000%
with 1 line
in your changes missing coverage. Please review.
Project coverage is 63.63%. Comparing base (
6c4f911
) to head (a2e3e0f
).
Files with missing lines | Patch % | Lines |
---|---|---|
...n/java/org/apache/tsfile/encrypt/EncryptUtils.java | 50.00% | 1 Missing :warning: |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Fixes https://github.com/apache/tsfile/security/code-scanning/9
To fix the problem, we need to replace the use of the MD5 algorithm with a stronger, modern cryptographic algorithm. The best way to do this without changing existing functionality is to use SHA-256, which is widely regarded as secure.
MessageDigest.getInstance("MD5")
withMessageDigest.getInstance("SHA-256")
.getNormalKeyStr
andgetEncryptParameter
methods to use SHA-256 instead of MD5.EncryptUtils.java
file.MessageDigest
is already imported.Suggested fixes powered by Copilot Autofix. Review carefully before merging.