authorized_persona 0.1.0 → 0.9.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
  SHA256:
3
- metadata.gz: 4c94ee11ec5cc61e600479f513dbd1977768ff146b61ec18ae34f34aeaa2e223
4
- data.tar.gz: 687dde9d36b005ab6a8b8d08e6b40ea7349819d765fb93c1cd4c06fb568dfc5d
3
+ metadata.gz: 83c7b75e101248119260f84dc0cfabd9dc6db7a079cacf89de689d7863e12028
4
+ data.tar.gz: 9d1e4c231c66e743650ae5566192a5a5aa640974d616c3f508b0f08a981ed592
5
5
  SHA512:
6
- metadata.gz: 7d146c61b9932e9eea82aea03ac7f48798ce42c47bf3eb8eb9cffc403631db58e56559a1098c7b9a640e4598858552a37ca75e6749c564882f248188c8bcd00c
7
- data.tar.gz: e371dc3c7752412945d46cb76716d8973ad6d1cdc3149d49bf31dde852b5b12c37e10b3d05490f0b4711694bdb0d1108ea683e28bef6d6ecd9dd322919095db6
6
+ metadata.gz: db6b39f1ca8cadb3e9180e17bf36eb33467c5d929144444ac9d17d2e949d13697c36a21241f4e168367c0013569699299e6322b2e85d1548ef2360c9377ff890
7
+ data.tar.gz: 6300f79ee516294b170acd149d555b80c23033a29513d667511ef447e8025abccff942faf9ab55823dedc3d871daa17326c691ef4ef969d544c2958451bd5794
@@ -0,0 +1,27 @@
1
+ name: CI
2
+
3
+ on: [push, pull_request]
4
+
5
+ jobs:
6
+ test:
7
+ runs-on: ubuntu-latest
8
+ strategy:
9
+ fail-fast: false
10
+ matrix:
11
+ ruby: ['2.7', '3.0']
12
+ gemfile:
13
+ - gemfiles/rails_6_0.gemfile
14
+ - gemfiles/rails_6_1.gemfile
15
+ - gemfiles/rails_7_0.gemfile
16
+ steps:
17
+ - uses: actions/checkout@v2
18
+ - uses: ruby/setup-ruby@v1
19
+ env:
20
+ BUNDLE_GEMFILE: ${{ matrix.gemfile }}
21
+ with:
22
+ ruby-version: ${{ matrix.ruby }}
23
+ bundler-cache: true # runs 'bundle install' and caches installed gems automatically
24
+ - name: Run tests and linter
25
+ env:
26
+ BUNDLE_GEMFILE: ${{ matrix.gemfile }}
27
+ run: bundle exec rake
data/.gitignore CHANGED
@@ -9,3 +9,6 @@
9
9
 
10
10
  # rspec failure tracking
11
11
  .rspec_status
12
+
13
+ /Gemfile.lock
14
+ *.gemfile.lock
data/.rubocop.yml CHANGED
@@ -1,3 +1,5 @@
1
+ inherit_from: .rubocop_todo.yml
2
+
1
3
  inherit_gem:
2
- rubocop-betterment:
4
+ betterlint:
3
5
  - config/default.yml
