Resolved Problem sending Laravel email

fusio

Member
Messages
64
Reaction score
5
Points
8
Hello to everyone.
I configured my .env file with the following data:
Code:
MAIL_MAILER=smtp
MAIL_HOST=mail.mydomain
MAIL_PORT=587
MAIL_USERNAME=myuser
MAIL_PASSWORD=mypassword
MAIL_ENCRYPTION=tls
MAIL_FROM_ADDRESS="myuser@mydomain"
and it worked fine on the first test, but I just did another email sending test and it doesn't send.
I reviewed the error log in my hosting panel and it said something like:
mydomain does not match x14.x10hosting...
something like that but I don't know what the problem is, and it worked for me once but not now.
Could some admin help me? thanks
ps: it seems to me that it has to do with when I forced redirection with https or with the ssl certificate
Code:
$message = 'Unable to connect with STARTTLS: stream_socket_enable_crypto(): Peer certificate CN=`x14.x10hosting.com\' did not match expected CN=`mail.mydomain.x10.mx\'
That's what I read and it seems strange to me.
 
Last edited:

fusio

Member
Messages
64
Reaction score
5
Points
8
I already solved it haha. But for those who have the same problem, here I leave you my immediate and final solution.
in the path app/config/mail.php
add the following to the mailers array:
Code:
'verify_peer' => false,
and that's it solved
Admin, can you set this post as resolved Thank you
 
Last edited:
Top