summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOYTIS <tossel@gmail.com>2019-01-25 17:25:06 +0100
committerGitHub <noreply@github.com>2019-01-25 17:25:06 +0100
commit826b15d0c3d45580d15a4c7bbf88f8bc3379bd70 (patch)
treecba1d9563ec4941e5859e467b57eec5ba9c84bf1
parentf4e46ffa9992ee41cc6ac1dff71f2c9907290a81 (diff)
parent5ac462299def05b7a49be25a0076c611482cb9c9 (diff)
downloadmeta-updater-826b15d0c3d45580d15a4c7bbf88f8bc3379bd70.tar.gz
Merge pull request #459 from ricardosalveti/hsm
Update softhsm and libp11 to latest
-rw-r--r--recipes-support/libp11/files/0001-Workaround-for-a-buggy-version-of-openssl-1.0.2m.patch42
-rw-r--r--recipes-support/libp11/libp11_git.bb (renamed from recipes-support/libp11/libp11_0.4.9.bb)7
-rw-r--r--recipes-support/softhsm/files/0001-Cross-compilation-tweaks.patch86
-rw-r--r--recipes-support/softhsm/softhsm_git.bb31
4 files changed, 19 insertions, 147 deletions
diff --git a/recipes-support/libp11/files/0001-Workaround-for-a-buggy-version-of-openssl-1.0.2m.patch b/recipes-support/libp11/files/0001-Workaround-for-a-buggy-version-of-openssl-1.0.2m.patch
deleted file mode 100644
index 55f2ed3..0000000
--- a/recipes-support/libp11/files/0001-Workaround-for-a-buggy-version-of-openssl-1.0.2m.patch
+++ /dev/null
@@ -1,42 +0,0 @@
1From ccab5ce63dd5d3dbb4bd02998d21d34407e550f2 Mon Sep 17 00:00:00 2001
2From: Anton Gerasimov <anton.gerasimov@here.com>
3Date: Fri, 19 Jan 2018 12:44:27 +0100
4Subject: [PATCH] Workaround for a buggy version of openssl (1.0.2m)
5
6---
7 src/p11_pkey.c | 12 +++++++++---
8 1 file changed, 9 insertions(+), 3 deletions(-)
9
10diff --git a/src/p11_pkey.c b/src/p11_pkey.c
11index 45d5ad3..75625e6 100644
12--- a/src/p11_pkey.c
13+++ b/src/p11_pkey.c
14@@ -139,8 +139,14 @@ static void EVP_PKEY_meth_copy(EVP_PKEY_METHOD *dst, const EVP_PKEY_METHOD *src)
15
16 #endif
17
18-#if OPENSSL_VERSION_NUMBER < 0x100020d0L || defined(LIBRESSL_VERSION_NUMBER)
19-static void EVP_PKEY_meth_get_sign(EVP_PKEY_METHOD *pmeth,
20+#if OPENSSL_VERSION_NUMBER < 0x10002110L || defined(LIBRESSL_VERSION_NUMBER)
21+
22+# if (OPENSSL_VERSION_NUMBER & 0xFFFFFFF0) == 0x100020d0L
23+# undef EVP_PKEY_meth_get_sign
24+# undef EVP_PKEY_meth_get_decrypt
25+# endif
26+
27+void EVP_PKEY_meth_get_sign(EVP_PKEY_METHOD *pmeth,
28 int (**psign_init) (EVP_PKEY_CTX *ctx),
29 int (**psign) (EVP_PKEY_CTX *ctx,
30 unsigned char *sig, size_t *siglen,
31@@ -152,7 +158,7 @@ static void EVP_PKEY_meth_get_sign(EVP_PKEY_METHOD *pmeth,
32 *psign = pmeth->sign;
33 }
34
35-static void EVP_PKEY_meth_get_decrypt(EVP_PKEY_METHOD *pmeth,
36+void EVP_PKEY_meth_get_decrypt(EVP_PKEY_METHOD *pmeth,
37 int (**pdecrypt_init) (EVP_PKEY_CTX *ctx),
38 int (**pdecrypt) (EVP_PKEY_CTX *ctx,
39 unsigned char *out,
40--
412.15.1
42
diff --git a/recipes-support/libp11/libp11_0.4.9.bb b/recipes-support/libp11/libp11_git.bb
index 6d0165f..bedcdc8 100644
--- a/recipes-support/libp11/libp11_0.4.9.bb
+++ b/recipes-support/libp11/libp11_git.bb
@@ -9,9 +9,10 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=fad9b3332be894bab9bc501572864b29"
9DEPENDS = "libtool openssl" 9DEPENDS = "libtool openssl"
10RDEPENDS_${PN} += " opensc" 10RDEPENDS_${PN} += " opensc"
11 11
12SRC_URI = "git://github.com/OpenSC/libp11.git \ 12SRC_URI = "git://github.com/OpenSC/libp11.git"
13 file://0001-Workaround-for-a-buggy-version-of-openssl-1.0.2m.patch" 13SRCREV = "57ca68ff67efa08e3be1f26dec6d23bf5bb977f2"
14SRCREV = "e1210903291b1de9eabcad26e740a4b2fbcca692" 14
15PV = "0.4.9+git${SRCPV}"
15 16
16S = "${WORKDIR}/git" 17S = "${WORKDIR}/git"
17 18
diff --git a/recipes-support/softhsm/files/0001-Cross-compilation-tweaks.patch b/recipes-support/softhsm/files/0001-Cross-compilation-tweaks.patch
deleted file mode 100644
index b3a7622..0000000
--- a/recipes-support/softhsm/files/0001-Cross-compilation-tweaks.patch
+++ /dev/null
@@ -1,86 +0,0 @@
1From b6add28acb884b6006216e8422cc18504483c72e Mon Sep 17 00:00:00 2001
2From: Anton Gerasimov <anton@advancedtelematic.com>
3Date: Fri, 8 Sep 2017 15:08:40 +0200
4Subject: [PATCH] Cross-compilation tweaks
5
6---
7 m4/acx_openssl.m4 | 2 ++
8 m4/acx_openssl_ecc.m4 | 3 +++
9 m4/acx_openssl_fips.m4 | 2 ++
10 m4/acx_openssl_gost.m4 | 2 ++
11 4 files changed, 9 insertions(+)
12
13diff --git a/m4/acx_openssl.m4 b/m4/acx_openssl.m4
14index e90c78f..9de6055 100644
15--- a/m4/acx_openssl.m4
16+++ b/m4/acx_openssl.m4
17@@ -25,6 +25,7 @@ AC_DEFUN([ACX_OPENSSL],[
18 AC_CHECK_HEADERS([openssl/ssl.h],,[AC_MSG_ERROR([Can't find OpenSSL headers])])
19 AC_CHECK_LIB(crypto, BN_new,,[AC_MSG_ERROR([Can't find OpenSSL library])])
20
21+ if test "$cross_compiling" != yes; then
22 AC_MSG_CHECKING([for OpenSSL version])
23 CHECK_OPENSSL_VERSION=m4_format(0x%02x%02x%02x000L, $1, $2, $3)
24 AC_LANG_PUSH([C])
25@@ -51,6 +52,7 @@ AC_DEFUN([ACX_OPENSSL],[
26 AC_MSG_ERROR([OpenSSL library too old ($1.$2.$3 or later required)])
27 ],[])
28 AC_LANG_POP([C])
29+ fi
30
31 CPPFLAGS=$tmp_CPPFLAGS
32 LIBS=$tmp_LIBS
33diff --git a/m4/acx_openssl_ecc.m4 b/m4/acx_openssl_ecc.m4
34index 612c505..ba2389d 100644
35--- a/m4/acx_openssl_ecc.m4
36+++ b/m4/acx_openssl_ecc.m4
37@@ -1,4 +1,5 @@
38 AC_DEFUN([ACX_OPENSSL_ECC],[
39+ if test "$cross_compiling" != yes; then
40 AC_MSG_CHECKING(for OpenSSL ECC support)
41
42 tmp_CPPFLAGS=$CPPFLAGS
43@@ -32,6 +33,8 @@ AC_DEFUN([ACX_OPENSSL_ECC],[
44 ],[])
45 AC_LANG_POP([C])
46
47+ fi
48+
49 CPPFLAGS=$tmp_CPPFLAGS
50 LIBS=$tmp_LIBS
51 ])
52diff --git a/m4/acx_openssl_fips.m4 b/m4/acx_openssl_fips.m4
53index 0491397..896cdbf 100644
54--- a/m4/acx_openssl_fips.m4
55+++ b/m4/acx_openssl_fips.m4
56@@ -1,4 +1,5 @@
57 AC_DEFUN([ACX_OPENSSL_FIPS],[
58+ if test "$cross_compiling" != yes; then
59 AC_MSG_CHECKING(for OpenSSL FIPS capable library)
60
61 tmp_CPPFLAGS=$CPPFLAGS
62@@ -47,4 +48,5 @@ AC_DEFUN([ACX_OPENSSL_FIPS],[
63
64 CPPFLAGS=$tmp_CPPFLAGS
65 LIBS=$tmp_LIBS
66+ fi
67 ])
68diff --git a/m4/acx_openssl_gost.m4 b/m4/acx_openssl_gost.m4
69index dca489b..34c39d8 100644
70--- a/m4/acx_openssl_gost.m4
71+++ b/m4/acx_openssl_gost.m4
72@@ -1,4 +1,5 @@
73 AC_DEFUN([ACX_OPENSSL_GOST],[
74+ if test "$cross_compiling" != yes; then
75 AC_MSG_CHECKING(for OpenSSL GOST support)
76
77 tmp_CPPFLAGS=$CPPFLAGS
78@@ -62,4 +63,5 @@ AC_DEFUN([ACX_OPENSSL_GOST],[
79
80 CPPFLAGS=$tmp_CPPFLAGS
81 LIBS=$tmp_LIBS
82+ fi
83 ])
84--
852.7.4
86
diff --git a/recipes-support/softhsm/softhsm_git.bb b/recipes-support/softhsm/softhsm_git.bb
index c26903d..4dcfe7d 100644
--- a/recipes-support/softhsm/softhsm_git.bb
+++ b/recipes-support/softhsm/softhsm_git.bb
@@ -1,27 +1,26 @@
1SUMMARY = "HSM emulator" 1SUMMARY = "HSM emulator"
2LICENSE = "BSD" 2HOMEPAGE = "https://www.opendnssec.org/softhsm/"
3LICENSE = "BSD-2-Clause & ISC"
3LIC_FILES_CHKSUM = "file://LICENSE;md5=ef3f77a3507c3d91e75b9f2bdaee4210" 4LIC_FILES_CHKSUM = "file://LICENSE;md5=ef3f77a3507c3d91e75b9f2bdaee4210"
4 5
5inherit autotools-brokensep 6DEPENDS = "openssl"
6 7
8SRC_URI = "git://github.com/opendnssec/SoftHSMv2.git;branch=master"
9SRCREV = "369df0383d101bc8952692c2a368ac8bc887d1b4"
7 10
8SRC_URI = "git://github.com/opendnssec/SoftHSMv2.git;branch=master \ 11PV = "2.5.0"
9 file://0001-Cross-compilation-tweaks.patch"
10SRCREV="1f7498c0c65b1b1ad5e1bdbd87e9d4b100705745"
11 12
12S = "${WORKDIR}/git" 13S = "${WORKDIR}/git"
13 14
14DEPENDS += " openssl" 15inherit autotools pkgconfig
15 16
16EXTRA_OECONF = "--disable-gost --with-openssl=${STAGING_LIBDIR}/.." 17# EdDSA requires OpenSSL >= 1.1.1
18EXTRA_OECONF = "--enable-eddsa --disable-gost"
17 19
18do_configure() { 20do_configure_prepend() {
19 unset docdir 21 (
20 sh ./autogen.sh 22 cd ${S}
21 oe_runconf 23 unset docdir
24 sh ./autogen.sh
25 )
22} 26}
23
24FILES_${PN} = "${bindir} \
25 ${libdir}/softhsm \
26 ${sysconfdir} \
27 ${localstatedir}/lib/softhsm "