I\'ve been trying to configure the user and password for proxy authentication from the configured properties while using Apaches HttpComponent\'s httpclient, but with no suc
For HttpClient 4.5 and per request authentication:
HttpContext httpContext = new BasicHttpContext();
AuthState authState = new AuthState();
authState.update(new BasicScheme(), new UsernamePasswordCredentials("userName", "password"));
httpContext.setAttribute(HttpClientContext.PROXY_AUTH_STATE, authState);
CloseableHttpResponse httpResponse = httpClient.execute(httpRequest, httpContext);