You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

26 lines
1.2 KiB

  1. commit f9c40ed93330c9add953310b7ac04a0d4f43ec5c
  2. Author: Daniel Jakots <haproxy@chown.me>
  3. Date: Tue Dec 7 20:34:39 2021 -0500
  4. BUILD: ssl: unbreak the build with newer libressl
  5. In LibreSSL 3.5.0, BIO is going to become opaque, so haproxy's
  6. compat macros will no longer work. The functions they substitute
  7. have been available since LibreSSL 2.7.0.
  8. (cherry picked from commit d1a2e2b0d1da0dff726738343fbaed044fb93470)
  9. Signed-off-by: Willy Tarreau <w@1wt.eu>
  10. (cherry picked from commit ca0b6e08dcc3686794d37e8bfcc4e4a4b2adb806)
  11. Signed-off-by: Willy Tarreau <w@1wt.eu>
  12. --- a/include/haproxy/openssl-compat.h
  13. +++ b/include/haproxy/openssl-compat.h
  14. @@ -386,7 +386,7 @@ static inline void SSL_CTX_up_ref(SSL_CT
  15. #define SSL_CTX_get_extra_chain_certs(ctx, chain) do { *(chain) = (ctx)->extra_certs; } while (0)
  16. #endif
  17. -#if HA_OPENSSL_VERSION_NUMBER < 0x10100000L
  18. +#if HA_OPENSSL_VERSION_NUMBER < 0x10100000L && (!defined(LIBRESSL_VERSION_NUMBER) || LIBRESSL_VERSION_NUMBER < 0x2070000fL)
  19. #define BIO_get_data(b) (b)->ptr
  20. #define BIO_set_data(b, v) do { (b)->ptr = (v); } while (0)
  21. #define BIO_set_init(b, v) do { (b)->init = (v); } while (0)