0

Good day,

I have a fully updated Tor Browser set up on a fully updated Manjaro Linux system. I confirmed that the Tor Browser's built-in proxy at 127.0.0.1:9150 can be accessed by using it as a proxy for my regular web browser (yes, I know this is not recommended, I just did it as a test to make sure 127.0.0.1:9150 is available and working to proxy traffic through the Tor network).

I want to proxy my SSH connection through Tor Browser, so I tried to follow instructions such as this, which tells me to run this command:

ssh -o ProxyCommand='nc -x localhost:9150 %h %p' example.com

However, when running it I get this error:

Error: Couldn't resolve host "127.0.0.1:9150"

I also tried localhost:9150 which gives the same error.

I guess the broader question is that given a local Tor proxy running on 127.0.0.1:9150, how do I tunnel my SSH connection through it (with the end goal of accessing Tor hidden services on the other side)?

Is my system blocking something or is my SSH command incorrect?

Thank you very much.

  • 1
    Does ssh -o CheckHostIp=no -o ProxyCommand='connect -4 -S localhost:9150 $(tor-resolve %h localhost:9150) %p' example.com work? – Tim Kennedy Aug 8 '18 at 17:16
  • 1
    There are simpler ways to use SSH. Could you explain better what exactly do you want to do? – Rui F Ribeiro Aug 8 '18 at 19:13
  • @RuiFRibeiro: I simply want SSH to use a proxy to make its connections. The Tor Browser acts as a local SOCKS proxy server through which I can tunnel my connections, and I'd like to tell SSH to use it. Does that make sense? – hpy Aug 9 '18 at 1:36
  • @TimKennedy: I tried running your suggestions, but I don't seem to have the tor-resolve command. I only have Tor Browser which is a portable package. – hpy Aug 9 '18 at 1:37
  • 1
    Could you explain better where you want to connect? The setup/what you are trying to do seems more complex than the necessary. – Rui F Ribeiro Aug 9 '18 at 1:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.