mp.addBodyPart(new MimeBodyPart(headers,certs[i].getEncoded()));
}
if (log.isTraceEnabled()) {
log.trace("content type: "+mp.getContentType());
}
mp.writeTo(resp.getOutputStream());
resp.flushBuffer();
} catch (CertificateEncodingException e) {
throw new ServletException(e);
} catch (MessagingException e) {
throw new ServletException(e);