From 5bab1304af25a843728dbcd2f3594913740aecb0 Mon Sep 17 00:00:00 2001 From: "Urabe, Shyouhei" Date: Tue, 14 May 2019 11:44:20 +0900 Subject: fix visibility of SecureRandom.gen_random Aliasing a method preserves its visibility. These aliases turn formerly-public methods into private. Should make them public again. [Bug #15847] --- lib/securerandom.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib/securerandom.rb') diff --git a/lib/securerandom.rb b/lib/securerandom.rb index 37835bf7df..205cb70be5 100644 --- a/lib/securerandom.rb +++ b/lib/securerandom.rb @@ -85,6 +85,7 @@ module SecureRandom class << self remove_method :gen_random alias gen_random gen_random_openssl + public :gen_random end end return gen_random(n) @@ -94,6 +95,7 @@ module SecureRandom class << self remove_method :gen_random alias gen_random gen_random_urandom + public :gen_random end end return gen_random(n) -- cgit v1.2.3