[gentoo-dev] [PATCH] verify-sig.eclass: Add a function to verify pure checksums

2022-02-15 Thread Michał Górny
Split the logic for verifying checksums into a dedicated functions
that can also be used directly when dealing with a checksum file
that uses a detached signature.

Signed-off-by: Michał Górny 
---
 eclass/verify-sig.eclass | 45 +---
 1 file changed, 38 insertions(+), 7 deletions(-)

diff --git a/eclass/verify-sig.eclass b/eclass/verify-sig.eclass
index 3693eb16ff41..9121d85bbeaf 100644
--- a/eclass/verify-sig.eclass
+++ b/eclass/verify-sig.eclass
@@ -197,17 +197,27 @@ verify-sig_verify_message() {
esac
 }
 
-# @FUNCTION: _gpg_verify_signed_checksums
-# @INTERNAL
-# @USAGE:[]
+# @FUNCTION: verify-sig_verify_unsigned_checksums
+# @USAGE:   
 # @DESCRIPTION:
-# GnuPG-specific function to verify a signed checksums list.
-_gpg_verify_signed_checksums() {
+# Verify the checksums for all files listed in the space-separated list
+#  (akin to ${A}) using a .   specifies
+# the checksum algorithm (e.g. sha256).   can be "-"
+# for stdin.
+#
+# The function dies if one of the files does not match checksums or
+# is missing from the checksum file.
+#
+# Note that this function itself can only verify integrity of the files.
+# In order to verify their authenticity, the  must
+# be verified against a signature first, e.g. using
+# verify-sig_verify_detached.  If it contains inline signature, use
+# verify-sig_verify_signed_checksums instead.
+verify-sig_verify_unsigned_checksums() {
local checksum_file=${1}
local algo=${2}
local files=()
read -r -d '' -a files <<<"${3}"
-   local key=${4:-${VERIFY_SIG_OPENPGP_KEY_PATH}}
local chksum_prog chksum_len
 
case ${algo} in
@@ -220,8 +230,13 @@ _gpg_verify_signed_checksums() {
;;
esac
 
+   [[ ${checksum_file} == - ]] && checksum_file=/dev/stdin
local checksum filename junk ret=0 count=0
while read -r checksum filename junk; do
+   if [[ ${checksum} == "-BEGIN" ]]; then
+   die "${FUNCNAME}: PGP armor found, use 
verify-sig_verify_signed_checksums instead"
+   fi
+
[[ ${#checksum} -eq ${chksum_len} ]] || continue
[[ -z ${checksum//[0-9a-f]} ]] || continue
has "${filename}" "${files[@]}" || continue
@@ -233,7 +248,7 @@ _gpg_verify_signed_checksums() {
else
ret=1
fi
-   done < <(verify-sig_verify_message "${checksum_file}" - "${key}")
+   done < "${checksum_file}"
 
[[ ${ret} -eq 0 ]] ||
die "${FUNCNAME}: at least one file did not verify successfully"
@@ -241,6 +256,22 @@ _gpg_verify_signed_checksums() {
die "${FUNCNAME}: checksums for some of the specified files 
were missing"
 }
 
+# @FUNCTION: _gpg_verify_signed_checksums
+# @INTERNAL
+# @USAGE:[]
+# @DESCRIPTION:
+# GnuPG-specific function to verify a signed checksums list.
+_gpg_verify_signed_checksums() {
+   local checksum_file=${1}
+   local algo=${2}
+   local files=${3}
+   local key=${4:-${VERIFY_SIG_OPENPGP_KEY_PATH}}
+
+   verify-sig_verify_unsigned_checksums - "${algo}" "${files}" < <(
+   verify-sig_verify_message "${checksum_file}" - "${key}"
+   )
+}
+
 # @FUNCTION: verify-sig_verify_signed_checksums
 # @USAGE:[]
 # @DESCRIPTION:
-- 
2.35.1




[gentoo-dev] Last rites: dev-java/upnplib, dev-java/apple-java-extensions-bin

2022-02-15 Thread Jakov Smolić
# Volkmar W. Pogatzki  (2022-02-15)
# Java libraries without consumers. Removal in 30 days.
dev-java/upnplib
dev-java/apple-java-extensions-bin
-- 
Jakov



OpenPGP_signature
Description: OpenPGP digital signature


[gentoo-dev] Last-rites: games-strategy/triplea

2022-02-15 Thread Jakov Smolić
# Volkmar W. Pogatzki  (2022-02-13)
# This package is completely broken and some libraries existing only for
# it cause unneeded workload for Java team. Removal in 30 days.
# Bug #831106, bug #784107.
games-strategy/triplea
-- 
Jakov



OpenPGP_signature
Description: OpenPGP digital signature


[gentoo-dev] Packages up for grabs: x11-misc/xhkeys

2022-02-15 Thread Jonas Stein

Dear all

the following packages are up for grabs after dropping
desktop-misc:

x11-misc/xhkeys
https://packages.gentoo.org/packages/x11-misc/xhkeys

--
Best,
Jonas



[gentoo-dev] Last rites: emboss-r2.eclass

2022-02-15 Thread David Seifert
# @DEAD
# Removal on 2022-03-15.


signature.asc
Description: This is a digitally signed message part


Re: [gentoo-dev] Package up for grabs: dev-vcs/git-sizer

2022-02-15 Thread Yixun Lan
On 00:29 Mon 14 Feb , Ulrich Mueller wrote:
> I am no longer interested in maintaining this package.
> It has no open bugs, but is one release behind upstream.
> 
I will take care it

-- 
Yixun Lan (dlan)
Gentoo Linux Developer
GPG Key ID AABEFD55