Skip to content

Commit 21f5440

Browse files
committed
Check for PS support
1 parent 6ebc30a commit 21f5440

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

.github/workflows/test.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ jobs:
6464
continue-on-error: ${{ matrix.experimental }}
6565
env:
6666
BUNDLE_GEMFILE: ${{ matrix.gemfile }}
67-
6867
steps:
6968
- uses: actions/checkout@v4
7069

gemfiles/openssl.gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22

33
source "https://rubygems.org"
44

5-
gem "openssl", "~> 2.0.0"
5+
gem "openssl", "< 2.1"
66

77
gemspec path: "../"

spec/jwt/jwa/ps_spec.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@
77
let(:ps384_instance) { described_class.new('PS384') }
88
let(:ps512_instance) { described_class.new('PS512') }
99

10+
before do
11+
skip 'OpenSSL gem missing RSA-PSS support' unless OpenSSL::PKey::RSA.new.respond_to?(:sign_pss=)
12+
end
13+
1014
describe '#initialize' do
1115
it 'initializes with the correct algorithm and digest' do
1216
expect(ps256_instance.instance_variable_get(:@alg)).to eq('PS256')

0 commit comments

Comments
 (0)