Index: head/devel/grpc/files/patch-src_core_tsi_alts_crypt_aes__gcm.cc =================================================================== --- head/devel/grpc/files/patch-src_core_tsi_alts_crypt_aes__gcm.cc (nonexistent) +++ head/devel/grpc/files/patch-src_core_tsi_alts_crypt_aes__gcm.cc (revision 467465) @@ -0,0 +1,11 @@ +--- src/core/tsi/alts/crypt/aes_gcm.cc.orig 2018-04-16 04:55:21 UTC ++++ src/core/tsi/alts/crypt/aes_gcm.cc +@@ -185,7 +185,7 @@ static grpc_status_code aes_gcm_derive_aead_key(uint8_ + const uint8_t* kdf_counter) { + unsigned char buf[EVP_MAX_MD_SIZE]; + unsigned char ctr = 1; +-#if OPENSSL_VERSION_NUMBER < 0x10100000L ++#if OPENSSL_VERSION_NUMBER < 0x10100000L || (defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x2070000fL) + HMAC_CTX hmac; + HMAC_CTX_init(&hmac); + if (!HMAC_Init_ex(&hmac, kdf_key, kKdfKeyLen, EVP_sha256(), nullptr) || Property changes on: head/devel/grpc/files/patch-src_core_tsi_alts_crypt_aes__gcm.cc ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/devel/grpc/files/patch-src_core_tsi_ssl__transport__security.cc =================================================================== --- head/devel/grpc/files/patch-src_core_tsi_ssl__transport__security.cc (revision 467464) +++ head/devel/grpc/files/patch-src_core_tsi_ssl__transport__security.cc (revision 467465) @@ -1,26 +1,35 @@ --- src/core/tsi/ssl_transport_security.cc.orig 2018-04-13 18:08:11 UTC +++ src/core/tsi/ssl_transport_security.cc @@ -19,7 +19,7 @@ #include #include "src/core/tsi/ssl_transport_security.h" - +#include #include #include @@ -58,11 +58,10 @@ extern "C" { #define TSI_SSL_MAX_PROTECTED_FRAME_SIZE_UPPER_BOUND 16384 #define TSI_SSL_MAX_PROTECTED_FRAME_SIZE_LOWER_BOUND 1024 -/* Putting a macro like this and littering the source file with #if is really - bad practice. - TODO(jboeuf): refactor all the #if / #endif in a separate module. */ -#ifndef TSI_OPENSSL_ALPN_SUPPORT +#if OPENSSL_VERSION_NUMBER >= 0x10002000L #define TSI_OPENSSL_ALPN_SUPPORT 1 +#else +#define TSI_OPENSSL_ALPN_SUPPORT 0 #endif /* TODO(jboeuf): I have not found a way to get this number dynamically from the +@@ -1547,7 +1546,7 @@ tsi_result tsi_create_ssl_client_handshaker_factory_wi + options->cipher_suites); + if (result != TSI_OK) break; + +-#if OPENSSL_VERSION_NUMBER >= 0x10100000 ++#if OPENSSL_VERSION_NUMBER >= 0x10100000 && !(defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x2070000fL) + // X509_STORE_up_ref is only available since OpenSSL 1.1. + if (options->root_store != nullptr) { + X509_STORE_up_ref(options->root_store->store);