From b2be182d49eea46686b5cf2680d457df61e89dc4 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 30 Jun 2018 08:49:38 +0100 Subject: gentoo resync : 30.06.2018 --- app-crypt/sbsigntool/Manifest | 7 +- .../sbsigntool-0.9.1-openssl-1.1.0-compat.patch | 152 +++++++++++++++++++++ app-crypt/sbsigntool/sbsigntool-0.6-r1.ebuild | 40 ------ app-crypt/sbsigntool/sbsigntool-0.6-r2.ebuild | 39 ++++++ app-crypt/sbsigntool/sbsigntool-0.8.ebuild | 46 ------- app-crypt/sbsigntool/sbsigntool-0.9.1-r1.ebuild | 51 +++++++ 6 files changed, 246 insertions(+), 89 deletions(-) create mode 100644 app-crypt/sbsigntool/files/sbsigntool-0.9.1-openssl-1.1.0-compat.patch delete mode 100644 app-crypt/sbsigntool/sbsigntool-0.6-r1.ebuild create mode 100644 app-crypt/sbsigntool/sbsigntool-0.6-r2.ebuild delete mode 100644 app-crypt/sbsigntool/sbsigntool-0.8.ebuild create mode 100644 app-crypt/sbsigntool/sbsigntool-0.9.1-r1.ebuild (limited to 'app-crypt/sbsigntool') diff --git a/app-crypt/sbsigntool/Manifest b/app-crypt/sbsigntool/Manifest index bf63001a7c0f..188aa58f7319 100644 --- a/app-crypt/sbsigntool/Manifest +++ b/app-crypt/sbsigntool/Manifest @@ -1,8 +1,9 @@ AUX 0002-image.c-clear-image-variable.patch 822 BLAKE2B acb775f625ecd081d9b3d7e497b066218e82d2dc13f80c473c25361dc85098ee15e5f14530334e47c33fe7cc9b2349ffb1aaba7abe4fdd33bfdde05ed9191c39 SHA512 004ba118cbe8fe5cc291888966e5994373c0b9d8149bc5c652a72971138fab5e64d721061c69e8b864d6ca5cdb4ffa193520156941b6bd9c998b256f8d72697b AUX 0003-Fix-for-multi-sign.patch 1452 BLAKE2B eaa6e39c18d13f3819d5852eda27eb5a8d589241224965392f1b1e067b5cb9ff0ece7fa83697e5fb6f5f8dd0acec15b7bbe57fcd5f761fcb2e8e1fc51193641f SHA512 2aba55a116536e7f41e4aac2fd33eeb92cf89b14bcdd8b93b6e9dc9bdaf2f0162134e56f7d365640445bf801ad8590f6d49f14cdf80b791324647067d52ae435 +AUX sbsigntool-0.9.1-openssl-1.1.0-compat.patch 4727 BLAKE2B 3b47c8086220cf12778bf5cd6018627a30ea349677eeb2cfcd1eaa1b83a25d39499ab21a1a123181a51f4138624c17e574050216f59c480e38d9774936f8b6f0 SHA512 6946e1d67161345088aee3ab54129b6e904b6008f2b275ab4eb55ed24fb2b866029f7d7ca856c5dfe76c395580f04709ad1be974369a1b4954b9e87cf812fd4b DIST sbsigntool-0.8-ccan.tar.gz 113537 BLAKE2B 8fbf27463d30c1895930628a145be2d521ae4f6adb7af3299bf2f5f4319fd643df0a07347ef6851bd41d233af4c3fc5f77002771af1c43aa0f20665aef2390b8 SHA512 6857096879f116f1802eb6b44789cbea7bb24440bc0f16503aeadf5f276fa45943f322f844dbb9abee717655205d82b830143be3a7f4424fd4146b9360674a09 -DIST sbsigntool-0.8.tar.gz 55537 BLAKE2B f81a530995b90f4030ae2bb36cdf4c5bab8fde5bbc4646029af008df9368968c1f1774317e8b0f94e6c75a33f0d79892f26d99c2987c92766f520a3b9a8e2e57 SHA512 ffc2661135dcdbdd218640f0a0657127c5519ade7ddaaa894898e382b4898829e5b877be51fce48bddd186667bf533f779cd5a323c79aad8b0e63b74f7a2c128 +DIST sbsigntool-0.9.1.tar.gz 56497 BLAKE2B 22791bd4b490f36963a19e82da3ce7b93a56d948bf44d1ffdb62fa3291a3f815b2c19d68f9180b607c2b1438f656367ec1f9002f0b1225734d16a9aadc6d20ec SHA512 ae16232327c098bbc60a9701185d856d851cb7fa8f62be64d3c8f75c8b274b8521fcc4212226189def05db980690878ee6ac9a9b418166c92442aaf35e790d29 DIST sbsigntool_0.6.orig.tar.gz 212375 BLAKE2B fab9141c7fbfa01ec24f975503ac83be4ae0664251a1311afb3d95124fec3750ce20a5ffab35b6965d4ee4585ab4ee91f25ae49488214a983b6fc006071d0968 SHA512 ed314d1cb7278cf5f27d4c3cd17f2195678419a7f9e47770429b6f95df35f7df035331e60c45970183ddd9b150a9b752f876c777929598b0525872b3255af95c -EBUILD sbsigntool-0.6-r1.ebuild 1122 BLAKE2B 86c468b5de842a7b5228ebf0e4de8eb053b44e539d4bf46a563ac57e8ced2feedffa7b0ef8f891a03d5b722886e53e95a2b62d20e571434ad0b7534aac6edcf8 SHA512 3805523425a7a4b85094c7cc1a2db43b7a8a8b15ed63f587cb5d512d76774eb77a683500f33ccb69ee2c1e55a71587b2111c6fa1cd54820137da442158a9a28d -EBUILD sbsigntool-0.8.ebuild 1242 BLAKE2B 7a26b18d70daa8c091325b3a016d634a243b57b05931b441050f77f8c435b01092ce99a52c08fe02e0d897c3c7374cd6adbdf9dfd12405a2b50f2e77678c2fd8 SHA512 bfa6d73bcf491ae0acc533d27721a18ad30b022afc26cd6f0e8cd4ade4828617ee7ef031e4782bb867b50d7652c3ccb9609b43cf4d871ffa69eb29b77bb9df34 +EBUILD sbsigntool-0.6-r2.ebuild 1063 BLAKE2B a1df369ad39fd98c81efb0c7b3f6fa43491739a3ccf36d3e5578e3dc017fef6ff8a0ec6067fb4e5f835b96dc4950d40ebeea398340a51e4aefaa9a964f59d0b1 SHA512 e9874cf541046004e0a0f2cffb4159a758eb5b878b7f3a9ecab7f36600c0b3abfa5798b69f223145d4d62df38d98f17b67319170ed6ec4209ee45c1e6c127ce5 +EBUILD sbsigntool-0.9.1-r1.ebuild 1334 BLAKE2B d773ec47da3c841c03673d852c2e32d1cea27c357028656050f3704ec1e0c7e456e712f237f90ef3dd5160a06619a8149ed24f22335e548b9bc3a718f5f5a428 SHA512 e3b42039618e185567e243f8c78756378cf0c75dd417018a658c2142bf8e9ef146f2e4e44235daa9d5d8972c7fc5c4aa1f113151c16d00800df4203f55a32fbc MISC metadata.xml 291 BLAKE2B 0aeb75750176d719f10db508a8924d0bf2fe75e8544b275a7c7e11c44320ce4f7819febb093dd3083a33a998a225f2a3b882407a8ffc03d1a57d03cbfc0a7ff2 SHA512 f7a520fc9a216ff983bd3d361c6ddb3b635eb5dcd94ed042e7c5d0beb0b4e10cdb231e2b4ace599ebb93d4bb46e071a744f1a780ec83f451bb2ee6bad4c2d8cc diff --git a/app-crypt/sbsigntool/files/sbsigntool-0.9.1-openssl-1.1.0-compat.patch b/app-crypt/sbsigntool/files/sbsigntool-0.9.1-openssl-1.1.0-compat.patch new file mode 100644 index 000000000000..2f9364f246ee --- /dev/null +++ b/app-crypt/sbsigntool/files/sbsigntool-0.9.1-openssl-1.1.0-compat.patch @@ -0,0 +1,152 @@ +diff --git a/src/fileio.c b/src/fileio.c +index 032eb1e..09bc3aa 100644 +--- a/src/fileio.c ++++ b/src/fileio.c +@@ -40,6 +40,7 @@ + #include + #include + #include ++#include + + #include + #include +diff --git a/src/idc.c b/src/idc.c +index 236cefd..6d87bd4 100644 +--- a/src/idc.c ++++ b/src/idc.c +@@ -238,7 +238,11 @@ struct idc *IDC_get(PKCS7 *p7, BIO *bio) + + /* extract the idc from the signed PKCS7 'other' data */ + str = p7->d.sign->contents->d.other->value.asn1_string; ++#if OPENSSL_VERSION_NUMBER < 0x10100000L + idcbuf = buf = ASN1_STRING_data(str); ++#else ++ idcbuf = buf = ASN1_STRING_get0_data(str); ++#endif + idc = d2i_IDC(NULL, &buf, ASN1_STRING_length(str)); + + /* If we were passed a BIO, write the idc data, minus type and length, +@@ -289,7 +293,11 @@ int IDC_check_hash(struct idc *idc, struct image *image) + } + + /* check hash against the one we calculated from the image */ ++#if OPENSSL_VERSION_NUMBER < 0x10100000L + buf = ASN1_STRING_data(str); ++#else ++ buf = ASN1_STRING_get0_data(str); ++#endif + if (memcmp(buf, sha, sizeof(sha))) { + fprintf(stderr, "Hash doesn't match image\n"); + fprintf(stderr, " got: %s\n", sha256_str(buf)); +diff --git a/src/sbattach.c b/src/sbattach.c +index a0c01b8..e89a23e 100644 +--- a/src/sbattach.c ++++ b/src/sbattach.c +@@ -231,6 +231,7 @@ int main(int argc, char **argv) + return EXIT_FAILURE; + } + ++#if OPENSSL_VERSION_NUMBER < 0x10100000L + ERR_load_crypto_strings(); + OpenSSL_add_all_digests(); + OPENSSL_config(NULL); +@@ -239,6 +240,7 @@ int main(int argc, char **argv) + * module isn't present). In either case ignore the errors + * (malloc will cause other failures out lower down */ + ERR_clear_error(); ++#endif + + image = image_load(image_filename); + if (!image) { +diff --git a/src/sbkeysync.c b/src/sbkeysync.c +index 7b17f40..419b1e7 100644 +--- a/src/sbkeysync.c ++++ b/src/sbkeysync.c +@@ -208,7 +208,11 @@ static int x509_key_parse(struct key *key, uint8_t *data, size_t len) + goto out; + + key->id_len = ASN1_STRING_length(serial); ++#if OPENSSL_VERSION_NUMBER < 0x10100000L + key->id = talloc_memdup(key, ASN1_STRING_data(serial), key->id_len); ++#else ++ key->id = talloc_memdup(key, ASN1_STRING_get0_data(serial), key->id_len); ++#endif + + key->description = talloc_array(key, char, description_len); + X509_NAME_oneline(X509_get_subject_name(x509), +@@ -927,6 +931,7 @@ int main(int argc, char **argv) + return EXIT_FAILURE; + } + ++#if OPENSSL_VERSION_NUMBER < 0x10100000L + ERR_load_crypto_strings(); + OpenSSL_add_all_digests(); + OpenSSL_add_all_ciphers(); +@@ -936,6 +941,7 @@ int main(int argc, char **argv) + * module isn't present). In either case ignore the errors + * (malloc will cause other failures out lower down */ + ERR_clear_error(); ++#endif + + ctx->filesystem_keys = init_keyset(ctx); + ctx->firmware_keys = init_keyset(ctx); +diff --git a/src/sbsign.c b/src/sbsign.c +index ff1fdfd..78d8d64 100644 +--- a/src/sbsign.c ++++ b/src/sbsign.c +@@ -188,6 +188,7 @@ int main(int argc, char **argv) + + talloc_steal(ctx, ctx->image); + ++#if OPENSSL_VERSION_NUMBER < 0x10100000L + ERR_load_crypto_strings(); + OpenSSL_add_all_digests(); + OpenSSL_add_all_ciphers(); +@@ -197,6 +198,7 @@ int main(int argc, char **argv) + * module isn't present). In either case ignore the errors + * (malloc will cause other failures out lower down */ + ERR_clear_error(); ++#endif + if (engine) + pkey = fileio_read_engine_key(engine, keyfilename); + else +diff --git a/src/sbvarsign.c b/src/sbvarsign.c +index 7dcbe51..9319c8b 100644 +--- a/src/sbvarsign.c ++++ b/src/sbvarsign.c +@@ -509,6 +509,7 @@ int main(int argc, char **argv) + return EXIT_FAILURE; + } + ++#if OPENSSL_VERSION_NUMBER < 0x10100000L + /* initialise openssl */ + OpenSSL_add_all_digests(); + OpenSSL_add_all_ciphers(); +@@ -519,6 +520,7 @@ int main(int argc, char **argv) + * module isn't present). In either case ignore the errors + * (malloc will cause other failures out lower down */ + ERR_clear_error(); ++#endif + + /* set up the variable signing context */ + varname = argv[optind]; +diff --git a/src/sbverify.c b/src/sbverify.c +index 3920d91..d0b203a 100644 +--- a/src/sbverify.c ++++ b/src/sbverify.c +@@ -250,6 +250,7 @@ int main(int argc, char **argv) + verbose = false; + detached_sig_filename = NULL; + ++#if OPENSSL_VERSION_NUMBER < 0x10100000L + OpenSSL_add_all_digests(); + ERR_load_crypto_strings(); + OPENSSL_config(NULL); +@@ -258,6 +259,7 @@ int main(int argc, char **argv) + * module isn't present). In either case ignore the errors + * (malloc will cause other failures out lower down */ + ERR_clear_error(); ++#endif + + for (;;) { + int idx; diff --git a/app-crypt/sbsigntool/sbsigntool-0.6-r1.ebuild b/app-crypt/sbsigntool/sbsigntool-0.6-r1.ebuild deleted file mode 100644 index 60b0606bfcd4..000000000000 --- a/app-crypt/sbsigntool/sbsigntool-0.6-r1.ebuild +++ /dev/null @@ -1,40 +0,0 @@ -# Copyright 1999-2016 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -EAPI="5" - -inherit eutils toolchain-funcs - -DESCRIPTION="Utilities for signing and verifying files for UEFI Secure Boot" -HOMEPAGE="https://launchpad.net/ubuntu/+source/sbsigntool" -SRC_URI="https://launchpad.net/ubuntu/+archive/primary/+files/${PN}_${PV}.orig.tar.gz" - -LICENSE="GPL-3" -SLOT="0" -KEYWORDS="amd64 x86" -IUSE="libressl" - -RDEPEND=" - !libressl? ( dev-libs/openssl:0= ) - libressl? ( dev-libs/libressl:0= ) - sys-apps/util-linux" -DEPEND="${RDEPEND} - sys-apps/help2man - sys-boot/gnu-efi - sys-libs/binutils-libs - virtual/pkgconfig" - -src_prepare() { - local iarch - case ${ARCH} in - ia64) iarch=ia64 ;; - x86) iarch=ia32 ;; - amd64) iarch=x86_64 ;; - *) die "unsupported architecture: ${ARCH}" ;; - esac - sed -i "/^EFI_ARCH=/s:=.*:=${iarch}:" configure || die - sed -i 's/-m64$/& -march=x86-64/' tests/Makefile.in || die - sed -i "/^AR /s:=.*:= $(tc-getAR):" lib/ccan/Makefile.in || die #481480 - epatch "${FILESDIR}"/0002-image.c-clear-image-variable.patch - epatch "${FILESDIR}"/0003-Fix-for-multi-sign.patch -} diff --git a/app-crypt/sbsigntool/sbsigntool-0.6-r2.ebuild b/app-crypt/sbsigntool/sbsigntool-0.6-r2.ebuild new file mode 100644 index 000000000000..464a4e833fb6 --- /dev/null +++ b/app-crypt/sbsigntool/sbsigntool-0.6-r2.ebuild @@ -0,0 +1,39 @@ +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="5" + +inherit eutils toolchain-funcs + +DESCRIPTION="Utilities for signing and verifying files for UEFI Secure Boot" +HOMEPAGE="https://launchpad.net/ubuntu/+source/sbsigntool" +SRC_URI="https://launchpad.net/ubuntu/+archive/primary/+files/${PN}_${PV}.orig.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="amd64 x86" +IUSE="" + +RDEPEND=" + dev-libs/openssl:0= + sys-apps/util-linux" +DEPEND="${RDEPEND} + sys-apps/help2man + sys-boot/gnu-efi + sys-libs/binutils-libs + virtual/pkgconfig" + +src_prepare() { + local iarch + case ${ARCH} in + ia64) iarch=ia64 ;; + x86) iarch=ia32 ;; + amd64) iarch=x86_64 ;; + *) die "unsupported architecture: ${ARCH}" ;; + esac + sed -i "/^EFI_ARCH=/s:=.*:=${iarch}:" configure || die + sed -i 's/-m64$/& -march=x86-64/' tests/Makefile.in || die + sed -i "/^AR /s:=.*:= $(tc-getAR):" lib/ccan/Makefile.in || die #481480 + epatch "${FILESDIR}"/0002-image.c-clear-image-variable.patch + epatch "${FILESDIR}"/0003-Fix-for-multi-sign.patch +} diff --git a/app-crypt/sbsigntool/sbsigntool-0.8.ebuild b/app-crypt/sbsigntool/sbsigntool-0.8.ebuild deleted file mode 100644 index 853bb5244541..000000000000 --- a/app-crypt/sbsigntool/sbsigntool-0.8.ebuild +++ /dev/null @@ -1,46 +0,0 @@ -# Copyright 1999-2017 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -EAPI="5" - -inherit eutils toolchain-funcs autotools-utils - -DESCRIPTION="Utilities for signing and verifying files for UEFI Secure Boot" -HOMEPAGE="https://git.kernel.org/cgit/linux/kernel/git/jejb/sbsigntools.git/" -SRC_URI="https://dev.gentoo.org/~tamiko/distfiles/${P}.tar.gz - https://dev.gentoo.org/~tamiko/distfiles/${P}-ccan.tar.gz" - -LICENSE="GPL-3 LGPL-3 LGPL-2.1 CC0-1.0" -SLOT="0" -KEYWORDS="~amd64 ~arm64 ~x86" -IUSE="libressl" - -RDEPEND=" - !libressl? ( dev-libs/openssl:0= ) - libressl? ( dev-libs/libressl:0= ) - sys-apps/util-linux" -DEPEND="${RDEPEND} - sys-apps/help2man - sys-boot/gnu-efi - sys-libs/binutils-libs - virtual/pkgconfig" - -S="${WORKDIR}" - -src_prepare() { - local iarch - case ${ARCH} in - amd64) iarch=x86_64 ;; - arm64) iarch=aarch64 ;; - ia64) iarch=ia64 ;; - x86) iarch=ia32 ;; - *) die "unsupported architecture: ${ARCH}" ;; - esac - sed -i "/^EFI_ARCH=/s:=.*:=${iarch}:" configure.ac || die - sed -i 's/-m64$/& -march=x86-64/' tests/Makefile.am || die - sed -i "/^AR /s:=.*:= $(tc-getAR):" lib/ccan/Makefile.in || die #481480 - - AUTOTOOLS_IN_SOURCE_BUILD=1 - AUTOTOOLS_AUTORECONF=true - autotools-utils_src_prepare -} diff --git a/app-crypt/sbsigntool/sbsigntool-0.9.1-r1.ebuild b/app-crypt/sbsigntool/sbsigntool-0.9.1-r1.ebuild new file mode 100644 index 000000000000..70e47576c088 --- /dev/null +++ b/app-crypt/sbsigntool/sbsigntool-0.9.1-r1.ebuild @@ -0,0 +1,51 @@ +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="6" + +inherit eutils autotools + +DESCRIPTION="Utilities for signing and verifying files for UEFI Secure Boot" +HOMEPAGE="https://git.kernel.org/cgit/linux/kernel/git/jejb/sbsigntools.git/" +SRC_URI="https://git.kernel.org/pub/scm/linux/kernel/git/jejb/${PN}s.git/snapshot/${PN}s-${PV}.tar.gz -> ${P}.tar.gz + https://dev.gentoo.org/~tamiko/distfiles/${PN}-0.8-ccan.tar.gz" + +LICENSE="GPL-3 LGPL-3 LGPL-2.1 CC0-1.0" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~x86" +IUSE="" + +RDEPEND=" + dev-libs/openssl:0= + sys-apps/util-linux" +DEPEND="${RDEPEND} + sys-apps/help2man + sys-boot/gnu-efi + sys-libs/binutils-libs + virtual/pkgconfig" + +S="${WORKDIR}/${PN}s-${PV}" + +PATCHES=( + "${FILESDIR}"/${P}-openssl-1.1.0-compat.patch +) + +src_prepare() { + mv "${WORKDIR}"/lib/ccan "${S}"/lib || die "mv failed" + rmdir "${WORKDIR}"/lib || die "rmdir failed" + + local iarch + case ${ARCH} in + amd64) iarch=x86_64 ;; + arm64) iarch=aarch64 ;; + ia64) iarch=ia64 ;; + x86) iarch=ia32 ;; + *) die "unsupported architecture: ${ARCH}" ;; + esac + sed -i "/^EFI_ARCH=/s:=.*:=${iarch}:" configure.ac || die + sed -i 's/-m64$/& -march=x86-64/' tests/Makefile.am || die + sed -i "/^AR /s:=.*:= $(tc-getAR):" lib/ccan/Makefile.in || die #481480 + + default + eautoreconf +} -- cgit v1.2.3