1

In torrc, I have come across both these lines:
HiddenServicePort 80 127.0.0.1:80
vs
HiddenServicePort 80 127.0.0.1:8080

Can anyone explain what their differences are?

2 Answers 2

1

The only difference between 127.0.0.1:80 and 127.0.0.1:8080 is the exit port of you local web server, or also known as the listening port.

It is the port number your locally running web server, whether it be Apache, Nginx, etc, is open to incoming requests.

To find out which port your server is using, check the configuration file in the server's installation directory, or just use 80 if you haven't changed any defaults.

0

The first number is the port on which the HS accepts connections.
The address+port is the actual (web?) server that the HS connects to.

In your second example:
HiddenServicePort 80 127.0.0.1:8080 The web server listens to port 8080, but the HS accepts connections to port #80. (Which is the default for http, so clients don't have to specify a port number.)
In this case, Tor and the web server live on the same host, so Tor connects to 127.0.0.1 (localhost) but if they don't live on the same host, then the HiddenServicePort directive should have the address (and port) of the web server.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .