assume Tunnel to be secure more consistently

follows up on 27458133.
This commit is contained in:
Oswald Buddenhagen 2022-05-18 17:11:59 +02:00
parent 8ba4192b23
commit 9169ee8fd8

View File

@ -2577,9 +2577,9 @@ imap_open_store_authenticate2( imap_store_t *ctx )
if (any || !strcasecmp( mech->string, cmech->string )) { if (any || !strcasecmp( mech->string, cmech->string )) {
if (!strcasecmp( cmech->string, "LOGIN" )) { if (!strcasecmp( cmech->string, "LOGIN" )) {
#ifdef HAVE_LIBSSL #ifdef HAVE_LIBSSL
if (ctx->conn.ssl || !any) if (ctx->conn.ssl || ctx->conn.conf->tunnel || !any)
#else #else
if (!any) if (ctx->conn.conf->tunnel || !any)
#endif #endif
auth_login = 1; auth_login = 1;
else else
@ -2680,7 +2680,7 @@ imap_open_store_authenticate2( imap_store_t *ctx )
if (!ensure_user( srvc ) || !ensure_password( srvc )) if (!ensure_user( srvc ) || !ensure_password( srvc ))
goto bail; goto bail;
#ifdef HAVE_LIBSSL #ifdef HAVE_LIBSSL
if (!ctx->conn.ssl) if (!ctx->conn.ssl && !ctx->conn.conf->tunnel)
#endif #endif
warn( "*** IMAP Warning *** Password is being sent in the clear\n" ); warn( "*** IMAP Warning *** Password is being sent in the clear\n" );
ctx->caps = 0; ctx->caps = 0;