omniauth-apple 1.2.1 → 1.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/omniauth/apple/version.rb +1 -1
- data/lib/omniauth/strategies/apple.rb +9 -3
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 81a5350ae8be48914ee324f8586b5d58f83927467bc87106cab846e028e38beb
|
4
|
+
data.tar.gz: 42db86865c9120c95e7326359e3ac02dd58dbd28bfe84c7fc0bbb002488b0a1b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 18a1bf098d7687ed17df039b9b2f4b0a388f0d6858a4a54aa8c94a7233622f7cb1d4485a38d870ae430f873aadaaee8d9d1b42c9f8a91545c0bdb10c4cffbe11
|
7
|
+
data.tar.gz: f53179d2a247e0fd2559614fece6b3b734579d756be44c1b4c40ab9c6911479e38dc7f74800dcc59b36b09749656bb93aff6c8eeccc422238e95667049064b63
|
@@ -6,6 +6,12 @@ require 'net/https'
|
|
6
6
|
module OmniAuth
|
7
7
|
module Strategies
|
8
8
|
class Apple < OmniAuth::Strategies::OAuth2
|
9
|
+
class JWTFetchingFailed < CallbackError
|
10
|
+
def initialize(error_reason = nil, error_uri = nil)
|
11
|
+
super :jwks_fetching_failed, error_reason, error_uri
|
12
|
+
end
|
13
|
+
end
|
14
|
+
|
9
15
|
option :name, 'apple'
|
10
16
|
|
11
17
|
option :client_options,
|
@@ -102,10 +108,10 @@ module OmniAuth
|
|
102
108
|
if res.success?
|
103
109
|
res.body
|
104
110
|
else
|
105
|
-
|
111
|
+
raise JWTFetchingFailed.new('HTTP Error when fetching JWKs')
|
106
112
|
end
|
107
|
-
rescue Faraday::Error => e
|
108
|
-
fail!(:jwks_fetching_failed, e)
|
113
|
+
rescue JWTFetchingFailed, Faraday::Error => e
|
114
|
+
fail!(:jwks_fetching_failed, e) and nil
|
109
115
|
end
|
110
116
|
|
111
117
|
def verify_nonce!(payload)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: omniauth-apple
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- nhosoya
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2022-10-
|
12
|
+
date: 2022-10-31 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: omniauth-oauth2
|