if (LOG.isDebugEnabled()) {
LOG.debug("Authenticating with " + realm);
}
Credentials credentials = this.state.getProxyCredentials(realm);
if (credentials != null) {
String authstring = authscheme.authenticate(credentials, method);
if (authstring != null) {
method.addRequestHeader(new Header(PROXY_AUTH_RESP, authstring, true));
}
} else {
LOG.warn("Required credentials not available");