mirror of
https://github.com/hanxi/xiaomusic.git
synced 2026-03-25 09:49:46 +08:00
Fix code scanning alert no. 32: Use of a broken or weak cryptographic hashing algorithm on sensitive data (#203)
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
This commit is contained in:
@@ -399,7 +399,7 @@ def access_key_verification(file_path, key, code):
|
||||
if code is not None:
|
||||
current_code_bytes = code.encode("utf8")
|
||||
correct_code_bytes = (
|
||||
hashlib.md5(
|
||||
hashlib.sha256(
|
||||
(
|
||||
file_path + config.httpauth_username + config.httpauth_password
|
||||
).encode("utf-8")
|
||||
|
||||
Reference in New Issue
Block a user