Skip to content

Commit

Permalink
modified
Browse files Browse the repository at this point in the history
  • Loading branch information
shimsha24 committed Aug 10, 2024
1 parent bc3e46b commit 9c8314b
Show file tree
Hide file tree
Showing 13 changed files with 1 addition and 4 deletions.
Binary file added __pycache__/app.cpython-312.pyc
Binary file not shown.
Binary file added __pycache__/config.cpython-312.pyc
Binary file not shown.
Binary file added api_views/__pycache__/__init__.cpython-312.pyc
Binary file not shown.
Binary file added api_views/__pycache__/books.cpython-312.pyc
Binary file not shown.
Binary file added api_views/__pycache__/json_schemas.cpython-312.pyc
Binary file not shown.
Binary file added api_views/__pycache__/main.cpython-312.pyc
Binary file not shown.
Binary file added api_views/__pycache__/users.cpython-312.pyc
Binary file not shown.
2 changes: 1 addition & 1 deletion api_views/users.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ def login_user():
return Response(json.dumps(responseObject), 200, mimetype="application/json")
if vuln: # Password Enumeration
if user and request_data.get('password') != user.password:
return Response(error_message_helper("Password is not correct for the given username."), 200, mimetype="application/json")
return Response(error_message_helper("Password is not correct for the given username.Week2 Completed"), 200, mimetype="application/json")
elif not user: # User enumeration
return Response(error_message_helper("Username does not exist"), 200, mimetype="application/json")
else:
Expand Down
Binary file modified database/database.db
Binary file not shown.
3 changes: 0 additions & 3 deletions enumerate.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
import requests

user_error_message = "Username does not exist"
password_error_message = "Password is not correct for the given username."

users_list = ["name1", "name2", "name3", "name4", "name5","admin"]
pass_list = ["pass1", "pass2", "pass3", "pass4", "pass5","admin"]

for user in users_list:
for password in pass_list:
data = {
Expand Down
Binary file added models/__pycache__/__init__.cpython-312.pyc
Binary file not shown.
Binary file added models/__pycache__/books_model.cpython-312.pyc
Binary file not shown.
Binary file added models/__pycache__/user_model.cpython-312.pyc
Binary file not shown.

0 comments on commit 9c8314b

Please sign in to comment.