keratin-authn 0.2.0 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/keratin-authn.gemspec +1 -0
- data/lib/keratin/authn/id_token_verifier.rb +1 -1
- data/lib/keratin/authn/issuer.rb +2 -2
- data/lib/keratin/authn/test/helpers.rb +1 -1
- data/lib/keratin/authn/version.rb +1 -1
- metadata +16 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2f45b125d67113d0774cbad89d9267547e3b7e31
|
4
|
+
data.tar.gz: de9f914409394e534f6fe8d9240fe0f4edb0c441
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 164fd93bf93e7ccad0f9d005ea81fcc09e78bdb79bccb8a8b55f4776101631bdbc14d0b2a0d4f9347c0f0e322a1e45fad3c88d3f243b2bb9c561995380b17859
|
7
|
+
data.tar.gz: a45bbfebe1d9bad1c0a5538cc8d679e5a7ee4ec3be78897a2c740c070bfae0ff89efdf8e1518d7b5c786d4940db6589aff7604f1b416474d068922616fbc43e3
|
data/keratin-authn.gemspec
CHANGED
@@ -35,7 +35,7 @@ module Keratin::AuthN
|
|
35
35
|
end
|
36
36
|
|
37
37
|
def token_intact?
|
38
|
-
jwt.verify!(@keychain.getset(jwt
|
38
|
+
jwt.verify!(@keychain.getset(jwt.kid){ Issuer.new(jwt['iss']).signing_key(jwt.kid) })
|
39
39
|
rescue JSON::JWT::VerificationFailed, JSON::JWT::UnexpectedAlgorithm
|
40
40
|
false
|
41
41
|
end
|
data/lib/keratin/authn/issuer.rb
CHANGED
@@ -15,8 +15,8 @@ module Keratin::AuthN
|
|
15
15
|
delete(path: "/accounts/:account_id").result
|
16
16
|
end
|
17
17
|
|
18
|
-
def signing_key
|
19
|
-
keys.find{|k| k['use'] == 'sig' }
|
18
|
+
def signing_key(kid)
|
19
|
+
keys.find{|k| k['use'] == 'sig' && (kid.blank? || kid == k['kid']) }
|
20
20
|
end
|
21
21
|
|
22
22
|
def configuration
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: keratin-authn
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lance Ivy
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-01-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: json-jwt
|
@@ -108,6 +108,20 @@ dependencies:
|
|
108
108
|
- - ">="
|
109
109
|
- !ruby/object:Gem::Version
|
110
110
|
version: '0'
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: byebug
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - ">="
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '0'
|
118
|
+
type: :development
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - ">="
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '0'
|
111
125
|
description:
|
112
126
|
email:
|
113
127
|
- lance@cainlevy.net
|