From: Aditya Garg Date: Sun, 08 Jun 2025 10:56:34 GMT Subject: Re: [PATCH v14 05/10] imap-send: gracefully fail if CRAM-MD5 authentication is requested without OpenSSL Message-ID: In-Reply-To: > On 7 Jun 2025, at 9:02 PM, Junio C Hamano wrote: > > Aditya Garg writes: > >> Unlike PLAIN, XOAUTH2 and OAUTHBEARER, CRAM-MD5 authentication is not >> supported by libcurl and requires OpenSSL. If the user tries to use >> CRAM-MD5 authentication without OpenSSL, the previous behaviour was to >> attempt to authenticate and fail with a die(error). Handle this in a >> better way by first checking if OpenSSL is available and then attempting >> to authenticate. If OpenSSL is not available, print an error message and >> exit gracefully. >> >> Signed-off-by: Aditya Garg >> --- >> imap-send.c | 61 ++++++++++++++++++----------------------------------- >> 1 file changed, 20 insertions(+), 41 deletions(-) > > This is a good thing to do, but I would have expected that it would > come a lot earlier in the series, perhaps immediately after 01/10 > fixes the copy-and-paste bug. If this is moved earlier in the > series, it would need to introduce the try_auth_method() helper at > the same time. Since there is no new authentication methods > introduced at that stage in the series yet, it would be quite > straight-forward to read and understand the patch, and on top of > such a solidified ground, the series can add OAuth2.0 and PLAIN > support on top. Sent a v15 with the patches rearranged.