data/.rubocop_todo.yml ADDED
@@ -0,0 +1,100 @@
1
+ # This configuration was generated by
2
+ # `rubocop --auto-gen-config --auto-gen-only-exclude --exclude-limit 99999`
3
+ # on 2023-05-09 13:01:46 UTC using RuboCop version 1.50.2.
4
+ # The point is for the user to remove these configuration records
5
+ # one by one as the offenses are removed from the code base.
6
+ # Note that changes in the inspected code, or installation of new
7
+ # versions of RuboCop, may require this file to be generated again.
8
+
9
+ # Offense count: 4
10
+ # Configuration parameters: EnforcedStyle, AllowedGems, Include.
11
+ # SupportedStyles: Gemfile, gems.rb, gemspec
12
+ # Include: **/*.gemspec, **/Gemfile, **/gems.rb
13
+ Gemspec/DevelopmentDependencies:
14
+ Exclude:
15
+ - 'authorized_persona.gemspec'
16
+
17
+ # Offense count: 1
18
+ # Configuration parameters: Severity, Include.
19
+ # Include: **/*.gemspec
20
+ Gemspec/RequiredRubyVersion:
21
+ Exclude:
22
+ - 'authorized_persona.gemspec'
23
+
24
+ # Offense count: 1
25
+ # This cop supports safe autocorrection (--autocorrect).
26
+ # Configuration parameters: Max, AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, AllowedPatterns.
27
+ # URISchemes: http, https
28
+ Layout/LineLength:
29
+ Exclude:
30
+ - 'lib/authorized_persona/authorization.rb'
31
+
32
+ # Offense count: 2
33
+ Lint/MissingSuper:
34
+ Exclude:
35
+ - 'spec/authorized_persona/authorization_spec.rb'
36
+ - 'spec/authorized_persona/persona_spec.rb'
37
+
38
+ # Offense count: 2
39
+ # This cop supports safe autocorrection (--autocorrect).
40
+ Lint/RedundantCopDisableDirective:
41
+ Exclude:
42
+ - 'lib/authorized_persona/authorization.rb'
43
+
44
+ # Offense count: 1
45
+ # Configuration parameters: AllowedMethods, AllowedPatterns, Max.
46
+ Metrics/PerceivedComplexity:
47
+ Exclude:
48
+ - 'lib/authorized_persona/persona.rb'
49
+
50
+ # Offense count: 2
51
+ # This cop supports unsafe autocorrection (--autocorrect-all).
52
+ RSpec/BeEq:
53
+ Exclude:
54
+ - 'spec/authorized_persona/authorization_spec.rb'
55
+
56
+ # Offense count: 1
57
+ # This cop supports unsafe autocorrection (--autocorrect-all).
58
+ Rails/ActiveSupportOnLoad:
59
+ Exclude:
60
+ - 'lib/authorized_persona/railtie.rb'
61
+
62
+ # Offense count: 1
63
+ Rails/I18nLocaleTexts:
64
+ Exclude:
65
+ - 'lib/authorized_persona/authorization.rb'
66
+
67
+ # Offense count: 1
68
+ # This cop supports unsafe autocorrection (--autocorrect-all).
69
+ # Configuration parameters: Include.
70
+ # Include: **/Rakefile, **/*.rake
71
+ Rails/RakeEnvironment:
72
+ Exclude:
73
+ - 'Rakefile'
74
+
75
+ # Offense count: 1
76
+ # This cop supports safe autocorrection (--autocorrect).
77
+ Rake/Desc:
78
+ Exclude:
79
+ - 'Rakefile'
80
+
81
+ # Offense count: 2
82
+ # This cop supports unsafe autocorrection (--autocorrect-all).
83
+ # Configuration parameters: AllowedReceivers.
84
+ # AllowedReceivers: Thread.current
85
+ Style/HashEachMethods:
86
+ Exclude:
87
+ - 'lib/authorized_persona/persona.rb'
88
+
89
+ # Offense count: 1
90
+ # This cop supports unsafe autocorrection (--autocorrect-all).
91
+ Style/MapToHash:
92
+ Exclude:
93
+ - 'lib/authorized_persona/authorization.rb'
94
+
95
+ # Offense count: 1
96
+ # This cop supports unsafe autocorrection (--autocorrect-all).
97
+ # Configuration parameters: Mode.
98
+ Style/StringConcatenation:
99
+ Exclude:
100
+ - 'lib/authorized_persona/view_helpers.rb'
data/.ruby-version ADDED
@@ -0,0 +1 @@
1
+ 3.0.6
data/Appraisals ADDED
@@ -0,0 +1,14 @@
1
+ appraise 'rails-6-0' do
2
+ gem 'railties', '~> 6.0.0'
3
+ gem 'activemodel', '~>6.0.0'
4
+ end
5
+
6
+ appraise 'rails-6-1' do
7
+ gem 'railties', '~> 6.1.0'
8
+ gem 'activemodel', '~>6.1.0'
9
+ end
10
+
11
+ appraise 'rails-7-0' do
12
+ gem 'railties', '~> 7.0.0'
13
+ gem 'activemodel', '~>7.0.0'
14
+ end
data/README.md CHANGED
@@ -34,7 +34,7 @@ your data model and trust root chaining. But even when more access
34
34
  control logic is required, you will develop simpler, better-fit
35
35
  solutions within your application.
36
36
 
37
- Which lead us to the following conclusions:
37
+ Which led us to the following conclusions:
38
38
 
39
39
  * Applications should be built for a single persona each.
40
40
  * In Rails applications, authorization should be granted and enforced
