Hi all,

I have setup the standard 8443 ssl connector in Tomcat after creating my own
certificate and everything works fine...

My application has a few servlets that generate dynamic pdf files using the
iText classes library. These work fine over http, but Tomcat gives me the
following message if I run the application over https

sun.security.validator.ValidatorException: No trusted certificate found

This only happens with the pdf servlets, not with the other parts of the
application... I am using IE 6, but I have the same problem with Firefox 1.5
and Netscape 8.1. Although I think this is a server side (Tomcat)
configuration issue, I mention the browser because I know IE has a bug with
streaming files over https. A workaround has been found and discussed here

http://forum.java.sun.com/thread.jspa?forumID=45&threadID=233446

I have tried to apply this, but to no avail... the code I use to stream is as
below:

/* ................. */

response.setContentType("application/pdf");
response.setHeader("Pragma", "public");
response.setHeader("Cache-Control", "max-age=0");
response.setHeader("Content-Disposition", "attachment; filename=aaa.pdf" );     
                
        
// the contentlength is needed for MSIE!!!
response.setContentLength(baos.size());
// write ByteArrayOutputStream to the ServletOutputStream
ServletOutputStream out = response.getOutputStream();
baos.writeTo(out);
out.flush();                                            

/* ................. */

can anyone help with this, please?

Thank you very much for your help.

Francesco
ttps. A workaround has been 



---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to