Default to doing DNS resolution through a proxy server if present.#276
Merged
Conversation
- Resolve an issue where proxy information by default was not resolving DNS through a proxy server (unlike the `socks` library), so users getting proxy information from an environment variable (HTTP_PROXY/HTTPS_PROXY) with no external DNS could not connect to hosts with DNS names. - Resolve a potential issue where if the proxy server was a different address family to the destination host and there was functional DNS, may not work. For example, using a IPv4-only proxy server to connect to an IPv6-only host via an IPv4-only internal network. - Improved documentation of the ProxyInfo class.
jcgregorio
added a commit
that referenced
this pull request
Jul 14, 2014
Default to doing DNS resolution through a proxy server if present.
|
Verified that the proxy_rdns sensible default change works for solving dns resolution behind a proxy server and without a local nameserver. A bit of context: I'm using httplib2 via Ansible's uri module. The default proxy_rdns=None in httplib2 v0.9 results in sock.connect() to raise gaierror which in turn raises ServerNotFoundError, which Ansible uri module passes as a failure with "Unable to resolve host name given." error message. Edit: typo and clarity. |
jsonn
pushed a commit
to jsonn/pkgsrc
that referenced
this pull request
Feb 4, 2016
0.9.2: Changes not documented. 0.9.1: Fixes in this release: jcgregorio/httplib2#296 There was a problem with headers when a binary string is passed (like b'Authorization'). jcgregorio/httplib2#276 Default to doing DNS resolution through a proxy server if present.
jsonn
pushed a commit
to jsonn/pkgsrc
that referenced
this pull request
Feb 11, 2016
0.9.2: Changes not documented. 0.9.1: Fixes in this release: jcgregorio/httplib2#296 There was a problem with headers when a binary string is passed (like b'Authorization'). jcgregorio/httplib2#276 Default to doing DNS resolution through a proxy server if present.
This was referenced Jun 19, 2017
Merged
This was referenced Oct 18, 2017
msk
pushed a commit
to msk/pkgsrc
that referenced
this pull request
May 11, 2026
0.9.2: Changes not documented. 0.9.1: Fixes in this release: jcgregorio/httplib2#296 There was a problem with headers when a binary string is passed (like b'Authorization'). jcgregorio/httplib2#276 Default to doing DNS resolution through a proxy server if present.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
sockslibrary), so users getting proxy information from an environment variable (HTTP_PROXY/HTTPS_PROXY) with no external DNS could not connect to hosts with DNS names. There isn't any way to setproxy_rdnsfromproxy_info_from_environmentorproxy_info_from_url, so this gives a sensible default, makinghttplib2work the same way as most web browsers.ProxyInfoclass.