[GH-ISSUE #485] imap tls context #382

Closed
opened 2026-02-25 21:34:54 +03:00 by kerem · 9 comments
Owner

Originally created by @basaran on GitHub (Jun 1, 2021).
Original GitHub issue: https://github.com/cypht-org/cypht/issues/485

Originally assigned to: @IrAlfred on GitHub.

🚀 Feature

Various packaged MTA distributions (such as mailcow) are set to use the latest and the greatest TLS.

Such an entry would be set through dovecot as:

ssl_min_protocol = TLSv1.2

Design, Layout, Architecture

In the long run, IMAP handler module should try establishing different versions, from the latest to least before returning an error.

Also, the returned error should be more descriptive.

modules/imap/handler_modules.php:

Hm_Msgs::add("ERRUnable to save this server, are the username and password correct?");

In the shortrun, a setting can be added to the add server dialog, and let the user to choose the TLS version.

P.S Thank you for cypth, it's great.

Originally created by @basaran on GitHub (Jun 1, 2021). Original GitHub issue: https://github.com/cypht-org/cypht/issues/485 Originally assigned to: @IrAlfred on GitHub. ## 🚀 Feature Various packaged MTA distributions (such as mailcow) are set to use the latest and the greatest TLS. Such an entry would be set through dovecot as: ``` ssl_min_protocol = TLSv1.2 ``` ### Design, Layout, Architecture In the long run, IMAP handler module should try establishing different versions, from the latest to least before returning an error. Also, the returned error should be more descriptive. modules/imap/handler_modules.php: ``` php Hm_Msgs::add("ERRUnable to save this server, are the username and password correct?"); ``` In the shortrun, a setting can be added to the `add server` dialog, and let the user to choose the TLS version. P.S Thank you for cypth, it's great.
kerem 2026-02-25 21:34:54 +03:00
Author
Owner

@jasonmunro commented on GitHub (Jun 8, 2021):

This has come up before and I agree we should get it done. I think maybe we should skip right to auto-determination as most folks will have no idea what to choose. Authentication errors are intentionally vague for obvious reasons, but I admit this is a PITA to troubleshoot.

<!-- gh-comment-id:856402452 --> @jasonmunro commented on GitHub (Jun 8, 2021): This has come up before and I agree we should get it done. I think maybe we should skip right to auto-determination as most folks will have no idea what to choose. Authentication errors are intentionally vague for obvious reasons, but I admit this is a PITA to troubleshoot.
Author
Owner

@basaran commented on GitHub (Jun 8, 2021):

if you would like and you don't think you can do it sooner, I will be happy to be assigned this task. I'm hoping to have an opening next month.

<!-- gh-comment-id:856758433 --> @basaran commented on GitHub (Jun 8, 2021): if you would like and you don't think you can do it sooner, I will be happy to be assigned this task. I'm hoping to have an opening next month.
Author
Owner

@jasonmunro commented on GitHub (Jun 8, 2021):

I would love your help with this, thanks for the offer! I have a ton of other stuff to work on so I will absolutely accept your offer to help. Let me know if you have questions or run into problems.

<!-- gh-comment-id:857023196 --> @jasonmunro commented on GitHub (Jun 8, 2021): I would love your help with this, thanks for the offer! I have a ton of other stuff to work on so I will absolutely accept your offer to help. Let me know if you have questions or run into problems.
Author
Owner

@jgrossophoff commented on GitHub (Sep 3, 2021):

Is there a quick workaround for this using the sailfrog Docker image? My email provider turned off TLS support for anything below v1.2 altogether so I'm sadly forced to change my email client if there is none.

<!-- gh-comment-id:912387821 --> @jgrossophoff commented on GitHub (Sep 3, 2021): Is there a quick workaround for this using the sailfrog Docker image? My email provider turned off TLS support for anything below v1.2 altogether so I'm sadly forced to change my email client if there is none.
Author
Owner

@Joshndroid commented on GitHub (Apr 24, 2022):

I have a feeling this is what is causing me issues on a fresh install with my email hoster..... i keep getting the generic message about username/password, yet it is correct.... Any updates on this?... kinda a show stopper otherwise

<!-- gh-comment-id:1107803291 --> @Joshndroid commented on GitHub (Apr 24, 2022): I have a feeling this is what is causing me issues on a fresh install with my email hoster..... i keep getting the generic message about username/password, yet it is correct.... Any updates on this?... kinda a show stopper otherwise
Author
Owner

@marclaporte commented on GitHub (Jul 31, 2022):

@basaran We need you :-)

<!-- gh-comment-id:1200478018 --> @marclaporte commented on GitHub (Jul 31, 2022): @basaran We need you :-)
Author
Owner

@marclaporte commented on GitHub (May 7, 2024):

@basaran

Please retest, as a lot has changed since you reported this issue. Notably, we now have 3 active branches and recently released Cypht 2.0.0

<!-- gh-comment-id:2097118796 --> @marclaporte commented on GitHub (May 7, 2024): @basaran Please retest, as a lot has changed since you reported this issue. Notably, we now have 3 active branches and recently released Cypht 2.0.0 - https://github.com/cypht-org/cypht/releases/tag/v2.0.0 - https://github.com/cypht-org/cypht/wiki/Lifecycle
Author
Owner

@marclaporte commented on GitHub (Sep 28, 2024):

@basaran

Last call :-)

Please test latest stable:
https://github.com/cypht-org/cypht/releases/

<!-- gh-comment-id:2380412030 --> @marclaporte commented on GitHub (Sep 28, 2024): @basaran Last call :-) Please test latest stable: https://github.com/cypht-org/cypht/releases/
Author
Owner

@IrAlfred commented on GitHub (Feb 10, 2026):

Already implemented here https://github.com/cypht-org/cypht/pull/1732

The current implementation in get_tls_stream_type() already handles TLS version negotiation automatically by enabling all available TLS versions (1.1 through 1.3) that the PHP/OpenSSL installation supports. This allows the client and server to negotiate the highest mutually supported version during the TLS handshake. I think this is fine.

<!-- gh-comment-id:3875111346 --> @IrAlfred commented on GitHub (Feb 10, 2026): Already implemented here https://github.com/cypht-org/cypht/pull/1732 The current implementation in get_tls_stream_type() already handles TLS version negotiation automatically by enabling all available TLS versions (1.1 through 1.3) that the PHP/OpenSSL installation supports. This allows the client and server to negotiate the highest mutually supported version during the TLS handshake. I think this is fine.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/cypht#382
No description provided.