Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F170507004
D37053.id111975.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D37053.id111975.diff
View Options
Index: security/pkcs11-helper/files/patch-libressl-3.5
===================================================================
--- /dev/null
+++ security/pkcs11-helper/files/patch-libressl-3.5
@@ -0,0 +1,42 @@
+From 50cc9c20d7136aeee7d0651d1ba6396245f1c4d4 Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Date: Wed, 27 Apr 2022 23:26:45 +0200
+Subject: [PATCH] fix build with libressl >= 3.5.0
+
+`DSA_METHOD` is opaque since libressl 3.5.0 and
+https://github.com/libressl-portable/openbsd/commit/62c7bff5397fa44f595b161cd593d9456eca236e
+resulting in the following build failure:
+
+```
+pkcs11h-openssl.c: In function 'DSA_meth_set1_name':
+pkcs11h-openssl.c:239:41: error: invalid use of incomplete typedef 'DSA_METHOD' {aka 'struct dsa_method'}
+ 239 | rv = _pkcs11h_mem_strdup ((void *)&meth->name, name);
+ | ^~
+```
+
+Fixes:
+ - http://autobuild.buildroot.org/results/9b0d3bf7d97696c7be6de1724daaba196626b865
+
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+---
+ lib/pkcs11h-openssl.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git lib/pkcs11h-openssl.c.orig lib/pkcs11h-openssl.c
+index 961c955c..64f23ea0 100644
+--- lib/pkcs11h-openssl.c.orig
++++ lib/pkcs11h-openssl.c
+@@ -235,9 +235,13 @@ DSA_meth_free (DSA_METHOD *meth)
+ static int
+ DSA_meth_set1_name (DSA_METHOD *meth, const char *name)
+ {
++#if (defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER >= 0x30500000L)
++ return 0;
++#else
+ CK_RV rv;
+ rv = _pkcs11h_mem_strdup ((void *)&meth->name, name);
+ return rv == CKR_OK ? 1 : 0;
++#endif
+ }
+ #endif
+
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Sep 6, 3:49 AM (17 h, 9 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
38380711
Default Alt Text
D37053.id111975.diff (1 KB)
Attached To
Mode
D37053: security/pkcs11-helper: Fix build with libressl3.5
Attached
Detach File
Event Timeline
Log In to Comment