Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
# Changelog

## [v3.1.3](https://github.com/jwt/ruby-jwt/tree/v3.1.3) (NEXT)

[Full Changelog](https://github.com/jwt/ruby-jwt/compare/v3.1.2...v3.1.3)

**Features:**

- Your contribution here

**Fixes and enhancements:**

- Fix compatibility with the openssl 4.0 gem [#706](https://github.com/jwt/ruby-jwt/pull/706)
- Your contribution here

## [v3.1.2](https://github.com/jwt/ruby-jwt/tree/v3.1.2) (2025-06-28)

[Full Changelog](https://github.com/jwt/ruby-jwt/compare/v3.1.1...v3.1.2)
Expand Down
2 changes: 1 addition & 1 deletion lib/jwt/jwk/rsa.rb
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ def validate_rsa_parameters!(rsa_parameters)

if ::JWT.openssl_3?
alias create_rsa_key create_rsa_key_using_der
elsif OpenSSL::PKey::RSA.new.respond_to?(:set_key)
elsif OpenSSL::PKey::RSA.method_defined?(:set_key)
alias create_rsa_key create_rsa_key_using_sets
else
alias create_rsa_key create_rsa_key_using_accessors
Expand Down
2 changes: 1 addition & 1 deletion lib/jwt/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def self.gem_version
module VERSION
MAJOR = 3
MINOR = 1
TINY = 2
TINY = 3
PRE = nil

STRING = [MAJOR, MINOR, TINY, PRE].compact.join('.')
Expand Down
4 changes: 2 additions & 2 deletions spec/jwt/jwk/rsa_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@

describe '.create_rsa_key_using_sets' do
before do
skip 'OpenSSL without the RSA#set_key method not supported' unless OpenSSL::PKey::RSA.new.respond_to?(:set_key)
skip 'OpenSSL without the RSA#set_key method not supported' unless OpenSSL::PKey::RSA.method_defined?(:set_key)
skip 'OpenSSL 3.0 does not allow mutating objects anymore' if JWT.openssl_3?
end

Expand All @@ -274,7 +274,7 @@

describe '.create_rsa_key_using_accessors' do
before do
skip 'OpenSSL if RSA#d= is not available there is no accessors anymore' unless OpenSSL::PKey::RSA.new.respond_to?(:d=)
skip 'OpenSSL if RSA#d= is not available there is no accessors anymore' unless OpenSSL::PKey::RSA.method_defined?(:d=)
end

subject(:rsa) { described_class.create_rsa_key_using_accessors(rsa_parameters) }
Expand Down
Loading