@@ -73,7 +73,7 @@ We'll assume you're using an authentication library like `devise` or
73
73
 
74
74
  1. Integrate AuthorizedPersona into your user model.
75
75
 
76
- The example uses ActiveRecord, but any ActiveModel-based ORM will do.
76
+ The example uses ActiveRecord, but any ActiveModel-like ORM will do.
77
77
  Your model only needs to have a string attribute named
78
78
  `authorization_tier`.
79
79
 
@@ -107,18 +107,24 @@ end
107
107
  class ApplicationController < ActionController::Base
108
108
  include AuthorizedPersona::Authorization
109
109
 
110
+ # Any hooks your authentication library needs to ensure
111
+ # `current_user` is set before # authorization, e.g.:
112
+ #
113
+ # before_action :authenticate_user!
114
+
110
115
  authorize_persona class_name: "User"
111
116
 
112
117
  # or optionally override the method name we use to fetch current_[class_name] e.g.:
113
118
  #
114
- # authorize_persona class_name: "User", current_user_method_name: :current_fancy_user
119
+ # authorize_persona class_name: "User", current_user_method: :current_fancy_user
115
120
 
116
121
  # Your code here...
117
122
  end
118
123
  ```
119
124
 
120
125
  At this point, no user is authorized to make a request to any descendent
121
- of `ApplicationController`.
126
+ of `ApplicationController`. Note that any unauthenticated controllers (e.g. authentication
127
+ controllers) will need to have authorization disabled via `skip_before_action :authorize!`.
122
128
 
123
129
  3. Grant privileges in your base controller or any subclass:
124
130
 
@@ -187,6 +193,24 @@ class BillSearch
187
193
  end
188
194
  ```
189
195
 
196
+ 6. (Advanced) If you need to determine which users are at or above an
197
+ authorization tier, e.g. for fanning out notifications:
198
+
199
+ ```ruby
200
+ # app/jobs/sensitive_bill_notification_job.rb
201
+ class SensitiveBillNotificationJob < ApplicationJob
202
+
203
+ def perform(bill_id)
204
+ bill = Bill.find(bill_id)
205
+ # AuthorizedPersona::Persona provides a `.[tier]_or_above` scope if
206
+ # your ORM supports a `.where` method
207
+ User.admin_or_above.find_each do |admin|
208
+ AdminMailer.with(user: admin, bill: bill).sensitive_bill_notification.deliver_later
209
+ end
210
+ end
211
+ end
212
+ ```
213
+
190
214
  ## Development
191
215
 
192
216
  After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
@@ -22,13 +22,15 @@ Gem::Specification.new do |spec|
22
22
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
23
23
  spec.require_paths = ["lib"]
24
24
 
25
- rails_version_range = [">= 5.1.6.2", "< 7"]
25
+ rails_version_range = [">= 5.1.6.2", "< 7.1"]
26
26
 
27
- spec.add_dependency "activemodel", *rails_version_range
28
- spec.add_dependency "railties", *rails_version_range
27
+ spec.add_dependency "railties", *rails_version_range
29
28
 
30
- spec.add_development_dependency "bundler", "~> 2.0"
31
- spec.add_development_dependency "rake", "~> 10.0"
29
+ spec.add_development_dependency "activemodel", *rails_version_range
30
+ spec.add_development_dependency "appraisal"
31
+ spec.add_development_dependency "betterlint"
32
+ spec.add_development_dependency "bundler"
33
+ spec.add_development_dependency "rake"
32
34
  spec.add_development_dependency "rspec", "~> 3.0"
33
- spec.add_development_dependency "rubocop-betterment"
35
+ spec.metadata['rubygems_mfa_required'] = 'true'
34
36
  end
@@ -0,0 +1,8 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "activemodel", "~>6.0.0"
6
+ gem "railties", "~> 6.0.0"
7
+
8
+ gemspec path: "../"
@@ -0,0 +1,8 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "activemodel", "~>6.1.0"
6
+ gem "railties", "~> 6.1.0"
7
+
8
+ gemspec path: "../"
@@ -0,0 +1,8 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "activemodel", "~>7.0.0"
6
+ gem "railties", "~> 7.0.0"
7
+
8
+ gemspec path: "../"
@@ -9,13 +9,11 @@ module AuthorizedPersona
9
9
  self.authorized_actions = {}
10
10
 
11
11
  helper_method :authorization_current_user
12
-
13
- before_action :authorize!
14
12
  end
