authrocket 2.1.0 → 2.1.1

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
  SHA1:
3
- metadata.gz: 37f37dc00fd966b7ee4a814d96dd74887ad28766
4
- data.tar.gz: d1c970139d94933366d970465d55945192645dc0
3
+ metadata.gz: 25c9714d9a8a39ba10d25bce51b378d643bb2a86
4
+ data.tar.gz: f6590ea8aed5079f41ddfe62d17c0095188efffb
5
5
  SHA512:
6
- metadata.gz: 40969c9aba8cb99c074179f23fb14cb57f7594acecb9e25e6e45511a4c5d4c916f3d92e82571ee9181ffcb00816d54b201ccb1114c7ef8e14b36d0bf47765c9f
7
- data.tar.gz: b39524bbbfb598427910fd665598e77d1b0307465c90b5d0cebb67b876380fc4505e6fd8dea4c6f80df381edb75e76bc179b73eb3f38b2a1bb7e4712467c1b0a
6
+ metadata.gz: ca3ea43ae527d665af2ffd02ade85e8dac33d895a9d879fa425f13a6b6d0399819c06ea99368189601d7fd80155393d32ddf730788142be2d1b3ab6afe6a4783
7
+ data.tar.gz: 00183ddbe8d5b9d65da316118da31618dfa57892aa993ba7930470495d08a4d03d66a4b5219bc2807068667072ab67940c9bee667e90a3a6ac591ad0b818a1ba
@@ -1,3 +1,8 @@
1
+ #### 2.1.1
2
+ - Add Realm#jwt_fields
3
+ - Deprecate Realm#jwt_data - replaced by #jwt_fields
4
+ - Parse custom attributes from JWT when available
5
+
1
6
  #### 2.1.0
2
7
  - AuthProvider.authorize, #authorize_token can now return a UserToken
3
8
  - Add UserToken#credential_type
@@ -1,3 +1,3 @@
1
1
  module AuthRocket
2
- VERSION = '2.1.0'
2
+ VERSION = '2.1.1'
3
3
  end
@@ -10,9 +10,10 @@ module AuthRocket
10
10
  has_many :users
11
11
 
12
12
  attr :api_key_minutes, :api_key_policy, :api_key_prefix, :custom, :name
13
- attr :jwt_data, :require_unique_emails, :resource_links, :session_minutes
13
+ attr :jwt_fields, :require_unique_emails, :resource_links, :session_minutes
14
14
  attr :session_type, :state, :username_validation_human
15
15
  attr :jwt_secret # readonly
16
+ attr :jwt_data # deprecated
16
17
 
17
18
 
18
19
  def reset!(params={})
@@ -31,15 +31,18 @@ module AuthRocket
31
31
  first_name: jwt['fn'],
32
32
  last_name: jwt['ln'],
33
33
  name: jwt['n'],
34
+ custom: jwt['cs'],
34
35
  memberships: jwt['m'] && jwt['m'].map do |m|
35
36
  Membership.new({
36
37
  permissions: m['p'],
38
+ custom: m['cs'],
37
39
  user_id: jwt['uid'],
38
40
  org_id: m['oid'],
39
- org: m['oid'] && Org.new({
41
+ org: m['o'] && Org.new({
40
42
  id: m['oid'],
41
43
  realm_id: jwt['aud'],
42
44
  name: m['o'],
45
+ custom: m['ocs'],
43
46
  }),
44
47
  })
45
48
  end,
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: authrocket
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - AuthRocket Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-01-04 00:00:00.000000000 Z
11
+ date: 2017-01-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ncore