Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see:
viewtopic.php?t=158230
Programming languages, Coding, Executables, Package Creation, and Scripting.
hack3rcon
Posts: 746 Joined: 2015-02-16 09:54
Has thanked: 48 times
#1
Post
by hack3rcon » 2020-02-23 05:30
Hello,
I want to change below Bash script for using Tor and send request to a website with new IP address:
Code: Select all
for i in {1..5}; do wget "URL" -O /dev/null; sleep 5; done
But, How can I understand that the Tor new identity established? If I use
Then how can I sure Tor got the new IP addresses and then "wget" sending new request to the website with that new IP address?
Thank you.
arzgi
Posts: 1185 Joined: 2008-02-21 17:03
Location: Finland
Been thanked: 31 times
#2
Post
by arzgi » 2020-02-23 12:54
hack3rcon wrote:
Then how can I sure Tor got the new IP addresses
Code: Select all
$ ip -br a
# service tor restart
$ ip -br a
EDIT:
If you need just an IP address, you can filter above command using for example sed.
EDIT2:
No need for filter.
hack3rcon
Posts: 746 Joined: 2015-02-16 09:54
Has thanked: 48 times
#3
Post
by hack3rcon » 2020-02-25 08:40
When I restart the Tor service then it need sometimes to connecting to a Tor node. How can I sure the Tor connection is established and then the next command execute?
reinob
Posts: 1189 Joined: 2014-06-30 11:42
Has thanked: 97 times
Been thanked: 47 times
#5
Post
by reinob » 2020-03-10 16:07
hack3rcon wrote: Any idea?
If you just want to create a new circuit you don't need to (and you should not) restart tor.
Just tell it to renew:
Code: Select all
$ printf "AUTHENTICATE \"\"\r\nSIGNAL NEWNYM\r\n" | nc 127.0.0.1 9051
(if your ControlPort is not 9051, then adjust accordingly).