mirror of
https://github.com/strongswan/strongswan.git
synced 2025-10-04 00:00:14 -04:00
curl: Don't ignore unknown SSL/TLS backends
Only older versions of OpenSSL and GnuTLS need special treatment, so we now accept all other backends (e.g. "(SecureTransport) OpenSSL/1.1.1s" on macOS). Whenever we remove support for the affected versions of the mentioned libraries, we can remove the corresponding *-threading plugin feature and the code here.
This commit is contained in:
parent
e99de2aee9
commit
d11868fb38
@ -60,7 +60,9 @@ static void add_feature(private_curl_plugin_t *this, plugin_feature_t f)
|
|||||||
static void add_feature_with_ssl(private_curl_plugin_t *this, const char *ssl,
|
static void add_feature_with_ssl(private_curl_plugin_t *this, const char *ssl,
|
||||||
char *proto, plugin_feature_t f)
|
char *proto, plugin_feature_t f)
|
||||||
{
|
{
|
||||||
/* http://curl.haxx.se/libcurl/c/libcurl-tutorial.html#Multi-threading */
|
/* according to https://curl.se/libcurl/c/threadsafe.html there is only an
|
||||||
|
* issue with thread-safety with older versions of OpenSSL (<= 1.0.2) and
|
||||||
|
* GnuTLS (< 1.6.0), so we just accept all other SSL backends */
|
||||||
if (strpfx(ssl, "OpenSSL") || strpfx(ssl, "LibreSSL"))
|
if (strpfx(ssl, "OpenSSL") || strpfx(ssl, "LibreSSL"))
|
||||||
{
|
{
|
||||||
add_feature(this, f);
|
add_feature(this, f);
|
||||||
@ -71,15 +73,9 @@ static void add_feature_with_ssl(private_curl_plugin_t *this, const char *ssl,
|
|||||||
add_feature(this, f);
|
add_feature(this, f);
|
||||||
add_feature(this, PLUGIN_DEPENDS(CUSTOM, "gcrypt-threading"));
|
add_feature(this, PLUGIN_DEPENDS(CUSTOM, "gcrypt-threading"));
|
||||||
}
|
}
|
||||||
else if (strpfx(ssl, "NSS") ||
|
|
||||||
strpfx(ssl, "BoringSSL"))
|
|
||||||
{
|
|
||||||
add_feature(this, f);
|
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
DBG1(DBG_LIB, "curl SSL backend '%s' not supported, %s disabled",
|
add_feature(this, f);
|
||||||
ssl, proto);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user