Skip to content
Snippets Groups Projects
Commit eda10ef7 authored by Antonio Terceiro's avatar Antonio Terceiro
Browse files

Add upstream patch to fix openssl version check

Closes: #1005426
parent b3305231
No related branches found
No related tags found
No related merge requests found
From: Joakim Antman <antmanj@gmail.com>
Date: Thu, 18 Nov 2021 07:31:41 +0200
Subject: Fix openssl gem version check to support versons greater than 3
---
lib/jwt/algos/ps.rb | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/lib/jwt/algos/ps.rb b/lib/jwt/algos/ps.rb
index a14f2dd..554aff7 100644
--- a/lib/jwt/algos/ps.rb
+++ b/lib/jwt/algos/ps.rb
@@ -29,9 +29,7 @@ module JWT
def require_openssl!
if Object.const_defined?('OpenSSL')
- major, minor = OpenSSL::VERSION.split('.').first(2)
-
- unless major.to_i >= 2 && minor.to_i >= 1
+ if ::Gem::Version.new(OpenSSL::VERSION) < ::Gem::Version.new('2.1')
raise JWT::RequiredDependencyError, "You currently have OpenSSL #{OpenSSL::VERSION}. PS support requires >= 2.1"
end
else
0001-Fix-openssl-gem-version-check-to-support-versons-gre.patch
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment