-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Additional password security Contain at least 2 uppercase letters Contain at least 2 lowercase letters Contain at least 2 numbers Contain at least 2 special characters * Make all the specs pass and add pwned gem * Reduce password complexity message, do not use html * Include ui specs * Update password complexity hint * Leftover code, remove
- Loading branch information
Showing
18 changed files
with
140 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# frozen_string_literal: true | ||
|
||
Devise.setup do |config| | ||
# ==> Security Extension | ||
# Configure security extension for devise | ||
|
||
# Should the password expire (e.g 3.months) | ||
# config.expire_password_after = false | ||
|
||
# Need 1 char each of: A-Z, a-z, 0-9, and a punctuation mark or symbol | ||
# You may use "digits" in place of "digit" and "symbols" in place of | ||
# "symbol" based on your preference | ||
config.password_complexity = { digit: 2, lower: 2, symbol: 2, upper: 2 } | ||
|
||
# How many passwords to keep in archive | ||
# config.password_archiving_count = 5 | ||
|
||
# Deny old passwords (true, false, number_of_old_passwords_to_check) | ||
# Examples: | ||
# config.deny_old_passwords = false # allow old passwords | ||
# config.deny_old_passwords = true # will deny all the old passwords | ||
# config.deny_old_passwords = 3 # will deny new passwords that matches with the last 3 passwords | ||
# config.deny_old_passwords = true | ||
|
||
# enable email validation for :secure_validatable. (true, false, validation_options) | ||
# dependency: see https://github.com/devise-security/devise-security/blob/master/README.md#e-mail-validation | ||
config.email_validation = false | ||
|
||
# captcha integration for recover form | ||
# config.captcha_for_recover = true | ||
|
||
# captcha integration for sign up form | ||
# config.captcha_for_sign_up = true | ||
|
||
# captcha integration for sign in form | ||
# config.captcha_for_sign_in = true | ||
|
||
# captcha integration for unlock form | ||
# config.captcha_for_unlock = true | ||
|
||
# captcha integration for confirmation form | ||
# config.captcha_for_confirmation = true | ||
|
||
# Time period for account expiry from last_activity_at | ||
# config.expire_after = 90.days | ||
|
||
# Allow password to equal the email | ||
# config.allow_passwords_equal_to_email = false | ||
|
||
# paranoid_verification will regenerate verification code after failed attempt | ||
# config.paranoid_code_regenerate_after_attempt = 10 | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
en: | ||
errors: | ||
messages: | ||
taken_in_past: 'was used previously.' | ||
equal_to_current_password: 'must be different than the current password.' | ||
equal_to_email: 'must be different than the email.' | ||
password_complexity: | ||
digit: | ||
one: must contain at least one digit | ||
other: must contain at least %{count} digits | ||
lower: | ||
one: must contain at least one lower-case letter | ||
other: must contain at least %{count} lower-case letters | ||
symbol: | ||
one: must contain at least one punctuation mark or symbol | ||
other: must contain at least %{count} punctuation marks or symbols | ||
upper: | ||
one: must contain at least one upper-case letter | ||
other: must contain at least %{count} upper-case letters | ||
devise: | ||
invalid_captcha: 'The captcha input was invalid.' | ||
invalid_security_question: 'The security question answer was invalid.' | ||
paranoid_verify: | ||
code_required: 'Please enter the code our support team provided' | ||
paranoid_verification_code: | ||
updated: Verification code accepted | ||
show: | ||
submit_verification_code: Submit verification code | ||
verification_code: Verification code | ||
submit: Submit | ||
password_expired: | ||
updated: 'Your new password is saved.' | ||
change_required: 'Your password is expired. Please renew your password.' | ||
show: | ||
renew_your_password: Renew your password | ||
current_password: Current password | ||
new_password: New password | ||
new_password_confirmation: Confirm new password | ||
change_my_password: Change my password | ||
failure: | ||
session_limited: 'Your login credentials were used in another browser. Please sign in again to continue in this browser.' | ||
expired: 'Your account has expired due to inactivity. Please contact the site administrator.' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
--- | ||
[email protected]: | ||
password: <%= ENV.fetch('USER_PASSWORD', 'StrongPassword') %> | ||
password: <%= ENV.fetch('USER_PASSWORD', 'StrongPassword12!@') %> | ||
terms_and_conditions_agreed_at: <%= 1.minute.ago %> | ||
|
||
[email protected]: | ||
password: <%= ENV.fetch('USER_PASSWORD', 'StrongPassword') %> | ||
password: <%= ENV.fetch('USER_PASSWORD', 'StrongPassword12!@') %> | ||
terms_and_conditions_agreed_at: <%= 1.minute.ago %> | ||
confirmed_at: <%= 1.minute.ago %> | ||
|
||
[email protected]: | ||
password: <%= ENV.fetch('USER_PASSWORD', 'StrongPassword') %> | ||
password: <%= ENV.fetch('USER_PASSWORD', 'StrongPassword12!@') %> | ||
terms_and_conditions_agreed_at: <%= 1.minute.ago %> | ||
confirmed_at: <%= 1.minute.ago %> | ||
first_name: Demo | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.