Skip to content

This is a team project which we worked on hosting and analysing the TOR network during my Masters second semester.

Notifications You must be signed in to change notification settings

Rusheelraj/TOR-Project

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 

Repository files navigation

Hosting and analysis of TOR network

This is a team project (2) which we worked on hosting and analysing the TOR network during my Masters second semester.

----------- Anonymising network traffic using Proxychains --------------

Step - 1 : Installing proxychains:

$ sudo apt install proxychains

$ sudo apt install proxychains4

Step - 2: Configuration of proxychains: Navigate to the /etc folder and open the proxychains4.conf file to edit the configuration changes. Uncomment the type of chaining needed for the proxychains. In our case, we want to test it on dynamic chains.

#dynamic_chain -> dynamic_chain

socks5 127.0.0.1 9050

Step - 3: Once the configuration changes are done, open a new terminal window and start the proxchains with a web-browser as well as a website we want to connect.

$ proxychains4 firefox whatismyipaddress.com

image

Step - 4: This is how we can view the proxychains traffic in the terminal. We can notice that the type of chain used in this connection is “Dynamic Chain”, localhost 127.0.0.1 and port 9050 with resulted IP address which we wanted to search. The last column describes the HTTP status code of the http request.

image

Step – 5: Let us check whether the traffic is really anonymizing. Online public IP address viewer can help us find out. Once the proxychains is established, we can see that our public IP is completely anonymized. The IP address is at location “Iceland” with a IP address as “89.147.110.214”

Check the IP address.

image

Step – 6: Let us also check DNS leak test. A DNS leak test is a tool that determines whether a user's DNS requests are being leaked or exposed outside of an encrypted VPN or proxy tunnel.

When a user visits a website or other online resource, their device sends a DNS request in order to translate the domain name into an IP address. If the DNS request is not delivered through the encrypted tunnel, the user's Internet Service Provider (ISP) can track their online activities and potentially identify their location and identity. DNS leak testing operates by mimicking DNS requests from the user's device and determining whether they are routed through the encrypted tunnel or are leaked outside of it. The test usually entails contacting a website or service that displays the user's IP address and comparing it to the IP address of the VPN or proxy server to which they are connected.

DNS leaks can occur as a result of incorrectly configured VPN or proxy settings, network connectivity problems, or software defects. DNS leak tests are useful because they assist users in identifying and correcting potential privacy and security issues, as well as selecting VPN or proxy services that do not leak DNS requests.

image

-------------- Hosting a TOR onion website ------------------

Step - 1: Open a terminal window on Kali Linux Install Tor by running the following command:

$ sudo apt-get install tor

Once Tor is installed, we can check its status by running the following command:

$ sudo service tor status

To automatically launch Tor when Kali Linux starts up, we can add the following command in our system's startup programs:

$ sudo systemctl enable tor.service

This will add the Tor service to the list of services that start up when Kali Linux boots. Also, we can start the Tor service manually by running the following command:

$ sudo systemctl start tor.service

Once the service is started, we can use the Tor browser to access .onion sites and browse the web anonymously.

Step - 2: Traverse to /var/lib/tor/hidden_service and uncomment the two lines present in the location-hidden services.

HiddenServiceDir /var/lib/tor/hidden_service/ HiddenServicePort 80 127.0.0.1:8080 // Here, we are binding the port 8080

image

Step – 3: Start the TOR service. This can be performed just by a simple command. $ sudo service tor start

$ sudo service tor status

image

Step – 4: Start running the in-built python’s HTTP server and bind the IP and port with HTTP server. This can be performed by the command.

$ sudo python3 -m http.server –bind 127.0.0.1 8080

image

Step - 5: But we must have an address to access the site. This can be found in /var/lib/tor/hidden_service folder. Open the hostname by using the “cat” command. Traverse to this path!

$ cd /var/lib/tor/hidden_service

There is a file called "hostname". This is where the TOR stores the URL name for your hidden website service.

image

Step – 6: Download the executable file of TOR browser from the official website and run it.

image

Type in this URL onto the TOR browser. zq7yfndhqwoqvmkujfvphddracckd53da3mrjplb7y5w7puacedjt2yd.onion

Once, we type in the URL (.onion site) in TOR browser, it automatically connects to the TOR network and accesses the .onion sites anywhere in the world. The below image is the result of the hosted website on TOR.

image

About

This is a team project which we worked on hosting and analysing the TOR network during my Masters second semester.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published