equal
deleted
inserted
replaced
1550 * after receiving a 407 error. In the case of NTLM however, |
1550 * after receiving a 407 error. In the case of NTLM however, |
1551 * receiving a 407 is normal and we just skip the stale check |
1551 * receiving a 407 is normal and we just skip the stale check |
1552 * because ntlm does not support this feature. |
1552 * because ntlm does not support this feature. |
1553 */ |
1553 */ |
1554 private AuthenticationInfo |
1554 private AuthenticationInfo |
1555 resetProxyAuthentication(AuthenticationInfo proxyAuthentication, AuthenticationHeader auth) { |
1555 resetProxyAuthentication(AuthenticationInfo proxyAuthentication, AuthenticationHeader auth) throws IOException { |
1556 if ((proxyAuthentication != null )&& |
1556 if ((proxyAuthentication != null )&& |
1557 proxyAuthentication.getAuthScheme() != NTLM) { |
1557 proxyAuthentication.getAuthScheme() != NTLM) { |
1558 String raw = auth.raw(); |
1558 String raw = auth.raw(); |
1559 if (proxyAuthentication.isAuthorizationStale (raw)) { |
1559 if (proxyAuthentication.isAuthorizationStale (raw)) { |
1560 /* we can retry with the current credentials */ |
1560 /* we can retry with the current credentials */ |
1774 } |
1774 } |
1775 |
1775 |
1776 /** |
1776 /** |
1777 * Sets pre-emptive proxy authentication in header |
1777 * Sets pre-emptive proxy authentication in header |
1778 */ |
1778 */ |
1779 private void setPreemptiveProxyAuthentication(MessageHeader requests) { |
1779 private void setPreemptiveProxyAuthentication(MessageHeader requests) throws IOException { |
1780 AuthenticationInfo pauth |
1780 AuthenticationInfo pauth |
1781 = AuthenticationInfo.getProxyAuth(http.getProxyHostUsed(), |
1781 = AuthenticationInfo.getProxyAuth(http.getProxyHostUsed(), |
1782 http.getProxyPortUsed()); |
1782 http.getProxyPortUsed()); |
1783 if (pauth != null && pauth.supportsPreemptiveAuthorization()) { |
1783 if (pauth != null && pauth.supportsPreemptiveAuthorization()) { |
1784 String value; |
1784 String value; |
2130 * Also, needed for digest authentication |
2130 * Also, needed for digest authentication |
2131 */ |
2131 */ |
2132 |
2132 |
2133 String requestURI = null; |
2133 String requestURI = null; |
2134 |
2134 |
2135 String getRequestURI() { |
2135 String getRequestURI() throws IOException { |
2136 if (requestURI == null) { |
2136 if (requestURI == null) { |
2137 try { |
2137 requestURI = http.getURLFile(); |
2138 requestURI = http.getURLFile(); |
|
2139 } catch (IOException e) { |
|
2140 requestURI = ""; |
|
2141 } |
|
2142 } |
2138 } |
2143 return requestURI; |
2139 return requestURI; |
2144 } |
2140 } |
2145 |
2141 |
2146 /* Tells us whether to follow a redirect. If so, it |
2142 /* Tells us whether to follow a redirect. If so, it |