Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

nodejs website for TOR network

Tags:

node.js

tor

Is there a simple way to use nodejs for building websites inside TOR network? I mean make my nodejs server available as .onion url? I have VDS/VPS with linux onboard.

like image 633
Наталья Калкутина Avatar asked Aug 04 '16 17:08

Наталья Калкутина


1 Answers

Running a hidden service is easy.

You have to install Tor first and then edit the config file to set up the hidden service.

Assume your node application is running on port 8080, you would edit your torrc config file and add:

HiddenServiceDir /var/lib/tor/nodeapp
HiddenServicePort 80 127.0.0.1:8080

When you restart Tor, it will initialize the hidden service (generate keys etc) and start proxying port 80 to local port 8080 (the node application).

You can get the onion address by looking at /var/lib/tor/nodeapp/hostname and then access it over Tor as long as Tor is running on the system and the node application.

like image 67
drew010 Avatar answered Nov 08 '22 11:11

drew010