rstudio / blastula

Easily send great-looking HTML email messages from R
https://pkgs.rstudio.com/blastula
Other
548 stars 85 forks source link

schannel: SNI or certificate check failed: SEC_E_WRONG_PRINCIPAL (0x80090322) - The target principal name is incorrect. #244

Open gfspiteri opened 3 years ago

gfspiteri commented 3 years ago

Hi, trying Blastula out on our work SMTP server, however having problems. This is the code:

email %>%
  smtp_send(
    to = "xx@gmail.com",
    from = "xx@xx.com",
    subject = "Testing the `smtp_send()` function",
    credentials = creds(user = "xx", host = "xx", port = 25, use_ssl = T)
  )

I get this error: Error in curl_fetch_memory(smtp_server, handle = h) : schannel: SNI or certificate check failed: SEC_E_WRONG_PRINCIPAL (0x80090322) - The target principal name is incorrect.

If I change use_ssl = F I I get "The email message was sent successfully." but no email is received.

Not sure what I can do to troubleshoot further. Any pointers appreciated!

Thanks.