sm outbound e-mail settings with STARTTLS security

Hi!
i set smtp servet for outbound e-mails from hpsm 9.50

smtphost:pochta.xxx.ru
smtpport:587
smtpusername:user
*smtppassword:FGFG35D254008F17841C148D2CE8D3DED865GFGF
smtpTLS:1
#smtpEnableSSL:1
#smtpSSLPort:465
mailFrom:user@XXX.ru
msg_buffer_size:32000
#keepmail:1
clean:1

and i got error

6420( 4344) 12/06/2017 13:02:19 JRTE E Unable to connect to mail [server]:port [pochta.xxx.ru]:587
javax.mail.MessagingException: Could not convert socket to TLS;
nested exception is:
javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
at com.sun.mail.smtp.SMTPTransport.startTLS(SMTPTransport.java:1999)

Do somebody have solution to connect to smtp-server?

  • Verified Answer

    solution
    1. copy cacerts from Server/jre/lib/security to Server/RUN folder
    2. add post certificate using keytool:
         keytool -import -trustcacerts -storepass changeit -noprompt -alias my.crt -file %1 -keystore cacerts
    3. add to sm.ini:
         #Known Certificate Authorities - The signing CA must be in here
         truststoreFile:cacerts
         truststorePass:changeit
    4. reboot server service.