15
13
 
16
14
  class_methods do
17
15
  # Configure authorization for an authorized persona class
18
- def authorize_persona(class_name:, current_user_method: nil) # rubocop:disable Metrics/AbcSize
16
+ def authorize_persona(class_name:, current_user_method: nil) # rubocop:disable Metrics/AbcSize, Metrics/PerceivedComplexity, Metrics/
19
17
  raise AuthorizedPersona::Error, "you can only configure authorization once" if authorization_persona_class_name.present?
20
18
  raise AuthorizedPersona::Error, "class_name must be a string" unless class_name.is_a?(String)
21
19
  raise AuthorizedPersona::Error, "current_user_method must be a symbol" if current_user_method && !current_user_method.is_a?(Symbol)
@@ -26,18 +24,25 @@ module AuthorizedPersona
26
24
  raise AuthorizedPersona::Error, "#{class_name} must be an AuthorizedPersona::Persona"
27
25
  end
28
26
 
29
- self.authorization_current_user_method = current_user_method || :"current_#{authorization_persona.model_name.singular_route_key}"
27
+ model_name = if authorization_persona.respond_to?(:model_name)
28
+ authorization_persona.model_name.singular_route_key
29
+ else
30
+ authorization_persona.name.underscore
31
+ end
32
+ self.authorization_current_user_method = current_user_method || :"current_#{model_name}"
33
+
34
+ before_action :authorize!
30
35
  end
31
36
 
32
37
  # Grants replace all previous grants to avoid privilege leakage
33
38
  def grant(privileges) # rubocop:disable Metrics/AbcSize
34
- self.authorized_actions = Hash[privileges.map { |auth_tier, actions| [auth_tier.to_s, [actions].flatten.map(&:to_sym)] }]
39
+ self.authorized_actions = privileges.map { |auth_tier, actions| [auth_tier.to_s, [actions].flatten.map(&:to_sym)] }.to_h
35
40
 
36
41
  tier_names = authorization_persona.authorization_tier_names
37
42
  extra_keys = authorized_actions.keys - authorization_persona.authorization_tier_names
38
43
  if extra_keys.present?
39
44
  raise AuthorizedPersona::Error, "invalid grant: #{authorization_persona_class_name} " \
40
- "has authorization tiers #{tier_names.join(', ')} but received extra keys: #{extra_keys.join(', ')}"
45
+ "has authorization tiers #{tier_names.join(', ')} but received extra keys: #{extra_keys.join(', ')}"
41
46
  end
42
47
  end
43
48
 
@@ -74,7 +79,7 @@ module AuthorizedPersona
74
79
  def authorization_current_user
75
80
  unless authorization_current_user_method.is_a?(Symbol)
76
81
  raise AuthorizedPersona::Error, "you must configure authorization with a valid current_user method name, " \
77
- "e.g. `authorize_persona class_name: 'User', current_user_method: :my_custom_current_user`"
82
+ "e.g. `authorize_persona class_name: 'User', current_user_method: :my_custom_current_user`"
78
83
  end
79
84
 
80
85
  send(self.class.authorization_current_user_method)
@@ -84,7 +89,7 @@ module AuthorizedPersona
84
89
  self.class.authorized_tier(action: params[:action])
85
90
  end
86
91
 
87
- def authorize! # rubocop:disable Metrics/MethodLength
92
+ def authorize!
88
93
  return if authorized?
89
94
 
90
95
  respond_to do |format|
@@ -2,6 +2,14 @@ module AuthorizedPersona
2
2
  module Persona
3
3
  extend ActiveSupport::Concern
4
4
 
5
+ included do
6
+ if respond_to?(:where)
7
+ def self.with_authorization_tier_at_or_above(tier)
8
+ where(authorization_tier_attribute_name => authorization_tier_names.drop(authorization_tier_level(tier)))
9
+ end
10
+ end
11
+ end
12
+
5
13
  class_methods do
6
14
  # Get the attribute name for authorization_tier
7
15
  def authorization_tier_attribute_name
@@ -26,7 +34,7 @@ module AuthorizedPersona
26
34
  end
27
35
 
28
36
  # Configure the authorization tiers in my_tier_slug: "My Tier Title And Description" form from lowest to highest privilege.
