I needed to use a SOCKS proxy to make an SFTP connection. The connection needed to be from a static IP address, and the connection is coming from a Heroku dyno, which doesn’t give us a static IP, so we needed to use Proximo to make it happen.

All the resources I found to do this had an annoying flaw: they monkey-patched either Paramiko or Python’s socket module. There’s no telling how badly that will end, so I dug in a little deeper.

Here’s what I came up with. It’s not quite as robust as Paramiko’s internal socket creation, but it’s working for me.

Resources


The web has a parasite inhibiting its growth. The LAMP Stack won the market for one reason: it’s simple. But that’s not enough to make it good. The web needs something better.

Let’s start by defining the venerable LAMP stack. It’s four main components are Linux, Apache, MySQL, and PHP.

For each of these components, they can easily be switched out for comparable pieces, with comparable results. Linux could easily be switched for OS X, FreeBSD, or even Windows, and have comparable results. …

About

Ryan Hiebert

Christian, Husband, Father, Programmer.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store