Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TLS issue fix #284

Open
cthamer opened this issue Jan 31, 2022 · 3 comments
Open

TLS issue fix #284

cthamer opened this issue Jan 31, 2022 · 3 comments

Comments

@cthamer
Copy link

cthamer commented Jan 31, 2022

The extension no longer works with email services (office365) that require TLS 1.2 or
higher. It seems to be a problem with the Zend Mailer hard coding in
only TLS 1.0 support.

The file httpdocs/lib/Zend/Mail/Protocol/Smtp.php has the following.

if (!stream_socket_enable_crypto($this->_socket, true,
STREAM_CRYPTO_METHOD_TLS_CLIENT)) {

STREAM_CRYPTO_METHOD_TLS_CLIENT defaults to TLS1.

If you change that to

if (!stream_socket_enable_crypto($this->_socket, true,
STREAM_CRYPTO_METHOD_ANY_CLIENT)) {

then a TLS1.2 connection can be established and all is well again

@cthamer cthamer changed the title TLS issue TLS issue fix Jan 31, 2022
@Johanoosmith
Copy link

Yes, it's working for me.

Thanks

@addison74
Copy link

Please check this file from here:

https://github.com/Shardj/zf1-future/blob/master/library/Zend/Mail/Protocol/Smtp.php

STREAM_CRYPTO_METHOD_TLS_CLIENT|STREAM_CRYPTO_METHOD_TLSv1_1_CLIENT|STREAM_CRYPTO_METHOD_TLSv1_2_CLIENT is a much better solution then STREAM_CRYPTO_METHOD_ANY_CLIENT because disables SSL protocol and leave only TLS.

I hope that in the coming months we will replace in OpenMage ZF1 inherited from Magento 1 and keep up with ZF1-Future which is an active project.

@ProgrammerNomad
Copy link

Yes, it's working for me.

Please check this file from here:

https://github.com/Shardj/zf1-future/blob/master/library/Zend/Mail/Protocol/Smtp.php

STREAM_CRYPTO_METHOD_TLS_CLIENT|STREAM_CRYPTO_METHOD_TLSv1_1_CLIENT|STREAM_CRYPTO_METHOD_TLSv1_2_CLIENT is a much better solution then STREAM_CRYPTO_METHOD_ANY_CLIENT because disables SSL protocol and leave only TLS.

I hope that in the coming months we will replace in OpenMage ZF1 inherited from Magento 1 and keep up with ZF1-Future which is an active project.

Its perfect working with all :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants