authrocket 2.4.1 → 3.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +18 -2
- data/README.md +72 -62
- data/app/controllers/auth_rocket/ar_controller.rb +11 -33
- data/app/controllers/logins_controller.rb +1 -8
- data/authrocket.gemspec +4 -3
- data/config/routes.rb +0 -1
- data/lib/authrocket.rb +22 -1
- data/lib/authrocket/api/api_config.rb +17 -18
- data/lib/authrocket/api/client.rb +1 -1
- data/lib/authrocket/api/version.rb +1 -1
- data/lib/authrocket/auth_provider.rb +49 -50
- data/lib/authrocket/client_app.rb +14 -0
- data/lib/authrocket/connection.rb +12 -0
- data/lib/authrocket/credential.rb +12 -6
- data/lib/authrocket/domain.rb +19 -0
- data/lib/authrocket/event.rb +2 -3
- data/lib/authrocket/hook.rb +39 -0
- data/lib/authrocket/invitation.rb +35 -0
- data/lib/authrocket/membership.rb +1 -1
- data/lib/authrocket/named_permission.rb +10 -0
- data/lib/authrocket/notification.rb +1 -1
- data/lib/authrocket/oauth2_session.rb +26 -0
- data/lib/authrocket/org.rb +2 -1
- data/lib/authrocket/rails/controller_helper.rb +73 -21
- data/lib/authrocket/rails/engine.rb +5 -1
- data/lib/authrocket/realm.rb +25 -9
- data/lib/authrocket/resource_link.rb +10 -0
- data/lib/authrocket/session.rb +139 -32
- data/lib/authrocket/token.rb +9 -0
- data/lib/authrocket/user.rb +88 -54
- metadata +33 -19
- data/lib/authrocket/app_hook.rb +0 -28
- data/lib/authrocket/login_policy.rb +0 -14
- data/lib/authrocket/user_token.rb +0 -9
metadata
CHANGED
@@ -1,49 +1,57 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: authrocket
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 3.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- AuthRocket Team
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-02-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
|
-
name:
|
14
|
+
name: addressable
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - "
|
18
|
-
- !ruby/object:Gem::Version
|
19
|
-
version: 2.2.2
|
20
|
-
- - "<"
|
17
|
+
- - "~>"
|
21
18
|
- !ruby/object:Gem::Version
|
22
|
-
version: '
|
19
|
+
version: '2.5'
|
23
20
|
type: :runtime
|
24
21
|
prerelease: false
|
25
22
|
version_requirements: !ruby/object:Gem::Requirement
|
26
23
|
requirements:
|
27
|
-
- - "
|
24
|
+
- - "~>"
|
28
25
|
- !ruby/object:Gem::Version
|
29
|
-
version: 2.
|
30
|
-
|
26
|
+
version: '2.5'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: ncore
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '3.0'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
31
39
|
- !ruby/object:Gem::Version
|
32
|
-
version: '3'
|
40
|
+
version: '3.0'
|
33
41
|
- !ruby/object:Gem::Dependency
|
34
42
|
name: jwt
|
35
43
|
requirement: !ruby/object:Gem::Requirement
|
36
44
|
requirements:
|
37
45
|
- - "~>"
|
38
46
|
- !ruby/object:Gem::Version
|
39
|
-
version: 1
|
47
|
+
version: '2.1'
|
40
48
|
type: :runtime
|
41
49
|
prerelease: false
|
42
50
|
version_requirements: !ruby/object:Gem::Requirement
|
43
51
|
requirements:
|
44
52
|
- - "~>"
|
45
53
|
- !ruby/object:Gem::Version
|
46
|
-
version: 1
|
54
|
+
version: '2.1'
|
47
55
|
- !ruby/object:Gem::Dependency
|
48
56
|
name: bundler
|
49
57
|
requirement: !ruby/object:Gem::Requirement
|
@@ -95,22 +103,28 @@ files:
|
|
95
103
|
- lib/authrocket/api/log_subscriber.rb
|
96
104
|
- lib/authrocket/api/railtie.rb
|
97
105
|
- lib/authrocket/api/version.rb
|
98
|
-
- lib/authrocket/app_hook.rb
|
99
106
|
- lib/authrocket/auth_provider.rb
|
107
|
+
- lib/authrocket/client_app.rb
|
108
|
+
- lib/authrocket/connection.rb
|
100
109
|
- lib/authrocket/credential.rb
|
110
|
+
- lib/authrocket/domain.rb
|
101
111
|
- lib/authrocket/event.rb
|
112
|
+
- lib/authrocket/hook.rb
|
113
|
+
- lib/authrocket/invitation.rb
|
102
114
|
- lib/authrocket/jwt_key.rb
|
103
|
-
- lib/authrocket/login_policy.rb
|
104
115
|
- lib/authrocket/membership.rb
|
116
|
+
- lib/authrocket/named_permission.rb
|
105
117
|
- lib/authrocket/notification.rb
|
118
|
+
- lib/authrocket/oauth2_session.rb
|
106
119
|
- lib/authrocket/org.rb
|
107
120
|
- lib/authrocket/rails.rb
|
108
121
|
- lib/authrocket/rails/controller_helper.rb
|
109
122
|
- lib/authrocket/rails/engine.rb
|
110
123
|
- lib/authrocket/realm.rb
|
124
|
+
- lib/authrocket/resource_link.rb
|
111
125
|
- lib/authrocket/session.rb
|
126
|
+
- lib/authrocket/token.rb
|
112
127
|
- lib/authrocket/user.rb
|
113
|
-
- lib/authrocket/user_token.rb
|
114
128
|
homepage: https://authrocket.com/
|
115
129
|
licenses:
|
116
130
|
- MIT
|
@@ -123,14 +137,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
123
137
|
requirements:
|
124
138
|
- - ">="
|
125
139
|
- !ruby/object:Gem::Version
|
126
|
-
version: '
|
140
|
+
version: '2.3'
|
127
141
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
128
142
|
requirements:
|
129
143
|
- - ">="
|
130
144
|
- !ruby/object:Gem::Version
|
131
145
|
version: '0'
|
132
146
|
requirements: []
|
133
|
-
rubygems_version: 3.0.
|
147
|
+
rubygems_version: 3.0.6
|
134
148
|
signing_key:
|
135
149
|
specification_version: 4
|
136
150
|
summary: AuthRocket client for Ruby
|
data/lib/authrocket/app_hook.rb
DELETED
@@ -1,28 +0,0 @@
|
|
1
|
-
module AuthRocket
|
2
|
-
class AppHook < Resource
|
3
|
-
crud :all, :find, :create, :update, :delete
|
4
|
-
|
5
|
-
belongs_to :realm
|
6
|
-
has_many :events
|
7
|
-
|
8
|
-
attr :event_type, :hook_type, :destination
|
9
|
-
attr :email_from, :email_from_name, :email_renderer, :email_subject
|
10
|
-
attr :email_template, :email_to, :user_type
|
11
|
-
|
12
|
-
def self.event_types
|
13
|
-
%w( app_hook.created app_hook.updated app_hook.deleted
|
14
|
-
auth_provider.created auth_provider.updated auth_provider.deleted
|
15
|
-
login_policy.created login_policy.updated login_policy.deleted
|
16
|
-
membership.created membership.updated membership.deleted
|
17
|
-
org.created org.updated org.deleted
|
18
|
-
realm.created realm.updated realm.deleted
|
19
|
-
user.created user.updated user.deleted
|
20
|
-
user.email.verification_requested user.email.verified
|
21
|
-
user.login.succeeded user.login.failed user.login.initiated
|
22
|
-
user.password_token.created user.password_token.consumed user.password_token.failed
|
23
|
-
).sort
|
24
|
-
end
|
25
|
-
|
26
|
-
|
27
|
-
end
|
28
|
-
end
|
@@ -1,14 +0,0 @@
|
|
1
|
-
module AuthRocket
|
2
|
-
class LoginPolicy < Resource
|
3
|
-
crud :all, :find, :create, :update, :delete
|
4
|
-
|
5
|
-
belongs_to :realm
|
6
|
-
has_many :events
|
7
|
-
|
8
|
-
attr :custom_domains, :external_css
|
9
|
-
attr :footer, :header, :login_handler, :name, :primary_domain
|
10
|
-
attr :redirect_uris, :signup_handler, :subdomain
|
11
|
-
attr :base_domain, :domains # readonly
|
12
|
-
|
13
|
-
end
|
14
|
-
end
|