29
- def authorization_tiers(tiers) # rubocop:disable Metrics/AbcSize, Metrics/MethodLength
37
+ def authorization_tiers(tiers) # rubocop:disable Metrics/AbcSize
30
38
  raise AuthorizedPersona::Error, "you can only define authorization tiers once" if instance_variable_defined?(:@authorization_tiers)
31
39
 
32
40
  if !tiers.is_a?(Hash) || !tiers.all? { |k, v| k.is_a?(Symbol) && v.is_a?(String) }
@@ -45,6 +53,19 @@ module AuthorizedPersona
45
53
  end
46
54
  end
47
55
 
56
+ if respond_to?(:with_authorization_tier_at_or_above)
57
+ class_methods = Module.new
58
+ extend class_methods
59
+
60
+ class_methods.module_eval do
61
+ tiers.keys.each do |tier|
62
+ define_method "#{tier}_or_above" do
63
+ with_authorization_tier_at_or_above(tier)
64
+ end
65
+ end
66
+ end
67
+ end
68
+
48
69
  @authorization_tiers = tiers.freeze
49
70
  end
50
71
 
@@ -1,7 +1,7 @@
1
1
  module AuthorizedPersona
2
2
  class Railtie < Rails::Railtie
3
3
  initializer "authorized_persona.view_helpers" do
4
- ActionView::Base.send :include, AuthorizedPersona::ViewHelpers
4
+ ActionView::Base.include AuthorizedPersona::ViewHelpers
5
5
  end
6
6
  end
7
7
  end
@@ -1,3 +1,3 @@
1
1
  module AuthorizedPersona
2
- VERSION = "0.1.0".freeze
2
+ VERSION = "0.9.1".freeze
3
3
  end
@@ -1,7 +1,6 @@
1
1
  require "authorized_persona/version"
2
2
 
3
3
  require "rails"
4
- require "active_model"
5
4
 
6
5
  require "authorized_persona/persona"
7
6
  require "authorized_persona/authorization"
metadata CHANGED
@@ -1,17 +1,17 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: authorized_persona
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.9.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - John Mileham
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-06-07 00:00:00.000000000 Z
11
+ date: 2023-05-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: activemodel
14
+ name: railties
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - ">="
@@ -19,7 +19,7 @@ dependencies:
19
19
  version: 5.1.6.2
20
20
  - - "<"
21
21
  - !ruby/object:Gem::Version
22
- version: '7'
22
+ version: '7.1'
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
@@ -29,9 +29,9 @@ dependencies:
29
29
  version: 5.1.6.2
30
30
  - - "<"
31
31
  - !ruby/object:Gem::Version
32
- version: '7'
32
+ version: '7.1'
33
33
  - !ruby/object:Gem::Dependency
34
- name: railties
34
+ name: activemodel
35
35
  requirement: !ruby/object:Gem::Requirement
36
36
  requirements:
37
37
  - - ">="
@@ -39,8 +39,8 @@ dependencies:
39
39
  version: 5.1.6.2
40
40
  - - "<"
41
41
  - !ruby/object:Gem::Version
42
- version: '7'
43
- type: :runtime
42
+ version: '7.1'
43
+ type: :development
44
44
  prerelease: false
45
45
  version_requirements: !ruby/object:Gem::Requirement
46
46
  requirements:
@@ -49,51 +49,51 @@ dependencies:
49
49
  version: 5.1.6.2
50
50
  - - "<"
51
51
  - !ruby/object:Gem::Version
52
- version: '7'
52
+ version: '7.1'
53
53
  - !ruby/object:Gem::Dependency
54
- name: bundler
54
+ name: appraisal
55
55
  requirement: !ruby/object:Gem::Requirement
56
56
  requirements:
57
- - - "~>"
57
+ - - ">="
58
58
  - !ruby/object:Gem::Version
59
- version: '2.0'
59
+ version: '0'
60
60
  type: :development
61
61
  prerelease: false
62
62
  version_requirements: !ruby/object:Gem::Requirement
63
63
  requirements:
64
- - - "~>"
64
+ - - ">="
65
65
  - !ruby/object:Gem::Version
66
- version: '2.0'
66
+ version: '0'
67
67
  - !ruby/object:Gem::Dependency
68
- name: rake
68
+ name: betterlint
69
69
  requirement: !ruby/object:Gem::Requirement
70
70
  requirements:
71
- - - "~>"
71
+ - - ">="
72
72
  - !ruby/object:Gem::Version
73
- version: '10.0'
73
+ version: '0'
74
74
  type: :development
