hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Satsangi, Vivek " <Vivek.Satsa...@xerox.com>
Subject RE: HttpClient and Simple SSL
Date Tue, 13 Dec 2005 20:03:58 GMT
 Hello Bashiro,

	One way that you can try to debug this issue is to 
A) Check what certificates are available in the keystore (the keytool
thing that Tim mentioned).
B) Are you getting any certificates recognized at all? E.g. if you go to
yahoo using https, does that work?
C) You can also try to output the full http handshake. Then you will be
able to tell whether it could find the keystore at all, whether the CRL
check failed or the actual certificate getting, etc.

Vivek

-----Original Message-----
From: bashiro [mailto:bashiro@myway.com] 
Sent: Tuesday, December 13, 2005 2:48 PM
To: httpclient-user@jakarta.apache.org
Subject: Re: HttpClient and Simple SSL



Hello guys,

Thanks for the tips I have been getting.

Here is a code snip of the exception i am getting;
========================================================
javax.net.ssl.SSLHandshakeException:
sun.security.validator.ValidatorException: No trusted certificate found
	at com.sun.net.ssl.internal.ssl.BaseSSLSocketImpl.a(DashoA6275)
	at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA6275)

=====================================================================0
I will be happy for any help.


Bashiro

 --- On Tue 12/13, Tim Watts < timtw@earthlink.net > wrote:
From: Tim Watts [mailto: timtw@earthlink.net]
To: httpclient-user@jakarta.apache.org
Date: Tue, 13 Dec 2005 08:34:33 -0500
Subject: Re: HttpClient and Simple SSL

Below is about the simplest example you can write. As you can see
there's nothing distinctive other than that 's' on https. What exception
are you getting? I have to say that this works fine on my Linux box but
it would probably throw a "CertificateException: Could not find trusted
certificate" on my Windows box. Why?, I don't know. Don't really think
it's an OS issue; something different about the java environment on each
machine. I'm still puzzling about that...import
org.apache.commons.httpclient.HttpClient;import
org.apache.commons.httpclient.HttpMethod;import
org.apache.commons.httpclient.methods.GetMethod;public class Test {
public static void main(String[] args) throws Exception {
HttpClient client = new HttpClient();        HttpMethod get = new
GetMethod("https://www.verisign.com/");        int httpRc =
client.executeMethod(get);        System.out.println(httpRc);    }}On
Tuesday 13 December 2005 07:43, bashiro wrote:> Thanks for the tips.>
You know I always
  
get exeption when working with> ssl. That i why i want an example
someone has doe using> the httpclient, so that I can edit that and
use.>> I just want to compare other examples with the use guide and>
then work further on.>> Thanks>> Bashiro>>  --- On Tue 12/13, Tim Watts
< timtw@earthlink.net > wrote:> From: Tim Watts [mailto:
timtw@earthlink.net]> To: httpclient-user@jakarta.apache.org> Date: Tue,
13 Dec 2005 06:38:48 -0500> Subject: Re: HttpClient and Simple SSL>> On
Tuesday 13 December 2005 05:08, bashiro wrote:> 1. A simple way to work>
with HttpClient and SSL ?>    (Not the user manual of
Httpclient)Mostly,> I've found working with SSL to be quite
transparent.> All what I mean is a> way to import SSL certificate and
work further with> it. An example is ;> Let's say I want to work with
Https://www.versign.com.> I heard I have to> first right click on the
Security key-lock icon on the> tray to save it as> a cert. Then import
it in java .Not sure about the right-click 
business but> try $JAVAHOME/jre/bin/keytool -help (especially
-import).Hope this helps>
somewhat.---------------------------------------------------------------
--->---To unsubscribe, e-mail:
httpclient-user-unsubscribe@jakarta.apache.orgFor> additional commands,
e-mail: httpclient-user-help@jakarta.apache.org>>
_______________________________________________> No banners. No pop-ups.
No kidding.> Make My Way  your home on the Web -
http://www.myway.com>>>>
--------------------------------------------------------------------->
To unsubscribe, e-mail: httpclient-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail:
httpclient-user-help@jakarta.apache.org---------------------------------
------------------------------------To unsubscribe, e-mail:
httpclient-user-unsubscribe@jakarta.apache.orgFor additional commands,
e-mail: httpclient-user-help@jakarta.apache.org

_______________________________________________
No banners. No pop-ups. No kidding.
Make My Way  your home on the Web - http://www.myway.com



---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: httpclient-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: httpclient-user-help@jakarta.apache.org


Mime
View raw message