when i connect to my imap server using imaps,it failes.
can you tell me how to ignore server cert error in javamail
Exception in thread \"main\" java
If you are using javamail 1.4.2+, there is a socket factory you can use to ignore server certificate.
MailSSLSocketFactory socketFactory= new MailSSLSocketFactory(); socketFactory.setTrustAllHosts(true); prop.put("mail.imap.ssl.socketFactory", socketFactory);