authentication-zero 3.0.0 → 3.0.2
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/CHANGELOG.md +4 -0
- data/Gemfile.lock +1 -1
- data/lib/authentication_zero/version.rb +1 -1
- data/lib/generators/authentication/templates/models/user.rb.tt +7 -2
- data/lib/generators/authentication/templates/test_unit/controllers/html/identity/emails_controller_test.rb.tt +2 -2
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c60a566c4789323eb87ac9f024b732231815e76092b5187d608ddc6a21314427
|
4
|
+
data.tar.gz: fccefad83e73b9fe383949f756cf2ad363372472a7d5a362f5e04a99ea75fefa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b4a4a9bf9a05f73b0fcc4862d763fb3a4880563fbec72a3f069d7b7e56dbc4dee3c8812823c2569d7e680a4c49b86e61465191cfbd0b24a2a121ba49ab61ec37
|
7
|
+
data.tar.gz: b73ed9438ecbb4a9afa463195ca88d735084853044c8d59b6f649157302aefa171ed0a6d421267c2acbe909cabe0993fdf3b81da3a68e5a654e2e82a99d1549c
|
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,8 +1,13 @@
|
|
1
1
|
class User < ApplicationRecord
|
2
2
|
has_secure_password
|
3
3
|
|
4
|
-
generates_token_for :email_verification, expires_in: 2.days
|
5
|
-
|
4
|
+
generates_token_for :email_verification, expires_in: 2.days do
|
5
|
+
email
|
6
|
+
end
|
7
|
+
generates_token_for :password_reset, expires_in: 20.minutes do
|
8
|
+
password_salt.last(10)
|
9
|
+
end
|
10
|
+
|
6
11
|
<%- if options.tenantable? %>
|
7
12
|
belongs_to :account
|
8
13
|
<%- end -%>
|
@@ -16,8 +16,8 @@ class Identity::EmailsControllerTest < ActionDispatch::IntegrationTest
|
|
16
16
|
end
|
17
17
|
|
18
18
|
|
19
|
-
test "should not update
|
20
|
-
patch
|
19
|
+
test "should not update email with wrong password challenge" do
|
20
|
+
patch identity_email_url, params: { email: "new_email@hey.com", password_challenge: "SecretWrong1*3" }
|
21
21
|
|
22
22
|
assert_response :unprocessable_entity
|
23
23
|
assert_select "li", /Password challenge is invalid/
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: authentication-zero
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.0.
|
4
|
+
version: 3.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nixon
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-10-
|
11
|
+
date: 2023-10-28 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description:
|
14
14
|
email:
|
@@ -156,7 +156,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
156
156
|
- !ruby/object:Gem::Version
|
157
157
|
version: '0'
|
158
158
|
requirements: []
|
159
|
-
rubygems_version: 3.4.
|
159
|
+
rubygems_version: 3.4.20
|
160
160
|
signing_key:
|
161
161
|
specification_version: 4
|
162
162
|
summary: An authentication system generator for Rails applications
|