[Pkg-openssl-changes] r629 - openssl/trunk/debian/patches
Kurt Roeckx
kroeckx at moszumanska.debian.org
Sun Dec 22 19:03:43 UTC 2013
Author: kroeckx
Date: 2013-12-22 19:03:43 +0000 (Sun, 22 Dec 2013)
New Revision: 629
Modified:
openssl/trunk/debian/patches/req_bits.patch
Log:
Make the patch actually work.
Modified: openssl/trunk/debian/patches/req_bits.patch
===================================================================
--- openssl/trunk/debian/patches/req_bits.patch 2013-12-22 18:26:30 UTC (rev 628)
+++ openssl/trunk/debian/patches/req_bits.patch 2013-12-22 19:03:43 UTC (rev 629)
@@ -5,17 +5,39 @@
Index: openssl-1.0.1e/apps/req.c
===================================================================
---- openssl-1.0.1e.orig/apps/req.c 2013-02-11 16:26:04.000000000 +0100
-+++ openssl-1.0.1e/apps/req.c 2013-12-22 19:09:34.840366384 +0100
-@@ -655,7 +655,11 @@
- if (newkey <= 0)
+--- openssl-1.0.1e.orig/apps/req.c 2013-12-22 19:47:42.355657810 +0100
++++ openssl-1.0.1e/apps/req.c 2013-12-22 19:57:12.287547599 +0100
+@@ -644,6 +644,11 @@
+ if (inrand)
+ app_RAND_load_files(inrand);
+
++ if (!NCONF_get_number(req_conf,SECTION,BITS, &newkey))
++ {
++ newkey=DEFAULT_KEY_LENGTH;
++ }
++
+ if (keyalg)
{
- if (!NCONF_get_number(req_conf,SECTION,BITS, &newkey))
-+ {
-+ EVP_PKEY_CTX_free(genctx);
-+ genctx = NULL;
- newkey=DEFAULT_KEY_LENGTH;
-+ }
+ genctx = set_keygen_ctx(bio_err, keyalg, &pkey_type, &newkey,
+@@ -652,12 +657,6 @@
+ goto end;
}
-
+
+- if (newkey <= 0)
+- {
+- if (!NCONF_get_number(req_conf,SECTION,BITS, &newkey))
+- newkey=DEFAULT_KEY_LENGTH;
+- }
+-
if (newkey < MIN_KEY_LENGTH && (pkey_type == EVP_PKEY_RSA || pkey_type == EVP_PKEY_DSA))
+ {
+ BIO_printf(bio_err,"private key length is too short,\n");
+@@ -1649,6 +1648,8 @@
+ keylen = atol(p + 1);
+ *pkeylen = keylen;
+ }
++ else
++ keylen = *pkeylen;
+ }
+ else if (p)
+ paramfile = p + 1;
More information about the Pkg-openssl-changes
mailing list