370f73f
From 8af6b87023cbb1ba6cebea7daaafa275e0dc687e Mon Sep 17 00:00:00 2001
370f73f
From: normal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>
370f73f
Date: Mon, 3 Dec 2018 04:51:13 +0000
370f73f
Subject: [PATCH] drb: fix tests on Debian sid/unstable with OpenSSL 1.1.1a
370f73f
370f73f
OpenSSL complains abour our keys being small and weak :<
370f73f
Make them big and strong with 2048-bit RSA keys and SHA256 digests
370f73f
370f73f
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66153 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
370f73f
---
370f73f
 lib/drb/ssl.rb | 4 ++--
370f73f
 1 file changed, 2 insertions(+), 2 deletions(-)
370f73f
370f73f
diff --git a/lib/drb/ssl.rb b/lib/drb/ssl.rb
370f73f
index 45fe4f1f74..8c2c1cc65d 100644
370f73f
--- a/lib/drb/ssl.rb
370f73f
+++ b/lib/drb/ssl.rb
370f73f
@@ -162,7 +162,7 @@ def setup_certificate
370f73f
           return
370f73f
         end
370f73f
 
370f73f
-        rsa = OpenSSL::PKey::RSA.new(1024){|p, n|
370f73f
+        rsa = OpenSSL::PKey::RSA.new(2048){|p, n|
370f73f
           next unless self[:verbose]
370f73f
           case p
370f73f
           when 0; $stderr.putc "."  # BN_generate_prime
370f73f
@@ -196,7 +196,7 @@ def setup_certificate
370f73f
         if comment = self[:SSLCertComment]
370f73f
           cert.add_extension(ef.create_extension("nsComment", comment))
370f73f
         end
370f73f
-        cert.sign(rsa, OpenSSL::Digest::SHA1.new)
370f73f
+        cert.sign(rsa, OpenSSL::Digest::SHA256.new)
370f73f
 
370f73f
         @cert = cert
370f73f
         @pkey = rsa
370f73f
-- 
370f73f
2.26.2
370f73f