clearance 2.11.0 → 2.12.0
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/.github/workflows/codeql.yml +3 -3
- data/.github/workflows/standardrb.yml +5 -2
- data/.github/workflows/tests.yml +8 -5
- data/Appraisals +3 -4
- data/CHANGELOG.md +48 -1
- data/Gemfile +2 -1
- data/Gemfile.lock +106 -98
- data/README.md +1 -2
- data/app/controllers/clearance/passwords_controller.rb +3 -3
- data/app/controllers/clearance/users_controller.rb +1 -1
- data/clearance.gemspec +3 -2
- data/gemfiles/rails_7.2.gemfile +3 -2
- data/gemfiles/rails_8.0.gemfile +3 -3
- data/gemfiles/{rails_7.1.gemfile → rails_8.1.gemfile} +4 -3
- data/lib/clearance/version.rb +1 -1
- data/lib/generators/clearance/install/install_generator.rb +1 -0
- data/spec/clearance/testing/deny_access_matcher_spec.rb +1 -0
- data/spec/controllers/passwords_controller_spec.rb +3 -3
- data/spec/controllers/users_controller_spec.rb +1 -1
- data/spec/password_strategies/bcrypt_spec.rb +1 -0
- data/spec/password_strategies/password_strategies_spec.rb +1 -0
- data/spec/requests/authentication_cookie_spec.rb +1 -0
- metadata +6 -5
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: de3f964eed826755511291f4864e3ac4ac2d4aaab072c386a8e3e596d540f8fb
|
|
4
|
+
data.tar.gz: 55b415f8cc8b31f0bd8ddfc6a44b1624973cf26fb8a74bde67b844187657eb9a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 2b148611311a59b4ff5c437a7742537fb74fe07c3e2a27d791c63db5f24b359f5931d867435095e0f5fb1cb303be7d477472d5f2aa3da6fd489d8ee64bf43866
|
|
7
|
+
data.tar.gz: 6b3239daba32dc324abe30fd43fa227079e7182dab1ce6a8f84064f90d2c6357373eb401cd4a889a0c65a355f1eaf27da8e4947305c18a489e8f3dae07105326
|
|
@@ -25,15 +25,15 @@ jobs:
|
|
|
25
25
|
build-mode: none
|
|
26
26
|
steps:
|
|
27
27
|
- name: Checkout repository
|
|
28
|
-
uses: actions/checkout@
|
|
28
|
+
uses: actions/checkout@v6
|
|
29
29
|
|
|
30
30
|
- name: Initialize CodeQL
|
|
31
|
-
uses: github/codeql-action/init@
|
|
31
|
+
uses: github/codeql-action/init@v4
|
|
32
32
|
with:
|
|
33
33
|
languages: ${{ matrix.language }}
|
|
34
34
|
build-mode: ${{ matrix.build-mode }}
|
|
35
35
|
|
|
36
36
|
- name: Perform CodeQL Analysis
|
|
37
|
-
uses: github/codeql-action/analyze@
|
|
37
|
+
uses: github/codeql-action/analyze@v4
|
|
38
38
|
with:
|
|
39
39
|
category: "/language:${{matrix.language}}"
|
|
@@ -9,11 +9,14 @@ on:
|
|
|
9
9
|
jobs:
|
|
10
10
|
standardrb:
|
|
11
11
|
name: StandardRB
|
|
12
|
+
permissions:
|
|
13
|
+
contents: read
|
|
14
|
+
pull-requests: write
|
|
12
15
|
runs-on: ubuntu-latest
|
|
13
16
|
steps:
|
|
14
|
-
- uses: actions/checkout@
|
|
17
|
+
- uses: actions/checkout@v6
|
|
15
18
|
- uses: ruby/setup-ruby@v1
|
|
16
19
|
with:
|
|
17
20
|
bundler-cache: true
|
|
18
|
-
ruby-version: 3.
|
|
21
|
+
ruby-version: 3.3.11
|
|
19
22
|
- run: bundle exec standardrb --format github --parallel
|
data/.github/workflows/tests.yml
CHANGED
|
@@ -9,6 +9,9 @@ on:
|
|
|
9
9
|
jobs:
|
|
10
10
|
test:
|
|
11
11
|
name: "Ruby ${{ matrix.ruby }}, Rails ${{ matrix.gemfile }}"
|
|
12
|
+
permissions:
|
|
13
|
+
contents: read
|
|
14
|
+
pull-requests: write
|
|
12
15
|
|
|
13
16
|
runs-on: ubuntu-latest
|
|
14
17
|
|
|
@@ -16,20 +19,20 @@ jobs:
|
|
|
16
19
|
fail-fast: false
|
|
17
20
|
matrix:
|
|
18
21
|
gemfile:
|
|
19
|
-
- "7.1"
|
|
20
22
|
- "7.2"
|
|
21
23
|
- "8.0"
|
|
24
|
+
- "8.1"
|
|
22
25
|
ruby:
|
|
23
|
-
- "3.
|
|
24
|
-
- "3.
|
|
25
|
-
- "
|
|
26
|
+
- "3.3.11"
|
|
27
|
+
- "3.4.9"
|
|
28
|
+
- "4.0.2"
|
|
26
29
|
|
|
27
30
|
env:
|
|
28
31
|
BUNDLE_GEMFILE: gemfiles/rails_${{ matrix.gemfile }}.gemfile
|
|
29
32
|
RAILS_ENV: test
|
|
30
33
|
|
|
31
34
|
steps:
|
|
32
|
-
- uses: actions/checkout@
|
|
35
|
+
- uses: actions/checkout@v6
|
|
33
36
|
|
|
34
37
|
- name: "Install Ruby ${{ matrix.ruby }}"
|
|
35
38
|
uses: ruby/setup-ruby@v1
|
data/Appraisals
CHANGED
|
@@ -1,7 +1,3 @@
|
|
|
1
|
-
appraise "rails_7.1" do
|
|
2
|
-
gem "railties", "~> 7.1.0"
|
|
3
|
-
end
|
|
4
|
-
|
|
5
1
|
appraise "rails_7.2" do
|
|
6
2
|
gem "railties", "~> 7.2.0"
|
|
7
3
|
end
|
|
@@ -10,3 +6,6 @@ appraise "rails_8.0" do
|
|
|
10
6
|
gem "railties", "~> 8.0.0"
|
|
11
7
|
gem "sqlite3", ">= 2.1"
|
|
12
8
|
end
|
|
9
|
+
appraise "rails_8.1" do
|
|
10
|
+
gem "railties", "~> 8.1.0"
|
|
11
|
+
end
|
data/CHANGELOG.md
CHANGED
|
@@ -5,7 +5,54 @@ complete changelog, see the git history for each version via the version links.
|
|
|
5
5
|
|
|
6
6
|
## [Unreleased]
|
|
7
7
|
|
|
8
|
-
[Unreleased]: https://github.com/thoughtbot/clearance/compare/v2.
|
|
8
|
+
[Unreleased]: https://github.com/thoughtbot/clearance/compare/v2.12.0...main
|
|
9
|
+
|
|
10
|
+
## [2.12.0] - April 17, 2026
|
|
11
|
+
|
|
12
|
+
Highlights of this release:
|
|
13
|
+
|
|
14
|
+
* Remove support for Ruby 3.2.9
|
|
15
|
+
* Bump ruby 3.3.9 to 3.3.11
|
|
16
|
+
* Make ruby 3.3.11 the minimum required version
|
|
17
|
+
* Bump ruby 3.4.5 to 3.4.9
|
|
18
|
+
* Add ruby 4.0.2
|
|
19
|
+
* Remove RoR 7.1.0 support
|
|
20
|
+
* Add RoR 8.1.0 support
|
|
21
|
+
|
|
22
|
+
All changes:
|
|
23
|
+
|
|
24
|
+
- Bump shoulda-matchers from 5.1.0 to 6.5.0 (#1066)
|
|
25
|
+
- Bump nokogiri from 1.18.9 to 1.18.10 (#1067)
|
|
26
|
+
- Bump standard from 1.50.0 to 1.51.1 (#1068)
|
|
27
|
+
- Bump database_cleaner from 2.0.1 to 2.1.0 (#1069)
|
|
28
|
+
- Bump timecop from 0.9.5 to 0.9.10 (#1070)
|
|
29
|
+
- Bump github/codeql-action from 3 to 4 (#1072)
|
|
30
|
+
- Bump rack from 3.1.16 to 3.1.18 (#1073)
|
|
31
|
+
- Bump railties from 7.2.2.2 to 7.2.3 (#1074)
|
|
32
|
+
- Bump standard from 1.51.1 to 1.52.0 (#1079)
|
|
33
|
+
- Bump actions/checkout from 5 to 6 (#1080)
|
|
34
|
+
- Bump addressable from 2.8.7 to 2.8.8 (#1081)
|
|
35
|
+
- Bump sqlite3 from 2.7.4 to 2.8.1 (#1082)
|
|
36
|
+
- Remove CodeClimate badge (broken) (#1084) Valeria Graffeo
|
|
37
|
+
- Replace obsolete unprocessable_entity with unprocessable_content (#1085) Sara Jackson
|
|
38
|
+
- Upgrade Ruby and Rails versions (#1088) Fernando Perales
|
|
39
|
+
- Bump rack-session from 2.1.1 to 2.1.2 (#1089)
|
|
40
|
+
- Bump activesupport from 7.2.3 to 7.2.3.1 (#1090)
|
|
41
|
+
- Bump addressable from 2.8.8 to 2.9.0 (#1091)
|
|
42
|
+
- Bump bcrypt from 3.1.20 to 3.1.22 (#1092)
|
|
43
|
+
- Bump standard from 1.52.0 to 1.54.0 (#1093)
|
|
44
|
+
- Bump pry from 0.15.2 to 0.16.0 (#1094)
|
|
45
|
+
- Bump shoulda-matchers from 6.5.0 to 7.0.1 (#1095)
|
|
46
|
+
- Bump json from 2.16.0 to 2.17.1.2 (#1096)
|
|
47
|
+
- Bump nokogiri from 1.18.10 to 1.19.2 (#1099)
|
|
48
|
+
- Add missing permissions to GitHub Actions jobs (#1100) Fernando Perales
|
|
49
|
+
- Bump rspec-rails from 8.0.2 to 8.0.4 (#1101)
|
|
50
|
+
- Bump sqlite3 from 2.8.1 to 2.9.2 (#1104)
|
|
51
|
+
- Bump ffi from 1.17.2 to 1.17.4 (#1103)
|
|
52
|
+
- Bump timecop from 0.9.10 to 0.9.11 (#1105)
|
|
53
|
+
- Bump argon2 from 2.3.2 to 2.3.3 (#1102)
|
|
54
|
+
|
|
55
|
+
[2.12.0]: https://github.com/thoughtbot/clearance/compare/v2.11.0...v2.12.0
|
|
9
56
|
|
|
10
57
|
## [2.11.0] - September 26, 2025
|
|
11
58
|
- Bump actions/checkout from 4 to 5 for tests workflow (#1051)
|
data/Gemfile
CHANGED
|
@@ -5,6 +5,7 @@ gemspec
|
|
|
5
5
|
gem "addressable"
|
|
6
6
|
gem "ammeter"
|
|
7
7
|
gem "appraisal"
|
|
8
|
+
gem "benchmark"
|
|
8
9
|
gem "capybara"
|
|
9
10
|
gem "database_cleaner"
|
|
10
11
|
gem "erb_lint", require: false
|
|
@@ -15,6 +16,6 @@ gem "pry", require: false
|
|
|
15
16
|
gem "rails-controller-testing"
|
|
16
17
|
gem "rspec-rails"
|
|
17
18
|
gem "shoulda-matchers"
|
|
18
|
-
gem "sqlite3", "~> 2.
|
|
19
|
+
gem "sqlite3", "~> 2.9"
|
|
19
20
|
gem "standard", ">= 1.35.1", require: false
|
|
20
21
|
gem "timecop"
|
data/Gemfile.lock
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
clearance (2.
|
|
4
|
+
clearance (2.12.0)
|
|
5
5
|
actionmailer (>= 5.0)
|
|
6
6
|
activemodel (>= 5.0)
|
|
7
7
|
activerecord (>= 5.0)
|
|
@@ -13,53 +13,53 @@ PATH
|
|
|
13
13
|
GEM
|
|
14
14
|
remote: https://rubygems.org/
|
|
15
15
|
specs:
|
|
16
|
-
actionmailer (
|
|
17
|
-
actionpack (=
|
|
18
|
-
actionview (=
|
|
19
|
-
activejob (=
|
|
20
|
-
activesupport (=
|
|
16
|
+
actionmailer (8.1.3)
|
|
17
|
+
actionpack (= 8.1.3)
|
|
18
|
+
actionview (= 8.1.3)
|
|
19
|
+
activejob (= 8.1.3)
|
|
20
|
+
activesupport (= 8.1.3)
|
|
21
21
|
mail (>= 2.8.0)
|
|
22
22
|
rails-dom-testing (~> 2.2)
|
|
23
|
-
actionpack (
|
|
24
|
-
actionview (=
|
|
25
|
-
activesupport (=
|
|
23
|
+
actionpack (8.1.3)
|
|
24
|
+
actionview (= 8.1.3)
|
|
25
|
+
activesupport (= 8.1.3)
|
|
26
26
|
nokogiri (>= 1.8.5)
|
|
27
|
-
|
|
28
|
-
rack (>= 2.2.4, < 3.2)
|
|
27
|
+
rack (>= 2.2.4)
|
|
29
28
|
rack-session (>= 1.0.1)
|
|
30
29
|
rack-test (>= 0.6.3)
|
|
31
30
|
rails-dom-testing (~> 2.2)
|
|
32
31
|
rails-html-sanitizer (~> 1.6)
|
|
33
32
|
useragent (~> 0.16)
|
|
34
|
-
actionview (
|
|
35
|
-
activesupport (=
|
|
33
|
+
actionview (8.1.3)
|
|
34
|
+
activesupport (= 8.1.3)
|
|
36
35
|
builder (~> 3.1)
|
|
37
36
|
erubi (~> 1.11)
|
|
38
37
|
rails-dom-testing (~> 2.2)
|
|
39
38
|
rails-html-sanitizer (~> 1.6)
|
|
40
|
-
activejob (
|
|
41
|
-
activesupport (=
|
|
39
|
+
activejob (8.1.3)
|
|
40
|
+
activesupport (= 8.1.3)
|
|
42
41
|
globalid (>= 0.3.6)
|
|
43
|
-
activemodel (
|
|
44
|
-
activesupport (=
|
|
45
|
-
activerecord (
|
|
46
|
-
activemodel (=
|
|
47
|
-
activesupport (=
|
|
42
|
+
activemodel (8.1.3)
|
|
43
|
+
activesupport (= 8.1.3)
|
|
44
|
+
activerecord (8.1.3)
|
|
45
|
+
activemodel (= 8.1.3)
|
|
46
|
+
activesupport (= 8.1.3)
|
|
48
47
|
timeout (>= 0.4.0)
|
|
49
|
-
activesupport (
|
|
48
|
+
activesupport (8.1.3)
|
|
50
49
|
base64
|
|
51
|
-
benchmark (>= 0.3)
|
|
52
50
|
bigdecimal
|
|
53
51
|
concurrent-ruby (~> 1.0, >= 1.3.1)
|
|
54
52
|
connection_pool (>= 2.2.5)
|
|
55
53
|
drb
|
|
56
54
|
i18n (>= 1.6, < 2)
|
|
55
|
+
json
|
|
57
56
|
logger (>= 1.4.2)
|
|
58
57
|
minitest (>= 5.1)
|
|
59
58
|
securerandom (>= 0.3)
|
|
60
59
|
tzinfo (~> 2.0, >= 2.0.5)
|
|
61
|
-
|
|
62
|
-
|
|
60
|
+
uri (>= 0.13.1)
|
|
61
|
+
addressable (2.9.0)
|
|
62
|
+
public_suffix (>= 2.0.2, < 8.0)
|
|
63
63
|
ammeter (1.1.7)
|
|
64
64
|
activesupport (>= 3.0)
|
|
65
65
|
railties (>= 3.0)
|
|
@@ -68,13 +68,13 @@ GEM
|
|
|
68
68
|
bundler
|
|
69
69
|
rake
|
|
70
70
|
thor (>= 0.14.0)
|
|
71
|
-
argon2 (2.3.
|
|
71
|
+
argon2 (2.3.3)
|
|
72
72
|
ffi (~> 1.15)
|
|
73
73
|
ffi-compiler (~> 1.0)
|
|
74
|
-
ast (2.4.
|
|
74
|
+
ast (2.4.3)
|
|
75
75
|
base64 (0.3.0)
|
|
76
|
-
bcrypt (3.1.
|
|
77
|
-
benchmark (0.
|
|
76
|
+
bcrypt (3.1.22)
|
|
77
|
+
benchmark (0.5.0)
|
|
78
78
|
better_html (2.1.1)
|
|
79
79
|
actionview (>= 6.0)
|
|
80
80
|
activesupport (>= 6.0)
|
|
@@ -82,7 +82,7 @@ GEM
|
|
|
82
82
|
erubi (~> 1.4)
|
|
83
83
|
parser (>= 2.4)
|
|
84
84
|
smart_properties
|
|
85
|
-
bigdecimal (
|
|
85
|
+
bigdecimal (4.1.1)
|
|
86
86
|
builder (3.3.0)
|
|
87
87
|
capybara (3.40.0)
|
|
88
88
|
addressable
|
|
@@ -93,24 +93,22 @@ GEM
|
|
|
93
93
|
rack-test (>= 0.6.3)
|
|
94
94
|
regexp_parser (>= 1.5, < 3.0)
|
|
95
95
|
xpath (~> 3.2)
|
|
96
|
-
cgi (0.5.0)
|
|
97
96
|
coderay (1.1.3)
|
|
98
|
-
concurrent-ruby (1.3.
|
|
99
|
-
connection_pool (
|
|
97
|
+
concurrent-ruby (1.3.6)
|
|
98
|
+
connection_pool (3.0.2)
|
|
100
99
|
crass (1.0.6)
|
|
101
|
-
database_cleaner (2.0
|
|
102
|
-
database_cleaner-active_record (
|
|
103
|
-
database_cleaner-active_record (2.
|
|
100
|
+
database_cleaner (2.1.0)
|
|
101
|
+
database_cleaner-active_record (>= 2, < 3)
|
|
102
|
+
database_cleaner-active_record (2.2.2)
|
|
104
103
|
activerecord (>= 5.a)
|
|
105
|
-
database_cleaner-core (~> 2.0
|
|
104
|
+
database_cleaner-core (~> 2.0)
|
|
106
105
|
database_cleaner-core (2.0.1)
|
|
107
|
-
date (3.
|
|
106
|
+
date (3.5.1)
|
|
108
107
|
diff-lcs (1.6.2)
|
|
109
108
|
drb (2.2.3)
|
|
110
109
|
email_validator (2.2.4)
|
|
111
110
|
activemodel
|
|
112
|
-
erb (
|
|
113
|
-
cgi (>= 0.3.3)
|
|
111
|
+
erb (6.0.2)
|
|
114
112
|
erb_lint (0.9.0)
|
|
115
113
|
activesupport
|
|
116
114
|
better_html (>= 2.0.1)
|
|
@@ -124,25 +122,26 @@ GEM
|
|
|
124
122
|
factory_bot_rails (6.5.1)
|
|
125
123
|
factory_bot (~> 6.5)
|
|
126
124
|
railties (>= 6.1.0)
|
|
127
|
-
ffi (1.17.
|
|
128
|
-
ffi (1.17.
|
|
125
|
+
ffi (1.17.4-arm64-darwin)
|
|
126
|
+
ffi (1.17.4-x86_64-linux-gnu)
|
|
129
127
|
ffi-compiler (1.3.2)
|
|
130
128
|
ffi (>= 1.15.5)
|
|
131
129
|
rake
|
|
132
130
|
globalid (1.2.1)
|
|
133
131
|
activesupport (>= 6.1)
|
|
134
|
-
i18n (1.14.
|
|
132
|
+
i18n (1.14.8)
|
|
135
133
|
concurrent-ruby (~> 1.0)
|
|
136
|
-
io-console (0.8.
|
|
137
|
-
irb (1.
|
|
134
|
+
io-console (0.8.2)
|
|
135
|
+
irb (1.17.0)
|
|
138
136
|
pp (>= 0.6.0)
|
|
137
|
+
prism (>= 1.3.0)
|
|
139
138
|
rdoc (>= 4.0.0)
|
|
140
139
|
reline (>= 0.4.2)
|
|
141
|
-
json (2.
|
|
140
|
+
json (2.19.3)
|
|
142
141
|
language_server-protocol (3.17.0.5)
|
|
143
142
|
lint_roller (1.1.0)
|
|
144
143
|
logger (1.7.0)
|
|
145
|
-
loofah (2.
|
|
144
|
+
loofah (2.25.1)
|
|
146
145
|
crass (~> 1.0.2)
|
|
147
146
|
nokogiri (>= 1.12.0)
|
|
148
147
|
mail (2.8.1)
|
|
@@ -153,7 +152,9 @@ GEM
|
|
|
153
152
|
matrix (0.4.3)
|
|
154
153
|
method_source (1.1.0)
|
|
155
154
|
mini_mime (1.1.5)
|
|
156
|
-
minitest (
|
|
155
|
+
minitest (6.0.3)
|
|
156
|
+
drb (~> 2.0)
|
|
157
|
+
prism (~> 1.5)
|
|
157
158
|
net-imap (0.4.20)
|
|
158
159
|
date
|
|
159
160
|
net-protocol
|
|
@@ -163,33 +164,34 @@ GEM
|
|
|
163
164
|
timeout
|
|
164
165
|
net-smtp (0.5.1)
|
|
165
166
|
net-protocol
|
|
166
|
-
nokogiri (1.
|
|
167
|
+
nokogiri (1.19.2-arm64-darwin)
|
|
167
168
|
racc (~> 1.4)
|
|
168
|
-
nokogiri (1.
|
|
169
|
+
nokogiri (1.19.2-x86_64-linux-gnu)
|
|
169
170
|
racc (~> 1.4)
|
|
170
|
-
parallel (1.
|
|
171
|
-
parser (3.3.
|
|
171
|
+
parallel (1.28.0)
|
|
172
|
+
parser (3.3.11.1)
|
|
172
173
|
ast (~> 2.4.1)
|
|
173
174
|
racc
|
|
174
|
-
pp (0.6.
|
|
175
|
+
pp (0.6.3)
|
|
175
176
|
prettyprint
|
|
176
177
|
prettyprint (0.2.0)
|
|
177
|
-
prism (1.
|
|
178
|
-
pry (0.
|
|
178
|
+
prism (1.9.0)
|
|
179
|
+
pry (0.16.0)
|
|
179
180
|
coderay (~> 1.1)
|
|
180
181
|
method_source (~> 1.0)
|
|
181
|
-
|
|
182
|
+
reline (>= 0.6.0)
|
|
183
|
+
psych (5.3.1)
|
|
182
184
|
date
|
|
183
185
|
stringio
|
|
184
|
-
public_suffix (
|
|
186
|
+
public_suffix (7.0.5)
|
|
185
187
|
racc (1.8.1)
|
|
186
|
-
rack (3.
|
|
187
|
-
rack-session (2.1.
|
|
188
|
+
rack (3.2.6)
|
|
189
|
+
rack-session (2.1.2)
|
|
188
190
|
base64 (>= 0.1.0)
|
|
189
191
|
rack (>= 3.0.0)
|
|
190
192
|
rack-test (2.2.0)
|
|
191
193
|
rack (>= 1.3)
|
|
192
|
-
rackup (2.
|
|
194
|
+
rackup (2.3.1)
|
|
193
195
|
rack (>= 3)
|
|
194
196
|
rails-controller-testing (1.0.5)
|
|
195
197
|
actionpack (>= 5.0.1.rc1)
|
|
@@ -199,43 +201,45 @@ GEM
|
|
|
199
201
|
activesupport (>= 5.0.0)
|
|
200
202
|
minitest
|
|
201
203
|
nokogiri (>= 1.6)
|
|
202
|
-
rails-html-sanitizer (1.
|
|
203
|
-
loofah (~> 2.
|
|
204
|
+
rails-html-sanitizer (1.7.0)
|
|
205
|
+
loofah (~> 2.25)
|
|
204
206
|
nokogiri (>= 1.15.7, != 1.16.7, != 1.16.6, != 1.16.5, != 1.16.4, != 1.16.3, != 1.16.2, != 1.16.1, != 1.16.0.rc1, != 1.16.0)
|
|
205
|
-
railties (
|
|
206
|
-
actionpack (=
|
|
207
|
-
activesupport (=
|
|
207
|
+
railties (8.1.3)
|
|
208
|
+
actionpack (= 8.1.3)
|
|
209
|
+
activesupport (= 8.1.3)
|
|
208
210
|
irb (~> 1.13)
|
|
209
211
|
rackup (>= 1.0.0)
|
|
210
212
|
rake (>= 12.2)
|
|
211
213
|
thor (~> 1.0, >= 1.2.2)
|
|
214
|
+
tsort (>= 0.2)
|
|
212
215
|
zeitwerk (~> 2.6)
|
|
213
216
|
rainbow (3.1.1)
|
|
214
|
-
rake (13.3.
|
|
215
|
-
rdoc (
|
|
217
|
+
rake (13.3.1)
|
|
218
|
+
rdoc (7.2.0)
|
|
216
219
|
erb
|
|
217
220
|
psych (>= 4.0.0)
|
|
218
|
-
|
|
219
|
-
|
|
221
|
+
tsort
|
|
222
|
+
regexp_parser (2.12.0)
|
|
223
|
+
reline (0.6.3)
|
|
220
224
|
io-console (~> 0.5)
|
|
221
|
-
rspec-core (3.13.
|
|
225
|
+
rspec-core (3.13.6)
|
|
222
226
|
rspec-support (~> 3.13.0)
|
|
223
227
|
rspec-expectations (3.13.5)
|
|
224
228
|
diff-lcs (>= 1.2.0, < 2.0)
|
|
225
229
|
rspec-support (~> 3.13.0)
|
|
226
|
-
rspec-mocks (3.13.
|
|
230
|
+
rspec-mocks (3.13.8)
|
|
227
231
|
diff-lcs (>= 1.2.0, < 2.0)
|
|
228
232
|
rspec-support (~> 3.13.0)
|
|
229
|
-
rspec-rails (8.0.
|
|
233
|
+
rspec-rails (8.0.4)
|
|
230
234
|
actionpack (>= 7.2)
|
|
231
235
|
activesupport (>= 7.2)
|
|
232
236
|
railties (>= 7.2)
|
|
233
|
-
rspec-core (
|
|
234
|
-
rspec-expectations (
|
|
235
|
-
rspec-mocks (
|
|
236
|
-
rspec-support (
|
|
237
|
-
rspec-support (3.13.
|
|
238
|
-
rubocop (1.
|
|
237
|
+
rspec-core (>= 3.13.0, < 5.0.0)
|
|
238
|
+
rspec-expectations (>= 3.13.0, < 5.0.0)
|
|
239
|
+
rspec-mocks (>= 3.13.0, < 5.0.0)
|
|
240
|
+
rspec-support (>= 3.13.0, < 5.0.0)
|
|
241
|
+
rspec-support (3.13.7)
|
|
242
|
+
rubocop (1.84.2)
|
|
239
243
|
json (~> 2.3)
|
|
240
244
|
language_server-protocol (~> 3.17.0.2)
|
|
241
245
|
lint_roller (~> 1.1.0)
|
|
@@ -243,57 +247,61 @@ GEM
|
|
|
243
247
|
parser (>= 3.3.0.2)
|
|
244
248
|
rainbow (>= 2.2.2, < 4.0)
|
|
245
249
|
regexp_parser (>= 2.9.3, < 3.0)
|
|
246
|
-
rubocop-ast (>= 1.
|
|
250
|
+
rubocop-ast (>= 1.49.0, < 2.0)
|
|
247
251
|
ruby-progressbar (~> 1.7)
|
|
248
252
|
unicode-display_width (>= 2.4.0, < 4.0)
|
|
249
|
-
rubocop-ast (1.
|
|
253
|
+
rubocop-ast (1.49.1)
|
|
250
254
|
parser (>= 3.3.7.2)
|
|
251
|
-
prism (~> 1.
|
|
252
|
-
rubocop-performance (1.
|
|
255
|
+
prism (~> 1.7)
|
|
256
|
+
rubocop-performance (1.26.1)
|
|
253
257
|
lint_roller (~> 1.1)
|
|
254
258
|
rubocop (>= 1.75.0, < 2.0)
|
|
255
|
-
rubocop-ast (>= 1.
|
|
259
|
+
rubocop-ast (>= 1.47.1, < 2.0)
|
|
256
260
|
ruby-progressbar (1.13.0)
|
|
257
261
|
securerandom (0.4.1)
|
|
258
|
-
shoulda-matchers (
|
|
259
|
-
activesupport (>=
|
|
262
|
+
shoulda-matchers (7.0.1)
|
|
263
|
+
activesupport (>= 7.1)
|
|
260
264
|
smart_properties (1.17.0)
|
|
261
|
-
sqlite3 (2.
|
|
262
|
-
sqlite3 (2.
|
|
263
|
-
standard (1.
|
|
265
|
+
sqlite3 (2.9.2-arm64-darwin)
|
|
266
|
+
sqlite3 (2.9.2-x86_64-linux-gnu)
|
|
267
|
+
standard (1.54.0)
|
|
264
268
|
language_server-protocol (~> 3.17.0.2)
|
|
265
269
|
lint_roller (~> 1.0)
|
|
266
|
-
rubocop (~> 1.
|
|
270
|
+
rubocop (~> 1.84.0)
|
|
267
271
|
standard-custom (~> 1.0.0)
|
|
268
272
|
standard-performance (~> 1.8)
|
|
269
273
|
standard-custom (1.0.2)
|
|
270
274
|
lint_roller (~> 1.0)
|
|
271
275
|
rubocop (~> 1.50)
|
|
272
|
-
standard-performance (1.
|
|
276
|
+
standard-performance (1.9.0)
|
|
273
277
|
lint_roller (~> 1.1)
|
|
274
|
-
rubocop-performance (~> 1.
|
|
275
|
-
stringio (3.
|
|
276
|
-
thor (1.
|
|
277
|
-
timecop (0.9.
|
|
278
|
+
rubocop-performance (~> 1.26.0)
|
|
279
|
+
stringio (3.2.0)
|
|
280
|
+
thor (1.5.0)
|
|
281
|
+
timecop (0.9.11)
|
|
278
282
|
timeout (0.4.3)
|
|
283
|
+
tsort (0.2.0)
|
|
279
284
|
tzinfo (2.0.6)
|
|
280
285
|
concurrent-ruby (~> 1.0)
|
|
281
|
-
unicode-display_width (3.
|
|
282
|
-
unicode-emoji (~> 4.
|
|
283
|
-
unicode-emoji (4.0
|
|
286
|
+
unicode-display_width (3.2.0)
|
|
287
|
+
unicode-emoji (~> 4.1)
|
|
288
|
+
unicode-emoji (4.2.0)
|
|
289
|
+
uri (1.1.1)
|
|
284
290
|
useragent (0.16.11)
|
|
285
291
|
xpath (3.2.0)
|
|
286
292
|
nokogiri (~> 1.8)
|
|
287
|
-
zeitwerk (2.
|
|
293
|
+
zeitwerk (2.7.5)
|
|
288
294
|
|
|
289
295
|
PLATFORMS
|
|
290
296
|
arm64-darwin-24
|
|
297
|
+
arm64-darwin-25
|
|
291
298
|
x86_64-linux
|
|
292
299
|
|
|
293
300
|
DEPENDENCIES
|
|
294
301
|
addressable
|
|
295
302
|
ammeter
|
|
296
303
|
appraisal
|
|
304
|
+
benchmark
|
|
297
305
|
capybara
|
|
298
306
|
clearance!
|
|
299
307
|
database_cleaner
|
|
@@ -305,7 +313,7 @@ DEPENDENCIES
|
|
|
305
313
|
rails-controller-testing
|
|
306
314
|
rspec-rails
|
|
307
315
|
shoulda-matchers
|
|
308
|
-
sqlite3 (~> 2.
|
|
316
|
+
sqlite3 (~> 2.9)
|
|
309
317
|
standard (>= 1.35.1)
|
|
310
318
|
timecop
|
|
311
319
|
|
data/README.md
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
# Clearance
|
|
2
2
|
|
|
3
3
|
[]( https://github.com/thoughtbot/clearance/actions/workflows/tests.yml?query=branch%3Amain)
|
|
4
|
-
[](https://codeclimate.com/github/thoughtbot/clearance)
|
|
5
4
|
[](https://inch-ci.org/github/thoughtbot/clearance)
|
|
6
5
|
|
|
7
6
|
Rails authentication with email & password.
|
|
@@ -18,7 +17,7 @@ monitored by contributors.
|
|
|
18
17
|
|
|
19
18
|
## Getting Started
|
|
20
19
|
|
|
21
|
-
Clearance is a Rails engine tested against Rails `>= 7.
|
|
20
|
+
Clearance is a Rails engine tested against Rails `>= 7.2` and Ruby `>= 3.3.11`.
|
|
22
21
|
|
|
23
22
|
You can add it to your Gemfile with:
|
|
24
23
|
|
|
@@ -38,7 +38,7 @@ class Clearance::PasswordsController < Clearance::BaseController
|
|
|
38
38
|
session[:password_reset_token] = nil
|
|
39
39
|
else
|
|
40
40
|
flash_failure_after_update
|
|
41
|
-
render template: "passwords/edit", status: :
|
|
41
|
+
render template: "passwords/edit", status: :unprocessable_content
|
|
42
42
|
end
|
|
43
43
|
end
|
|
44
44
|
|
|
@@ -80,14 +80,14 @@ class Clearance::PasswordsController < Clearance::BaseController
|
|
|
80
80
|
def ensure_email_present
|
|
81
81
|
if email_from_password_params.blank?
|
|
82
82
|
flash_failure_when_missing_email
|
|
83
|
-
render template: "passwords/new", status: :
|
|
83
|
+
render template: "passwords/new", status: :unprocessable_content
|
|
84
84
|
end
|
|
85
85
|
end
|
|
86
86
|
|
|
87
87
|
def ensure_existing_user
|
|
88
88
|
unless find_user_by_id_and_confirmation_token
|
|
89
89
|
flash_failure_when_forbidden
|
|
90
|
-
render template: "passwords/new", status: :
|
|
90
|
+
render template: "passwords/new", status: :unprocessable_content
|
|
91
91
|
end
|
|
92
92
|
end
|
|
93
93
|
|
|
@@ -14,7 +14,7 @@ class Clearance::UsersController < Clearance::BaseController
|
|
|
14
14
|
sign_in @user
|
|
15
15
|
redirect_back_or url_after_create
|
|
16
16
|
else
|
|
17
|
-
render template: "users/new", status: :
|
|
17
|
+
render template: "users/new", status: :unprocessable_content
|
|
18
18
|
end
|
|
19
19
|
end
|
|
20
20
|
|
data/clearance.gemspec
CHANGED
|
@@ -29,7 +29,8 @@ Gem::Specification.new do |s|
|
|
|
29
29
|
"Galen Frechette",
|
|
30
30
|
"Josh Steiner",
|
|
31
31
|
"Dorian Marié",
|
|
32
|
-
"Sara Jackson"
|
|
32
|
+
"Sara Jackson",
|
|
33
|
+
"Fernando Perales"
|
|
33
34
|
]
|
|
34
35
|
s.description = <<-DESCRIPTION
|
|
35
36
|
Clearance is built to support authentication and authorization via an
|
|
@@ -46,7 +47,7 @@ Gem::Specification.new do |s|
|
|
|
46
47
|
s.name = "clearance"
|
|
47
48
|
s.rdoc_options = ["--charset=UTF-8"]
|
|
48
49
|
s.require_paths = ["lib"]
|
|
49
|
-
s.required_ruby_version = Gem::Requirement.new(">= 3.
|
|
50
|
+
s.required_ruby_version = Gem::Requirement.new(">= 3.3.11")
|
|
50
51
|
s.summary = "Rails authentication & authorization with email & password."
|
|
51
52
|
s.version = Clearance::VERSION
|
|
52
53
|
end
|
data/gemfiles/rails_7.2.gemfile
CHANGED
|
@@ -5,17 +5,18 @@ source "https://rubygems.org"
|
|
|
5
5
|
gem "addressable"
|
|
6
6
|
gem "ammeter"
|
|
7
7
|
gem "appraisal"
|
|
8
|
+
gem "benchmark"
|
|
8
9
|
gem "capybara"
|
|
9
10
|
gem "database_cleaner"
|
|
10
11
|
gem "erb_lint", require: false
|
|
11
12
|
gem "factory_bot_rails"
|
|
12
|
-
gem "ffi", "< 1.
|
|
13
|
+
gem "ffi", "< 1.18.0"
|
|
13
14
|
gem "nokogiri"
|
|
14
15
|
gem "pry", require: false
|
|
15
16
|
gem "rails-controller-testing"
|
|
16
17
|
gem "rspec-rails"
|
|
17
18
|
gem "shoulda-matchers"
|
|
18
|
-
gem "sqlite3", "~>
|
|
19
|
+
gem "sqlite3", "~> 2.8"
|
|
19
20
|
gem "standard", ">= 1.35.1", require: false
|
|
20
21
|
gem "timecop"
|
|
21
22
|
gem "railties", "~> 7.2.0"
|
data/gemfiles/rails_8.0.gemfile
CHANGED
|
@@ -5,20 +5,20 @@ source "https://rubygems.org"
|
|
|
5
5
|
gem "addressable"
|
|
6
6
|
gem "ammeter"
|
|
7
7
|
gem "appraisal"
|
|
8
|
+
gem "benchmark"
|
|
8
9
|
gem "capybara"
|
|
9
10
|
gem "database_cleaner"
|
|
10
11
|
gem "erb_lint", require: false
|
|
11
12
|
gem "factory_bot_rails"
|
|
12
|
-
gem "ffi", "< 1.
|
|
13
|
+
gem "ffi", "< 1.18.0"
|
|
13
14
|
gem "nokogiri"
|
|
14
15
|
gem "pry", require: false
|
|
15
16
|
gem "rails-controller-testing"
|
|
16
17
|
gem "rspec-rails"
|
|
17
18
|
gem "shoulda-matchers"
|
|
18
|
-
gem "sqlite3", "
|
|
19
|
+
gem "sqlite3", ">= 2.1"
|
|
19
20
|
gem "standard", ">= 1.35.1", require: false
|
|
20
21
|
gem "timecop"
|
|
21
22
|
gem "railties", "~> 8.0.0"
|
|
22
|
-
gem "net-smtp", require: false
|
|
23
23
|
|
|
24
24
|
gemspec path: "../"
|
|
@@ -5,19 +5,20 @@ source "https://rubygems.org"
|
|
|
5
5
|
gem "addressable"
|
|
6
6
|
gem "ammeter"
|
|
7
7
|
gem "appraisal"
|
|
8
|
+
gem "benchmark"
|
|
8
9
|
gem "capybara"
|
|
9
10
|
gem "database_cleaner"
|
|
10
11
|
gem "erb_lint", require: false
|
|
11
12
|
gem "factory_bot_rails"
|
|
12
|
-
gem "ffi", "< 1.
|
|
13
|
+
gem "ffi", "< 1.18.0"
|
|
13
14
|
gem "nokogiri"
|
|
14
15
|
gem "pry", require: false
|
|
15
16
|
gem "rails-controller-testing"
|
|
16
17
|
gem "rspec-rails"
|
|
17
18
|
gem "shoulda-matchers"
|
|
18
|
-
gem "sqlite3", "~>
|
|
19
|
+
gem "sqlite3", "~> 2.8"
|
|
19
20
|
gem "standard", ">= 1.35.1", require: false
|
|
20
21
|
gem "timecop"
|
|
21
|
-
gem "railties", "~>
|
|
22
|
+
gem "railties", "~> 8.1.0"
|
|
22
23
|
|
|
23
24
|
gemspec path: "../"
|
data/lib/clearance/version.rb
CHANGED
|
@@ -62,7 +62,7 @@ describe Clearance::PasswordsController do
|
|
|
62
62
|
password: {}
|
|
63
63
|
}
|
|
64
64
|
|
|
65
|
-
expect(response).to have_http_status(:
|
|
65
|
+
expect(response).to have_http_status(:unprocessable_content)
|
|
66
66
|
end
|
|
67
67
|
end
|
|
68
68
|
|
|
@@ -85,7 +85,7 @@ describe Clearance::PasswordsController do
|
|
|
85
85
|
}
|
|
86
86
|
}
|
|
87
87
|
|
|
88
|
-
expect(response).to have_http_status(:
|
|
88
|
+
expect(response).to have_http_status(:unprocessable_content)
|
|
89
89
|
end
|
|
90
90
|
end
|
|
91
91
|
|
|
@@ -279,7 +279,7 @@ describe Clearance::PasswordsController do
|
|
|
279
279
|
)
|
|
280
280
|
|
|
281
281
|
expect(flash.now[:alert]).to match(I18n.t("flashes.failure_after_update"))
|
|
282
|
-
expect(response).to have_http_status(:
|
|
282
|
+
expect(response).to have_http_status(:unprocessable_content)
|
|
283
283
|
expect(response).to render_template(:edit)
|
|
284
284
|
end
|
|
285
285
|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: clearance
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.12.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Dan Croak
|
|
@@ -24,10 +24,11 @@ authors:
|
|
|
24
24
|
- Josh Steiner
|
|
25
25
|
- Dorian Marié
|
|
26
26
|
- Sara Jackson
|
|
27
|
+
- Fernando Perales
|
|
27
28
|
autorequire:
|
|
28
29
|
bindir: bin
|
|
29
30
|
cert_chain: []
|
|
30
|
-
date:
|
|
31
|
+
date: 2026-04-17 00:00:00.000000000 Z
|
|
31
32
|
dependencies:
|
|
32
33
|
- !ruby/object:Gem::Dependency
|
|
33
34
|
name: bcrypt
|
|
@@ -187,9 +188,9 @@ files:
|
|
|
187
188
|
- clearance.gemspec
|
|
188
189
|
- config/locales/clearance.en.yml
|
|
189
190
|
- config/routes.rb
|
|
190
|
-
- gemfiles/rails_7.1.gemfile
|
|
191
191
|
- gemfiles/rails_7.2.gemfile
|
|
192
192
|
- gemfiles/rails_8.0.gemfile
|
|
193
|
+
- gemfiles/rails_8.1.gemfile
|
|
193
194
|
- lib/clearance.rb
|
|
194
195
|
- lib/clearance/authentication.rb
|
|
195
196
|
- lib/clearance/authorization.rb
|
|
@@ -318,14 +319,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
318
319
|
requirements:
|
|
319
320
|
- - ">="
|
|
320
321
|
- !ruby/object:Gem::Version
|
|
321
|
-
version: 3.
|
|
322
|
+
version: 3.3.11
|
|
322
323
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
323
324
|
requirements:
|
|
324
325
|
- - ">="
|
|
325
326
|
- !ruby/object:Gem::Version
|
|
326
327
|
version: '0'
|
|
327
328
|
requirements: []
|
|
328
|
-
rubygems_version: 3.
|
|
329
|
+
rubygems_version: 3.5.22
|
|
329
330
|
signing_key:
|
|
330
331
|
specification_version: 4
|
|
331
332
|
summary: Rails authentication & authorization with email & password.
|