History log of /frameworks/base/packages/services/Proxy/src/com/android/proxyhandler/ProxyServer.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
1e64ab3e56f6efafc25301df5da21d69bb75b470 19-Dec-2014 Andrei Kapishnikov <kapishnikov@google.com> Replace absolute_uri with absolute_path when HTTP request is forwarded to non-proxy server.

According to the spec (http://www.w3.org/Protocols/rfc2616/rfc2616-sec5.html):
When Request-URI is used to identify a resource on an origin server or
gateway, the absolute path of the URI MUST be transmitted as the
Request-URI.

Before the change,the proxy sent absolute_uri, which is used to send
HTTP requests to proxies: “The absoluteURI form is REQUIRED when the
request is being made to a proxy.”

Related Bug 18776631

Other changes:
1. Remove proxy-connection header when the request is sent to an
origin server.

2. Added “connection = close” header to indicate that the origin
server needs to close the connection right after the response.
Currently, our proxy does not support keep-alive (persistent)
connections because it analyses only the first request for a given
connection and; therefore, cannot perform required request content
substitutions.

3. Fixed an issue when a non-numeric host port number resulted in
forwarding requests to default 443 port for SSL connections, e.g.
request to https://google.com:ZZZ, would be translated to
https://google.com:443.

4. Fixed an issue when the proxy tries to establish direct connection
to the origin server even when it is not supposed to do that
according to PAC. That happened when PAC returned a proxy server
that is not available.

5. Prevent ProxyServer from crashing when PacService throws
an exception by intercepting all exception types.

Change-Id: I7d50b13b4cb24199a690a53c1925e87c15a8d45b
/frameworks/base/packages/services/Proxy/src/com/android/proxyhandler/ProxyServer.java
6090995951c6e2e4dcf38102f01793f8a94166e1 19-Nov-2013 John Spurlock <jspurlock@google.com> Remove unused imports from frameworks/base.

Change-Id: Ia1f99bd2c1105b0b0f70aa614f1f4a67b2840906
/frameworks/base/packages/services/Proxy/src/com/android/proxyhandler/ProxyServer.java
179d6e8e2067c380d3c1f7a1a26877b81a9240cb 30-Oct-2013 Jason Monk <jmonk@google.com> Change PacProxySelector to return unresolved addr

This was found by a bug in Firefox where it expects the addresses from a
ProxySelector to be unresolved. Since ProxySelectorImpl returns unresolved
addresses the PAC version should as well to avoid breaking apps.

The ProxyServer also needed to be updated to reflect this change as it was
expecting a resolved InetSocketAddress.

Bug: 11443853
Change-Id: I3a4e9e248d22d7808603c147660df708e01cdf82
/frameworks/base/packages/services/Proxy/src/com/android/proxyhandler/ProxyServer.java
fa4518f7632f0a2146a0638cf39d6d9e1d832a01 14-Aug-2013 Jason Monk <jmonk@google.com> PAC Local Proxy to only receive lo connections

This changes the Local Proxy used in PAC to only accept connections coming
from the device.

Bug: 10230718
Change-Id: I5fbeb3aa018df5179a403301021f452e910a517d
/frameworks/base/packages/services/Proxy/src/com/android/proxyhandler/ProxyServer.java
6f8a68f49a7e8cf86104e721a1e8be7568b5f730 24-Aug-2013 Jason Monk <jmonk@google.com> Guarantee that PAC Local Proxy owns Port

This changes the PAC support to not broadcast the Proxy information until
the Local Proxy has started up and successfully bound to a port so that
the local proxy information can be guaranteed to be owned by the proxy.

Bug: 10459877
Change-Id: I175cd3388c758c55e341115e4a8241884b90d633
/frameworks/base/packages/services/Proxy/src/com/android/proxyhandler/ProxyServer.java
da205a749fadb3a87357d9bd607f094c7717764a 21-Aug-2013 Jason Monk <jmonk@google.com> System binds PAC Local Proxy instead of self start

The PAC Local Proxy priviously caught proxy broadcasts and started itself
when needed. Now it is bound by the system the same way the pac processing
service is started.

Bug: 10425091
Change-Id: I746daa21645a11aa18ef464f00c8cb5536d8c86f
/frameworks/base/packages/services/Proxy/src/com/android/proxyhandler/ProxyServer.java
602b232a06ede86999aa362a12eb28cbc782dc1d 03-Jul-2013 Jason Monk <jmonk@google.com> Add PAC File support for proxy configuration

PAC (Proxy auto-config) files contain a single javascript function,
FindProxyForURL(url, host). It gets called to determine what proxy should be
used for a specific request.

This adds PAC support to the system. The ProxyProperties has been modified
to hold the PAC file when one is present. The Proxy method
setHttpProxySystemProperty has been modified to insert a PacProxySelector
as the default ProxySelector when it is required. This new ProxySelector
makes calls to the ConnectivityService to parse the PAC file.

The ConnectivityService and the WifiConfigStore have been modified to support
saving the extra PAC file data.

The ConnectivityService now has a class attached (PacProxyNative) that
interfaces to the native calls for PAC files. The parsing of the PAC file
is handled by libpac (which is being added to external/) which utilizes
libv8 to parse the javascript.

As a fallback to applications that don't use the java ProxySelector, the proxy
is setup to point to a local proxy server that will handle the pac parsing.

bug:10182711
Change-Id: I5eb8df893c632fd3e1b732385cb7720ad646f401
/frameworks/base/packages/services/Proxy/src/com/android/proxyhandler/ProxyServer.java