On 29/05/25 7:28 pm, Phillip Wood wrote: > Hi Aditya > > On 28/05/2025 18:17, Aditya Garg wrote: >> Currently, imap-send allows the user to choose between libcurl and >> openssl in case Git is compiled with both libraries only using the >> command line, and no option to set a default using the config is >> available. Add support for the same. > > I'm wondering why anyone would want to switch the backend at run-time? There has been talk in the past about removing the openssl code [1] and just relying on the curl backend. I think that is a worthwhile goal as it simplifies the code and means we would avoid having to worry about whether we're using openssl correctly [2]. That would be harder to do if we add this config setting. If we don't already do so, perhaps we could start using libcurl even when openssl is also available though that does not need to be part of this patch series. OpenSSL is still needed for CRAM-MD5, something which curl does not support at all. I agree CRAM-MD5 is not popular today, but I have seen servers that still use it even today (For example rediffmail). Also, implementing more features is simply more easy and feasible with OpenSSL, curl has limitations. Lastly, in my tests, OpenSSL did perform much better in terms of sending mails than curl, and thus having that implementation does not harm if someone is ready to compile git themselves.