Thank you very much Oleg.
I got the latest build from following URL
http://archive.apache.org/dist/httpcomponents/httpclient/binary/

I need one more help from you.
Can you please give me a sample program that communicates through proxy
server using kerberos authentication.

I am successfully able to communicate to an internet URL through proxy
server using kerberos authentication, but it asks for UserName and password
twice; although I have specified the username and password in the program.
Following is the sample program.

System.setProperty("java.security.krb5.conf", "krb5.ini");
System.setProperty("java.security.auth.login.config", "spNegoLogin.conf");
System.setProperty("javax.security.auth.useSubjectCredsOnly", "false");
System.setProperty("sun.security.krb5.debug", "true");
 DefaultHttpClient httpClient = new DefaultHttpClient();
 AuthSchemeRegistry authreg = httpClient.getAuthSchemes();
authreg.unregister("Negotiate");
authreg.register("Negotiate", new SPNegoSchemeFactory(true));
httpClient.setAuthSchemes(authreg);
 HttpHost httpHost = new HttpHost("proxyserver.test.local", 3128);
httpClient.getParams().setParameter(ConnRoutePNames.DEFAULT_PROXY,
httpHost);
 CredentialsProvider provider = httpClient.getCredentialsProvider();
AuthScope authScope = new AuthScope("proxyserver.test.local", 3128,
"TEST.LOCAL", AuthPolicy.SPNEGO);
UsernamePasswordCredentials creds = new
UsernamePasswordCredentials("adminusername", "password");
provider.setCredentials(authScope, creds);
HttpUriRequest request = new HttpGet("http://www.google.com";);
try {
HttpResponse response = httpClient.execute(request);
BasicResponseHandler handler = new BasicResponseHandler();
String respStr = handler.handleResponse(response);
System.out.println(respStr);
} catch (ClientProtocolException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}

thank you.

On Tue, Jan 15, 2013 at 5:12 PM, Oleg Kalnichevski <ol...@apache.org> wrote:

>
> HttpClient 4.2.3 should be available in the Maven central by now. I am
> going to send a formal release announcement in a short while.
>
> Oleg
>
> > On Tue, Jan 8, 2013 at 4:02 PM, dilip <ved...@gmail.com> wrote:
> >
> > > created issue
> > > https://issues.apache.org/jira/browse/HTTPCLIENT-1293
> > > i have tried changing the GGSSchemeBase.java
> > > my change is working in my setup
> > > added my change in comments.
> > >
> > >
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: httpclient-users-unsubscr...@hc.apache.org
> > > For additional commands, e-mail: httpclient-users-h...@hc.apache.org
> > >
> > >
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: httpclient-users-unsubscr...@hc.apache.org
> For additional commands, e-mail: httpclient-users-h...@hc.apache.org
>
>

Reply via email to