Created
September 24, 2015 01:16
-
-
Save anonymous/35c843c94c0c577f37ef to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def http_post_with_proxy(uri, data) | |
req = Net::HTTP.SOCKSProxy(@proxy_host,@proxy_port).start(uri.host, uri.port).post(uri.path) | |
req.set_form_data(data) unless data.empty? | |
@connection.request(req) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment