“TransportException
The connection could not be established with host “ssl://smtp.gmail.com:587”: stream_socket_client(): SSL operation failed with code 1. OpenSSL Error messages: error:1408F10B:SSL routines:ssl3_get_record:wrong version number”
I tried to change the encryption setting to STARTTLS. This did not fix the issue. Alog with several other changes in settings.
the SSL version being used by Nextcloud is not compatible with the one Gmail’s server expects.
I know that my password and username are correct.
To correct the issue of " OpenSSL Error messages: error:1408F10B:SSL routines:ssl3_get_record:wrong version number:"
I found this suggestion but I’m not sure if the code is correct or is a good idea
Edit config.php: In your Nextcloud’s config.php file, add the following lines:
Failed to authenticate on SMTP server with username “my email” using the following authenticators: “LOGIN”, “PLAIN”, “XOAUTH2”. Authenticator “LOGIN” returned “Expected response code “235” but got code “535”, with message “535-5.7.8 Username and Password not accepted. For more information, go to 535 5.7.8 Can't sign in to your Google Account - Gmail Help 5614622812f47-3db1341e15asm1809771b6e.16 - gsmtp”.”. Authenticator “PLAIN” returned “Expected response code “235” but got code “535”, with message “535-5.7.8 Username and Password not accepted. For more information, go to 535 5.7.8 Can't sign in to your Google Account - Gmail Help 5614622812f47-3db1341e15asm1809771b6e.16 - gsmtp”.”. Authenticator “XOAUTH2” returned “Expected response code “235” but got code “334”, with message “334 eyJzdGF0dXMiOiI0MDAiLCJzY2hlbWVzIjoiQmVhcmVyIiwic2NvcGUiOiJodHRwczovL21haWwuZ29vZ2xlLmNvbS8ifQ==”.”.
Sending mail to "Array ( [my email] => user ) " with subject “Email setting test” failed