Skip to content

Commit

Permalink
SQL explaination.
Browse files Browse the repository at this point in the history
  • Loading branch information
dayeya authored Dec 10, 2023
1 parent a7c3a83 commit e3f5722
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ That is by using the `f strings` in Python, the following code is where the brea
query = f"SELECT * FROM users WHERE user_name = '{user_name}' AND password = '{password}'"
# rest of the code...
```
As a result of using the `f-string`, parsing an SQL Injection payload can cause trouble.
As a result of using the `f-string`, parsing an SQL Injection payload can cause trouble.<br>
E.g parsing the `' OR 'a'='a';--` payload and a random password (abcd) can exploit the database.
```sql
SELECT * FROM users WHERE user_name = '' OR 'a'='a';-- AND password = 'abcd'
Expand Down

0 comments on commit e3f5722

Please sign in to comment.