Blame SOURCES/0011-Fix-conversions-of-bit-lengths-to-byte-lengths.patch

bda584
From 42586b51e34519f18fadef2ad3c9c9d77fde0409 Mon Sep 17 00:00:00 2001
bda584
From: Rob Crittenden <rcritten@redhat.com>
bda584
Date: Mon, 5 Mar 2018 15:54:10 -0400
bda584
Subject: [PATCH] Fix conversions of bit lengths to byte lengths
bda584
bda584
Fix a number of places where we weren't correctly converting from length
bda584
in bits to length in bytes, and one in the self-tests where the newest
bda584
version of NSS complains if the size of a signature was too large
bda584
because it was not converted at all.
bda584
bda584
Based on upstream change dd537bcc644dea163b4c8f3de08d73a60876449d
bda584
---
bda584
 tests/tools/checksig.c | 2 ++
bda584
 1 file changed, 2 insertions(+)
bda584
bda584
diff --git a/tests/tools/checksig.c b/tests/tools/checksig.c
bda584
index e690911..ab8bb11 100644
bda584
--- a/tests/tools/checksig.c
bda584
+++ b/tests/tools/checksig.c
bda584
@@ -18,6 +18,7 @@
bda584
 #include "../../src/config.h"
bda584
 
bda584
 #include <sys/types.h>
bda584
+#include <sys/param.h>
bda584
 #include <sys/select.h>
bda584
 #include <errno.h>
bda584
 #include <limits.h>
bda584
@@ -101,6 +102,7 @@ main(int argc, char **argv)
bda584
 		printf("error finding public key\n");
bda584
 		return 1;
bda584
 	}
bda584
+	signed_data.signature.len = howmany(signed_data.signature.len, 8);
bda584
 	if (VFY_VerifyDataWithAlgorithmID(signed_data.data.data,
bda584
 					  signed_data.data.len,
bda584
 					  pubkey,
bda584
-- 
bda584
1.8.3.1
bda584