Blame SOURCES/0001-Link-with-ssl-shim.patch

effb77
From acc0bf44f8f822bf1dd07f62c8d2533ad4f0c1ce Mon Sep 17 00:00:00 2001
3f476a
From: =?UTF-8?q?Jan=20Stan=C4=9Bk?= <jstanek@redhat.com>
3f476a
Date: Tue, 28 Apr 2020 11:15:24 +0200
effb77
Subject: [PATCH] Link with ssl-shim
3f476a
MIME-Version: 1.0
3f476a
Content-Type: text/plain; charset=UTF-8
3f476a
Content-Transfer-Encoding: 8bit
3f476a
3f476a
Signed-off-by: Jan Staněk <jstanek@redhat.com>
3f476a
---
3f476a
 node.gypi          | 10 +++++++---
3f476a
 src/node_crypto.cc |  2 +-
3f476a
 src/node_crypto.h  |  2 ++
3f476a
 3 files changed, 10 insertions(+), 4 deletions(-)
3f476a
3f476a
diff --git a/node.gypi b/node.gypi
effb77
index ad088b133b..45f6a9f45c 100644
3f476a
--- a/node.gypi
3f476a
+++ b/node.gypi
effb77
@@ -361,9 +361,13 @@
3f476a
               ],
3f476a
             }],
3f476a
           ],
3f476a
-        }]]
3f476a
-
3f476a
-    }, {
3f476a
+        }],
3f476a
+        [ 'node_shared_openssl=="true"', {
3f476a
+          'include_dirs': ['deps/node-ssl-shim/include'],
3f476a
+          'libraries': ['
3f476a
+        }]
3f476a
+    ]},
3f476a
+    {
3f476a
       'defines': [ 'HAVE_OPENSSL=0' ]
3f476a
     }],
3f476a
 
3f476a
diff --git a/src/node_crypto.cc b/src/node_crypto.cc
effb77
index 61e5a32854..d7c7d06646 100644
3f476a
--- a/src/node_crypto.cc
3f476a
+++ b/src/node_crypto.cc
effb77
@@ -1174,7 +1174,7 @@ void SecureContext::AddRootCerts(const FunctionCallbackInfo<Value>& args) {
3f476a
 
3f476a
 void SecureContext::SetCipherSuites(const FunctionCallbackInfo<Value>& args) {
3f476a
   // BoringSSL doesn't allow API config of TLS1.3 cipher suites.
3f476a
-#ifndef OPENSSL_IS_BORINGSSL
3f476a
+#if !defined OPENSSL_IS_BORINGSSL && !OPENSSL_IS_LEGACY
3f476a
   SecureContext* sc;
3f476a
   ASSIGN_OR_RETURN_UNWRAP(&sc, args.Holder());
3f476a
   Environment* env = sc->env();
3f476a
diff --git a/src/node_crypto.h b/src/node_crypto.h
3f476a
index bef98b3e24..d46730c9ba 100644
3f476a
--- a/src/node_crypto.h
3f476a
+++ b/src/node_crypto.h
3f476a
@@ -42,6 +42,8 @@
3f476a
 #include <openssl/ec.h>
3f476a
 #include <openssl/rsa.h>
3f476a
 
3f476a
+#include <node-ssl-shim/ssl-shim.h>
3f476a
+
3f476a
 namespace node {
3f476a
 namespace crypto {
3f476a
 
3f476a
-- 
effb77
2.36.1
3f476a