75
75
  prerelease: false
76
76
  version_requirements: !ruby/object:Gem::Requirement
77
77
  requirements:
78
- - - "~>"
78
+ - - ">="
79
79
  - !ruby/object:Gem::Version
80
- version: '10.0'
80
+ version: '0'
81
81
  - !ruby/object:Gem::Dependency
82
- name: rspec
82
+ name: bundler
83
83
  requirement: !ruby/object:Gem::Requirement
84
84
  requirements:
85
- - - "~>"
85
+ - - ">="
86
86
  - !ruby/object:Gem::Version
87
- version: '3.0'
87
+ version: '0'
88
88
  type: :development
89
89
  prerelease: false
90
90
  version_requirements: !ruby/object:Gem::Requirement
91
91
  requirements:
92
- - - "~>"
92
+ - - ">="
93
93
  - !ruby/object:Gem::Version
94
- version: '3.0'
94
+ version: '0'
95
95
  - !ruby/object:Gem::Dependency
96
- name: rubocop-betterment
96
+ name: rake
97
97
  requirement: !ruby/object:Gem::Requirement
98
98
  requirements:
99
99
  - - ">="
@@ -106,6 +106,20 @@ dependencies:
106
106
  - - ">="
107
107
  - !ruby/object:Gem::Version
108
108
  version: '0'
109
+ - !ruby/object:Gem::Dependency
110
+ name: rspec
111
+ requirement: !ruby/object:Gem::Requirement
112
+ requirements:
113
+ - - "~>"
114
+ - !ruby/object:Gem::Version
115
+ version: '3.0'
116
+ type: :development
117
+ prerelease: false
118
+ version_requirements: !ruby/object:Gem::Requirement
119
+ requirements:
120
+ - - "~>"
121
+ - !ruby/object:Gem::Version
122
+ version: '3.0'
109
123
  description: AuthorizedPersona is a rails implementation of Betterment's Persona Centric
110
124
  Authorization pattern
111
125
  email:
@@ -114,19 +128,24 @@ executables: []
114
128
  extensions: []
115
129
  extra_rdoc_files: []
116
130
  files:
131
+ - ".github/workflows/ci.yml"
117
132
  - ".gitignore"
118
133
  - ".rspec"
119
134
  - ".rubocop.yml"
120
- - ".travis.yml"
135
+ - ".rubocop_todo.yml"
136
+ - ".ruby-version"
137
+ - Appraisals
121
138
  - CODE_OF_CONDUCT.md
122
139
  - Gemfile
123
- - Gemfile.lock
124
140
  - LICENSE.txt
125
141
  - README.md
126
142
  - Rakefile
127
143
  - authorized_persona.gemspec
128
144
  - bin/console
129
145
  - bin/setup
146
+ - gemfiles/rails_6_0.gemfile
147
+ - gemfiles/rails_6_1.gemfile
148
+ - gemfiles/rails_7_0.gemfile
130
149
  - lib/authorized_persona.rb
131
150
  - lib/authorized_persona/authorization.rb
132
151
  - lib/authorized_persona/persona.rb
@@ -136,8 +155,9 @@ files:
136
155
  homepage: https://github.com/Betterment/authorized_persona
137
156
  licenses:
138
157
  - MIT
139
- metadata: {}
140
- post_install_message:
158
+ metadata:
159
+ rubygems_mfa_required: 'true'
160
+ post_install_message:
141
161
  rdoc_options: []
142
162
  require_paths:
143
163
  - lib
@@ -152,8 +172,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
152
172
  - !ruby/object:Gem::Version
153
173
  version: '0'
154
174
  requirements: []
155
- rubygems_version: 3.0.3
156
- signing_key:
175
+ rubygems_version: 3.4.12
176
+ signing_key:
157
177
  specification_version: 4
158
178
  summary: the simplest authorization library you will ever love
159
179
  test_files: []
