This is bothering me for hours now. I’m trying to send mails with Symfony 5 and SwiftMailerBundle 3.4 using Mailjet. So I have the following value in my
In production I used my username and password ofcourse.
Now when Symfony tries to send a mail I get the following error:
Warning: stream_socket_enable_crypto(): SSL context creation failure
The most annoying part is that these settings are working on my local machine, but not on my server. My server is a Ubuntu server, running PHP 7.3. Local environment is MacOS also with PHP 7.3.
So, I already tried to following:
- Setting the
openssl.cafileto the Mozilla CA (https://curl.haxx.se/docs/caextract.html)
- Setting stream_options in swiftmailer config
stream_options: ssl: allow_self_signed: true verify_peer: false
Does somebody have an idea on how to fix this? I don’t want to waste another five hours on this on new years eve…
Source: Symfony Questions
Was this helpful?
0 / 0