mirror of
https://github.com/unrealircd/unrealircd.git
synced 2026-06-12 18:54:46 +02:00
cda2bcd930
In config.h we had a: #if OPENSSL_VERSION_NUMBER >= 0x10100000L #define UNREALIRCD_DEFAULT_ECDH_CURVES "X25519:secp521r1:secp384r1:prime256v1" #else #define UNREALIRCD_DEFAULT_ECDH_CURVES "secp521r1:secp384r1:prime256v1" #endif ...which is fine in theory, but openssl headers are not included at that point, so OPENSSL_VERSION_NUMBER was not defined. From now on, we have: #define UNREALIRCD_DEFAULT_ECDH_CURVES_PRIMARY "X25519:secp521r1:secp384r1:prime256v1" #define UNREALIRCD_DEFAULT_ECDH_CURVES_SECONDARY "secp521r1:secp384r1:prime256v1" ...and we try them in that order. If both fail, we exit with an error (like before). This because X25519 is not available in OpenSSL before 1.1.0 (so really old) and may also not be available when running in FIPS mode.