I'm trying to find out what the equivalent Mac SSH client is and set of commands are that would achieve the below. In Windows we use the Putty CLI utility 'Plink' to set up a SSH connection to a SSH server for web proxying purposes.

plink -l username -pw password -D 8080 -P 443 -ssh

This command establishes a SSH connection to host IP: over port 443 using the username and password specified. It then presents a local port (8080) available for other applications on the local host to connect to, for example a web browser. Within the web browser we configure a SOCKS proxy using our own IP address or 'localhost' as the proxy server, with port 8080.

I don't know enough about Mac to replicate this putty tool's function and it's not a standard ssh client and I haven't seen plink documented to map things to a unix situation.

  • 2
    ssh is the tool of choice for this
    – nohillside
    Commented Dec 1, 2012 at 15:00

1 Answer 1


This is standard ssh and covered in the man page for TCP forwarding.

ssh -f -L 8080:localhost:443 sleep 10

I changed as little from the manual page (8080, 443, so you can find it and the explanation there on OS X. You will want to increase the sleep time if you browser isn't going to connect in the next 10 seconds.

You must log in to answer this question.

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