-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1149 from flatcar/tormath1/sign
core_sign_update: use pkcs11 openssl engine
- Loading branch information
Showing
42 changed files
with
1,665 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
#!/usr/bin/env bash | ||
set -euo pipefail | ||
|
||
if [ $# -lt 1 ] || [ "$1" = "-h" ] || [ "$1" = "--help" ]; then | ||
echo "Usage: $0 RELEASE_DESCRIPTORS..." | ||
echo "Example: $0 alpha:1786.0.0 beta:1781.2.0" | ||
echo "Downloads the release update payloads to ARCH-usr/VERSION/ folders." | ||
echo "Expected to be run in .../sdk/src/scripts/data/" | ||
echo "(usually before entering the chroot and running ./generate_payload data/ARCH-usr/VERSION/ keys/)." | ||
exit 1 | ||
fi | ||
|
||
if [ "$(basename "${PWD}")" != "data" ] || [ "$(basename "$(readlink -f ..)")" != "scripts" ]; then | ||
echo "Expected to be run in .../sdk/src/scripts/data/" >&2 | ||
exit 1 | ||
fi | ||
|
||
# Same as in copy-to-origin.sh and set-symlink.sh | ||
for TUPLE_COL in "$@"; do | ||
IFS=":" read -r -a TUPLE <<< "${TUPLE_COL}" | ||
CHANNEL="${TUPLE[0]}" | ||
VERSION="${TUPLE[1]}" | ||
for ARCH in amd64 arm64; do | ||
echo "Downloading ${CHANNEL} ${VERSION} ${ARCH}" | ||
rm -rf "${ARCH}-usr/${VERSION}" | ||
mkdir -p "${ARCH}-usr/${VERSION}" && cd "${ARCH}-usr/${VERSION}" | ||
BASEURL="https://bincache.flatcar-linux.net/images/${ARCH}/${VERSION}/" | ||
# Note: Don't replace this with 'mapfile -t array < <(curl)' or 'read -r -a array <<< "$(curl)"' because that has no error checking | ||
EXTRA_PAYLOADS=($(curl -H 'Accept: application/json' -fsSL "${BASEURL}" | jq -r ".[].name" | { grep -P '^(oem|flatcar)-.*raw(.sig)?$' || true ; })) | ||
wget "${BASEURL}"{flatcar_production_update.bin.bz2,flatcar_production_update.bin.bz2.sig,flatcar_production_image.vmlinuz,flatcar_production_image.vmlinuz.sig} | ||
for EXTRA_PAYLOAD in "${EXTRA_PAYLOADS[@]}"; do | ||
wget "${BASEURL}${EXTRA_PAYLOAD}" | ||
done | ||
cd ../.. | ||
done | ||
done | ||
echo "Success" |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 5 additions & 0 deletions
5
sdk_container/src/third_party/portage-stable/acct-group/openct/metadata.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> | ||
<pkgmetadata> | ||
<!-- maintainer-needed --> | ||
</pkgmetadata> |
8 changes: 8 additions & 0 deletions
8
sdk_container/src/third_party/portage-stable/acct-group/openct/openct-0-r2.ebuild
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Copyright 2020-2023 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI=7 | ||
|
||
inherit acct-group | ||
|
||
ACCT_GROUP_ID=46 |
5 changes: 5 additions & 0 deletions
5
sdk_container/src/third_party/portage-stable/acct-group/pcscd/metadata.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> | ||
<pkgmetadata> | ||
<!-- maintainer-needed --> | ||
</pkgmetadata> |
8 changes: 8 additions & 0 deletions
8
sdk_container/src/third_party/portage-stable/acct-group/pcscd/pcscd-0-r2.ebuild
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Copyright 2020-2023 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI=7 | ||
|
||
inherit acct-group | ||
|
||
ACCT_GROUP_ID=47 |
5 changes: 5 additions & 0 deletions
5
sdk_container/src/third_party/portage-stable/acct-group/usb/metadata.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> | ||
<pkgmetadata> | ||
<!-- maintainer-needed --> | ||
</pkgmetadata> |
8 changes: 8 additions & 0 deletions
8
sdk_container/src/third_party/portage-stable/acct-group/usb/usb-0-r2.ebuild
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Copyright 2020-2023 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI=7 | ||
|
||
inherit acct-group | ||
|
||
ACCT_GROUP_ID=85 |
5 changes: 5 additions & 0 deletions
5
sdk_container/src/third_party/portage-stable/acct-user/pcscd/metadata.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> | ||
<pkgmetadata> | ||
<!-- maintainer-needed --> | ||
</pkgmetadata> |
13 changes: 13 additions & 0 deletions
13
sdk_container/src/third_party/portage-stable/acct-user/pcscd/pcscd-0-r2.ebuild
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# Copyright 2020-2023 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI=7 | ||
|
||
inherit acct-user | ||
|
||
DESCRIPTION="A user for pcsc-lite" | ||
ACCT_USER_ID=47 | ||
ACCT_USER_GROUPS=( pcscd openct usb ) | ||
ACCT_USER_GROUPS=( pcscd openct ) | ||
|
||
acct-user_add_deps |
1 change: 1 addition & 0 deletions
1
sdk_container/src/third_party/portage-stable/app-crypt/ccid/Manifest
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
DIST ccid-1.5.1.tar.bz2 702586 BLAKE2B 7b9e3c6daf03c186f34ac9b13bd960293a6481f9237ee52937ece1040bd3a79b7dab318e1244205a7feae992261ab5e82292d80ae023a4f621e0e7af7cdb9df5 SHA512 492bde96f5752e2a5316693c44e35e2d041785a00d15e094905c0aafad392f5329009d12801899367276328a582936ee53a1c5239c1813c4536001cb8a608f2e |
45 changes: 45 additions & 0 deletions
45
sdk_container/src/third_party/portage-stable/app-crypt/ccid/ccid-1.5.1.ebuild
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# Copyright 1999-2023 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI=8 | ||
|
||
inherit udev | ||
|
||
DESCRIPTION="CCID free software driver" | ||
HOMEPAGE="https://ccid.apdu.fr https://github.com/LudovicRousseau/CCID" | ||
SRC_URI="https://ccid.apdu.fr/files/${P}.tar.bz2" | ||
|
||
LICENSE="GPL-2" | ||
SLOT="0" | ||
KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~ia64 ppc ppc64 ~riscv ~sparc x86" | ||
IUSE="twinserial +usb" | ||
|
||
RDEPEND=" | ||
>=sys-apps/pcsc-lite-1.8.3 | ||
twinserial? ( dev-lang/perl ) | ||
usb? ( virtual/libusb:1 ) | ||
" | ||
DEPEND="${RDEPEND}" | ||
BDEPEND="virtual/pkgconfig" | ||
|
||
src_configure() { | ||
econf \ | ||
LEX=: \ | ||
$(use_enable twinserial) \ | ||
$(use_enable usb libusb) | ||
} | ||
|
||
src_install() { | ||
default | ||
udev_newrules src/92_pcscd_ccid.rules 92-pcsc-ccid.rules | ||
} | ||
|
||
pkg_postinst() { | ||
udev_reload | ||
einfo "Check https://github.com/LudovicRousseau/CCID/blob/master/INSTALL" | ||
einfo "for more info about how to configure and use ccid" | ||
} | ||
|
||
pkg_postrm() { | ||
udev_reload | ||
} |
11 changes: 11 additions & 0 deletions
11
sdk_container/src/third_party/portage-stable/app-crypt/ccid/metadata.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> | ||
<pkgmetadata> | ||
<!-- maintainer-needed --> | ||
<use> | ||
<flag name="twinserial">Enable twinserial reader</flag> | ||
</use> | ||
<upstream> | ||
<remote-id type="github">LudovicRousseau/CCID</remote-id> | ||
</upstream> | ||
</pkgmetadata> |
1 change: 1 addition & 0 deletions
1
sdk_container/src/third_party/portage-stable/dev-libs/libp11/Manifest
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
DIST libp11-0.4.12.tar.gz 516414 BLAKE2B a816749984753a1916dd58860c51b49d316946b59eb3bc839f6a21dcff14de48d7a4937f55fc7ad96a26b914591854d5cf11a1fbac2d5f2f5e04c833973c0e42 SHA512 674cfca2c9eaf162262204c94f9d59d3095dabbc348c1842e758b897e1a5bd4ba08b2d589ec3b2a2d1343a8760eab253e7008dc09ef5b499e2f16385efe5c8cc |
50 changes: 50 additions & 0 deletions
50
...iner/src/third_party/portage-stable/dev-libs/libp11/files/libp11-0.4.12-openssl-3.1.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
https://github.com/OpenSC/libp11/pull/503 | ||
https://bugs.gentoo.org/910203 | ||
|
||
From 580c12b78b63d88010a6178d7c4c58186938c479 Mon Sep 17 00:00:00 2001 | ||
From: Dominique Leuenberger <[email protected]> | ||
Date: Tue, 6 Jun 2023 14:27:46 +0200 | ||
Subject: [PATCH] Detect openSSL 3.1; compatible to openSSL 3.0 | ||
|
||
--- | ||
configure.ac | 2 +- | ||
1 file changed, 1 insertion(+), 1 deletion(-) | ||
|
||
diff --git a/configure.ac b/configure.ac | ||
index d6b0ee91..b96979d9 100644 | ||
--- a/configure.ac | ||
+++ b/configure.ac | ||
@@ -33,7 +33,7 @@ AC_C_BIGENDIAN | ||
# issues with applications linking to new openssl, old libp11, and vice versa | ||
case "`$PKG_CONFIG --modversion --silence-errors libcrypto || \ | ||
$PKG_CONFIG --modversion openssl`" in | ||
- 3.0.*) # Predicted engines directory prefix for OpenSSL 3.x | ||
+ 3.1.*|3.0.*) # Predicted engines directory prefix for OpenSSL 3.x | ||
LIBP11_LT_OLDEST="3" | ||
debian_ssl_prefix="openssl-3.0.0";; | ||
1.1.*) # Predicted engines directory prefix for OpenSSL 1.1.x | ||
From 0697773b403efb8e7fa9f0c0fddcb499fb9b6337 Mon Sep 17 00:00:00 2001 | ||
From: Mike Gilbert <[email protected]> | ||
Date: Thu, 13 Jul 2023 13:52:54 -0400 | ||
Subject: [PATCH] configure: treat all openssl-3.x releases the same | ||
|
||
OpenSSL's soversion will not change for any 3.x minor release. | ||
|
||
https://www.openssl.org/policies/general/versioning-policy.html | ||
--- | ||
configure.ac | 2 +- | ||
1 file changed, 1 insertion(+), 1 deletion(-) | ||
|
||
diff --git a/configure.ac b/configure.ac | ||
index b96979d9..c344e84a 100644 | ||
--- a/configure.ac | ||
+++ b/configure.ac | ||
@@ -33,7 +33,7 @@ AC_C_BIGENDIAN | ||
# issues with applications linking to new openssl, old libp11, and vice versa | ||
case "`$PKG_CONFIG --modversion --silence-errors libcrypto || \ | ||
$PKG_CONFIG --modversion openssl`" in | ||
- 3.1.*|3.0.*) # Predicted engines directory prefix for OpenSSL 3.x | ||
+ 3.*) # Predicted engines directory prefix for OpenSSL 3.x | ||
LIBP11_LT_OLDEST="3" | ||
debian_ssl_prefix="openssl-3.0.0";; | ||
1.1.*) # Predicted engines directory prefix for OpenSSL 1.1.x |
31 changes: 31 additions & 0 deletions
31
sdk_container/src/third_party/portage-stable/dev-libs/libp11/libp11-0.4.12-r1.ebuild
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# Copyright 1999-2022 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI=8 | ||
|
||
DESCRIPTION="Abstraction layer to simplify PKCS#11 API" | ||
HOMEPAGE="https://github.com/opensc/libp11/wiki" | ||
SRC_URI="https://github.com/OpenSC/${PN}/releases/download/${P}/${P}.tar.gz" | ||
|
||
LICENSE="LGPL-2.1" | ||
SLOT="0" | ||
KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~loong ppc ppc64 ~riscv ~s390 sparc x86" | ||
IUSE="doc static-libs" | ||
|
||
RDEPEND="dev-libs/openssl:=[bindist(+)]" | ||
DEPEND="${RDEPEND}" | ||
BDEPEND="virtual/pkgconfig | ||
doc? ( app-doc/doxygen )" | ||
|
||
src_configure() { | ||
econf \ | ||
--enable-shared \ | ||
$(use_enable static-libs static) \ | ||
$(use_enable doc api-doc) | ||
} | ||
|
||
src_install() { | ||
default | ||
|
||
find "${ED}" -name '*.la' -delete || die | ||
} |
Oops, something went wrong.