Patches: Browse | Submit New | Admin

[#14049] Allow HTTP proxying

Date:
2007-09-18 18:16
Priority:
3
Submitted By:
David Stevenson (stevend)
Assigned To:
Nobody (None)
Category:
None
State:
Open
Summary:
Allow HTTP proxying

Detailed description
This patch creates a hash RFacebook::HTTP_PROXY_OPTIONS which contains the keys:
  :proxy_host, :proxy_port, :proxy_user, and :proxy_pass

It pulls default values from the ENV["http_proxy"] variable, like most unix utilities.  The hash object is
a constant (meaning you can't assign it to be anything other than this hash), but the hash's contents can be modified
in the environment without warning.  This allows you to override the defaul when necessary.

Finally, the patch uses a Net::HTTP::Proxy for creating the http_server in the post_request method.  If the :proxy_host
=> nil, net/http documentation states this will be the same as the previous implementation.

Add A Comment: Notepad

Please login


Followup

No Followups Have Been Posted

Attached Files:

Name Description Download
allow_http_proxying.patch The proxying patch Download

Changes:

Field Old Value Date By
File Added2529: allow_http_proxying.patch2007-09-18 18:16stevend