data/.travis.yml DELETED
@@ -1,7 +0,0 @@
1
- ---
2
- sudo: false
3
- language: ruby
4
- cache: bundler
5
- rvm:
6
- - 2.6.1
7
- before_install: gem install bundler -v 2.0.1
data/Gemfile.lock DELETED
@@ -1,112 +0,0 @@
1
- PATH
2
- remote: .
3
- specs:
4
- authorized_persona (0.1.0)
5
- activemodel (>= 5.1.6.2, < 7)
6
- railties (>= 5.1.6.2, < 7)
7
-
8
- GEM
9
- remote: https://rubygems.org/
10
- specs:
11
- actionpack (5.2.3)
12
- actionview (= 5.2.3)
13
- activesupport (= 5.2.3)
14
- rack (~> 2.0)
15
- rack-test (>= 0.6.3)
16
- rails-dom-testing (~> 2.0)
17
- rails-html-sanitizer (~> 1.0, >= 1.0.2)
18
- actionview (5.2.3)
19
- activesupport (= 5.2.3)
20
- builder (~> 3.1)
21
- erubi (~> 1.4)
22
- rails-dom-testing (~> 2.0)
23
- rails-html-sanitizer (~> 1.0, >= 1.0.3)
24
- activemodel (5.2.3)
25
- activesupport (= 5.2.3)
26
- activesupport (5.2.3)
27
- concurrent-ruby (~> 1.0, >= 1.0.2)
28
- i18n (>= 0.7, < 2)
29
- minitest (~> 5.1)
30
- tzinfo (~> 1.1)
31
- ast (2.4.0)
32
- builder (3.2.3)
33
- concurrent-ruby (1.1.5)
34
- crass (1.0.4)
35
- diff-lcs (1.3)
36
- erubi (1.8.0)
37
- i18n (1.6.0)
38
- concurrent-ruby (~> 1.0)
39
- jaro_winkler (1.5.2)
40
- loofah (2.2.3)
41
- crass (~> 1.0.2)
42
- nokogiri (>= 1.5.9)
43
- method_source (0.9.2)
44
- mini_portile2 (2.4.0)
45
- minitest (5.11.3)
46
- nokogiri (1.10.3)
47
- mini_portile2 (~> 2.4.0)
48
- parallel (1.17.0)
49
- parser (2.6.3.0)
50
- ast (~> 2.4.0)
51
- powerpack (0.1.2)
52
- rack (2.0.7)
53
- rack-test (1.1.0)
54
- rack (>= 1.0, < 3)
55
- rails-dom-testing (2.0.3)
56
- activesupport (>= 4.2.0)
57
- nokogiri (>= 1.6)
58
- rails-html-sanitizer (1.0.4)
59
- loofah (~> 2.2, >= 2.2.2)
60
- railties (5.2.3)
61
- actionpack (= 5.2.3)
62
- activesupport (= 5.2.3)
63
- method_source
64
- rake (>= 0.8.7)
65
- thor (>= 0.19.0, < 2.0)
66
- rainbow (3.0.0)
67
- rake (10.5.0)
68
- rspec (3.8.0)
69
- rspec-core (~> 3.8.0)
70
- rspec-expectations (~> 3.8.0)
71
- rspec-mocks (~> 3.8.0)
72
- rspec-core (3.8.0)
73
- rspec-support (~> 3.8.0)
74
- rspec-expectations (3.8.3)
75
- diff-lcs (>= 1.2.0, < 2.0)
76
- rspec-support (~> 3.8.0)
77
- rspec-mocks (3.8.0)
78
- diff-lcs (>= 1.2.0, < 2.0)
79
- rspec-support (~> 3.8.0)
80
- rspec-support (3.8.0)
81
- rubocop (0.61.1)
82
- jaro_winkler (~> 1.5.1)
83
- parallel (~> 1.10)
84
- parser (>= 2.5, != 2.5.1.1)
85
- powerpack (~> 0.1)
86
- rainbow (>= 2.2.2, < 4.0)
87
- ruby-progressbar (~> 1.7)
88
- unicode-display_width (~> 1.4.0)
89
- rubocop-betterment (1.8.0)
90
- rubocop (~> 0.61.1)
91
- rubocop-rspec (= 1.28.0)
92
- rubocop-rspec (1.28.0)
93
- rubocop (>= 0.58.0)
94
- ruby-progressbar (1.10.1)
95
- thor (0.20.3)
96
- thread_safe (0.3.6)
97
- tzinfo (1.2.5)
98
- thread_safe (~> 0.1)
99
- unicode-display_width (1.4.1)
100
-
101
- PLATFORMS
102
- ruby
103
-
104
- DEPENDENCIES
105
- authorized_persona!
106
- bundler (~> 2.0)
107
- rake (~> 10.0)
108
- rspec (~> 3.0)
109
- rubocop-betterment
110
-
111
- BUNDLED WITH
112
- 2.0.1