I have a local mail server (hMailServer) with SSL (port 465) and a self-signed certificate.
Domain is \"foobar.com\"
I have setup my Properties
This the solution for JavaMail SSL with no Authentication trust certificate using Spring framework, change your .xml file as describe below.You can see the solution in the snapshot See the image description here
javax.net.ssl.SSLSocketFactory true
change it to false if you want mail server must be in ssl