Fork me on GitHub

Herr Knedel/Set up your own darknet page

Created Sun, 30 May 2021 00:00:00 +0000 Modified Mon, 28 Mar 2022 18:10:54 +0000 Difficulty level: It may take a little longer

293 Words

Surfing the darknet as a visitor is quite simple. But how can I host an Onion page? I will show you how to set up your own darknet page.

Step 1: How can I surf the darknet?

I use an Ubuntu desktop for better illustration. There I install the following packages:

x
+
Terminal

$ sudo apt-get update
$ sudo apt-get install tor

Then I edit the “/etc/privoxy/config” file and enter the following ($ sudo vim /etc/privoxy/config). You can get the IP of the computer with “ifconfig”.

listen-address hier-muss-die-ip-des-rechners-rein:8118
forward-socks5 / 127.0.0.1:9050 .

See:

To make sure that Tor and Privoxy are also executed at system startup, we still need to add them to the autostart:
x
+
Terminal

$ sudo update-rc.d tor defaults
$ sudo update-rc.d privoxy defaults

Now the services can be started:
x
+
Terminal

$ sudo service tor restart
$ sudo service privoxy restart

I enter the proxy address in my Firefox, disable “Javascript” and visit the “Tor test page”. If everything worked, I can now visit TOR/.Onion sites.

Step 2: How can I host darknet site?

First, I install an HTTP server:

x
+
Terminal

$ sudo apt-get install nginx

Then I change the NGINX configuration (vim /etc/nginx/nginx.conf) and turn off these features:

server_tokens off;
port_in_redirect off;
server_name_in_redirect off;

See:

The NGINX server must now be restarted once again:
x
+
Terminal

$ sudo service nginx restart

A change must also be made in the Tor configuration. I comment the following lines “HiddenServiceDir” and “HiddenServicePort” in the “/etc/tor/torrc” file. After that I also restart this DIenst:
x
+
Terminal

$ sudo service tor restart

Ready

Under “/var/lib/tor/hidden_servic/hostname” I find my Darknet/Onion address. Now all content under /var/www/html is available in the darkent.