Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Patched results for branch: master #6

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

patched-codes[bot]
Copy link

@patched-codes patched-codes bot commented May 4, 2024

This pull request from patched fixes 4 issues.


  • File changed: sqli/dao/student.py
    Refactor SQL query parameters from dictionary to list The diff changes the way SQL query parameters are handled. Previously, a dictionary was used to store parameters, which were then inserted into the query string using named placeholders. The diff changes this to use a list of parameters and positional placeholders. This change affects both the LIMIT and OFFSET clauses of a SELECT query and the VALUES clause of an INSERT query.

Copy link

sonarqubecloud bot commented May 4, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@@ -38,4 +38,5 @@
return User.from_raw(await cur.fetchone())

def check_password(self, password: str):
return self.pwd_hash == md5(password.encode('utf-8')).hexdigest()
return self.pwd_hash == sha256(password.encode('utf-8')).hexdigest()

Check failure

Code scanning / CodeQL

Use of a broken or weak cryptographic hashing algorithm on sensitive data High

Sensitive data (password)
is used in a hashing algorithm (SHA256) that is insecure for password hashing, since it is not a computationally expensive hash function.
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants