[Rpm-maint] [rpm-software-management/rpm] Add ability to calculate filedigests using Streebog-256 and Streebog-… (#1082)

Neal Gompa (ニール・ゴンパ) notifications at github.com
Fri Feb 21 01:54:03 UTC 2020


Conan-Kudo requested changes on this pull request.

It's a good first start, just some initial nits...

> @@ -395,6 +395,7 @@ AC_SUBST(WITH_OPENSSL_LIB)
 WITH_LIBGCRYPT_INCLUDE=
 WITH_LIBGCRYPT_LIB=
 if test "$with_crypto" = libgcrypt ; then
+  AC_DEFINE(WITH_LIBGCRYPT, 1, [Build with libgcrypt instead of nss3 support?])

Why the `instead of nss3 support?`? This could just be `Build with libgcrypt as the crypto backend`.

> @@ -1229,6 +1229,17 @@ static const struct rpmlibProvides_s rpmlibProvides[] = {
     { "rpmlib(FileDigests)", 		"4.6.0-1",
 	(		 RPMSENSE_EQUAL),
     N_("file digest algorithm is per package configurable") },
+#ifdef WITH_LIBGCRYPT
+    /*
+     * As rpmlib(FileDigestsGOST12) is available only when RPM is built with libcgrypt,
+     * to avoid other versions of RPM from misunderatanding hashes
+     * (see e.g. https://github.com/rpm-software-management/rpm/issues/959),
+     * require FileDigestsGOST12 separately
+     */
+    { "rpmlib(FileDigestsGOST12)", 		"4.16.0-1",
+	(		 RPMSENSE_RPMLIB|RPMSENSE_EQUAL),
+    N_("file digest can be GOST R 34.11 2012 (STREEBOG256, STREEBOG512)") },

I'm not sure how to word this yet, but I don't like this wording much...

> @@ -266,6 +266,8 @@ typedef enum pgpHashAlgo_e {
     PGPHASHALGO_SHA384		=  9,	/*!< SHA384 */
     PGPHASHALGO_SHA512		= 10,	/*!< SHA512 */
     PGPHASHALGO_SHA224		= 11,	/*!< SHA224 */
+    PGPHASHALGO_GOST12_256	= 100,	/*!< GOST R 34.11-2012 256 */
+    PGPHASHALGO_GOST12_512	= 101,	/*!< GOST R 34.11-2012 512 */

Is there a reason we jump so many values?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/1082#pullrequestreview-362355795
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20200220/f79cc29e/attachment.html>


More information about the Rpm-maint mailing list