openid_connect 1.4.0 → 1.4.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b75de8fc4fb255bd3516e8035f72ad3c2f75f95240e6c33d4233991c363b57d5
4
- data.tar.gz: 43264652dba072d41fde285f06cf2f0e5e173d700d8d5c92156273a249623e16
3
+ metadata.gz: fc2fbaf7f12786bfb4695776c65b78a58a7730730382b138a8b53b6149939989
4
+ data.tar.gz: 54d98cef9172883b53426b457ab41cb743d078ae9ed20eb8b374628802cebf1d
5
5
  SHA512:
6
- metadata.gz: 9c3a8b6351419263e11bf7ec1ba4960d2a7675545ddd486411b03d6480e39916e93a35129b668b8123ef662fd53ba6941bcdaa3115bdde36cfa9934080fa91c9
7
- data.tar.gz: 2d3e1bdd2276370bfa60c6a4e5c3f7daf3891cdc60efb7d98130b8686d0d3c4003c6c409cfa59b2b2b7adc57df612958cd8ce36dedfe6cbd3a7b905404a4c500
6
+ metadata.gz: f3bc8fec5821911fbf334a27c9bc2d49dd7871cd5379a9ff91b7a5d1f05b017cece154744b4eb6283b3eea64dbf2cd6cb2fc61fe66a1f75c4dbf21aa97180646
7
+ data.tar.gz: '09845c6ec9f7d8a198333d49eab6511f25fccd7d31a6ea7f59456700f44eab420ae4dbe2d96d28e541f7cd7b5f9bf0c5976ee19a85b7397904c3debd45db01e9'
@@ -2,6 +2,8 @@ name: Spec
2
2
 
3
3
  on:
4
4
  push:
5
+ branches:
6
+ - master
5
7
  pull_request:
6
8
 
7
9
  permissions:
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.4.0
1
+ 1.4.2
@@ -18,9 +18,9 @@ Gem::Specification.new do |s|
18
18
  s.add_runtime_dependency "validate_url"
19
19
  s.add_runtime_dependency "validate_email"
20
20
  s.add_runtime_dependency "json-jwt", ">= 1.15.0"
21
- s.add_runtime_dependency "swd", ">= 1.0.0"
22
- s.add_runtime_dependency "webfinger", ">= 1.0.1"
23
- s.add_runtime_dependency "rack-oauth2", ">= 1.6.1"
21
+ s.add_runtime_dependency "swd", "~> 1.3"
22
+ s.add_runtime_dependency "webfinger", "~> 1.2"
23
+ s.add_runtime_dependency "rack-oauth2", "~> 1.21"
24
24
  if Gem.ruby_version >= Gem::Version.create(3.1)
25
25
  # TODO:
26
26
  # remove "net-smtp" dependency after mail gem 2.8+ (which supports ruby 3.1+) released.
@@ -257,11 +257,6 @@ describe OpenIDConnect::ResponseObject::IdToken do
257
257
  jwk_str = File.read(File.join(__dir__, '../../mock_response/public_keys/jwks_with_private_key.json'))
258
258
  jwk = JSON::JWK::Set.new JSON.parse(jwk_str)
259
259
  end
260
- let(:private_key) do
261
- OpenSSL::PKey::RSA.new(
262
- File.read(File.join(__dir__, '../../mock_response/public_keys/private_key.pem'))
263
- ).to_jwk
264
- end
265
260
  let(:idp_config) do
266
261
  OpenIDConnect::Discovery::Provider::Config::Response.new(
267
262
  issuer: attributes[:issuer],
@@ -273,9 +268,33 @@ describe OpenIDConnect::ResponseObject::IdToken do
273
268
  )
274
269
  end
275
270
 
276
- it do
277
- mock_json :get, idp_config.jwks_uri, 'public_keys/jwks_with_private_key' do
278
- should
271
+ context 'when id_token has kid' do
272
+ let(:private_key) do
273
+ OpenSSL::PKey::RSA.new(
274
+ File.read(File.join(__dir__, '../../mock_response/public_keys/private_key.pem'))
275
+ ).to_jwk
276
+ end
277
+
278
+ it do
279
+ mock_json :get, idp_config.jwks_uri, 'public_keys/jwks_with_private_key' do
280
+ should be_a klass
281
+ end
282
+ end
283
+ end
284
+
285
+ context 'otherwise' do
286
+ let(:private_key) do
287
+ OpenSSL::PKey::RSA.new(
288
+ File.read(File.join(__dir__, '../../mock_response/public_keys/private_key.pem'))
289
+ )
290
+ end
291
+
292
+ it do
293
+ mock_json :get, idp_config.jwks_uri, 'public_keys/jwks_with_private_key' do
294
+ expect do
295
+ should
296
+ end.to raise_error JSON::JWK::Set::KidNotFound
297
+ end
279
298
  end
280
299
  end
281
300
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: openid_connect
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.0
4
+ version: 1.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - nov matake
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-09-23 00:00:00.000000000 Z
11
+ date: 2022-10-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: tzinfo
@@ -98,44 +98,58 @@ dependencies:
98
98
  name: swd
99
99
  requirement: !ruby/object:Gem::Requirement
100
100
  requirements:
101
- - - ">="
101
+ - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: 1.0.0
103
+ version: '1.3'
104
104
  type: :runtime
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
- - - ">="
108
+ - - "~>"
109
109
  - !ruby/object:Gem::Version
110
- version: 1.0.0
110
+ version: '1.3'
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: webfinger
113
113
  requirement: !ruby/object:Gem::Requirement
114
114
  requirements:
115
- - - ">="
115
+ - - "~>"
116
116
  - !ruby/object:Gem::Version
117
- version: 1.0.1
117
+ version: '1.2'
118
118
  type: :runtime
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
- - - ">="
122
+ - - "~>"
123
123
  - !ruby/object:Gem::Version
124
- version: 1.0.1
124
+ version: '1.2'
125
125
  - !ruby/object:Gem::Dependency
126
126
  name: rack-oauth2
127
+ requirement: !ruby/object:Gem::Requirement
128
+ requirements:
129
+ - - "~>"
130
+ - !ruby/object:Gem::Version
131
+ version: '1.21'
132
+ type: :runtime
133
+ prerelease: false
134
+ version_requirements: !ruby/object:Gem::Requirement
135
+ requirements:
136
+ - - "~>"
137
+ - !ruby/object:Gem::Version
138
+ version: '1.21'
139
+ - !ruby/object:Gem::Dependency
140
+ name: net-smtp
127
141
  requirement: !ruby/object:Gem::Requirement
128
142
  requirements:
129
143
  - - ">="
130
144
  - !ruby/object:Gem::Version
131
- version: 1.6.1
145
+ version: '0'
132
146
  type: :runtime
133
147
  prerelease: false
134
148
  version_requirements: !ruby/object:Gem::Requirement
135
149
  requirements:
136
150
  - - ">="
137
151
  - !ruby/object:Gem::Version
138
- version: 1.6.1
152
+ version: '0'
139
153
  - !ruby/object:Gem::Dependency
140
154
  name: rake
141
155
  requirement: !ruby/object:Gem::Requirement
@@ -336,7 +350,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
336
350
  - !ruby/object:Gem::Version
337
351
  version: '0'
338
352
  requirements: []
339
- rubygems_version: 3.2.22
353
+ rubygems_version: 3.3.7
340
354
  signing_key:
341
355
  specification_version: 4
342
356
  summary: OpenID Connect Server & Client Library