I had a similar problem with Apache 1.3.12 (with mod_ssl and 'open SSL' on
RedHat Linux) and JServ1.1. I do not believe that Sun's SSL's client
implementation (over HTTP) works as it should, IMHO. I was able to use it with
a server certificate and encrypted data transfers correctly against a servlet
but NOT with a client certificate!
Good luck - George (Pls. also try to post in the SSL discussion group)

Jeff Marshall wrote:

> I am trying to get ssl working as a client in a servlet.
>
> The code works if ssl is not running on the webserver.  We are using
> JWS 1.1.3.  I have read that there are third party classes that will
> allow
> servlets to make client ssl connections.
>
> I need to stay with this configuration and I am looking for help.
>
> This code works for ssl connections when the JWS is not running ssl
> Servlet code----
>
> URL url = new URL (imageServerProtocol,imageServerName,
>                     imageServerPort,imageServerGetRequest);
>
> URLConnection uc= url.openConnection();
> uc.connect();
> InputStream in = uc.getInputStream();
> String mimeType = uc.getContentType();
>
> PrintWriter printStream = output.getWriter();
>
> BufferedInputStream inputStream = new BufferedInputStream(in );
>
> output.setContentType("text/html");
> StringBuffer _sb = new StringBuffer();
> int b=-1;
> while ((b=inputStream.read()) !=-1){
>    _sb.append((char)b);
> }
> printStream.println(_sb.toString());
>
> Thanks
>
> ___________________________________________________________________________
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
> of the message "signoff SERVLET-INTEREST".
>
> Archives: http://archives.java.sun.com/archives/servlet-interest.html
> Resources: http://java.sun.com/products/servlet/external-resources.html
> LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to