Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Table of Contents

Purpose

...

  • has at least 12 characters long;
  • contains both upper- and lowercase letters, numbers, and letter and numbers (required), special characters (optional)

Must be controlled by regular expression:  ^(?=.*?[a-z][а-яёїієґ])(?=.*?[A-ZА-ЯЁЇIЄҐ])(?=.*?[0-9])(?=.*?[^a-zA-Z]).{8,}\d)


  1. Validate upper, lowercase letter and numbers

In case of error - return 422 error (message: "Password doest does not meet complexity requirements")

Code Block
languageerl
{:error, [{%{
        description: "Password doestdoes not meet complexity requirements",
        params: [],
        rule: :invalid
      }, "$.password"}]}
    2. Validate password length (at least 12 characters long)

In case of error - return 422 error (message: "Password must be at least 12 characters long")

Code Block
languageerl
{:error, [{%{
        description: "Password must be at least 12 characters long",
        params: [],
        rule: :invalid
      }, "$.password"}]}

...

Destination
Source
Description
id
Autogenerated
user_id$.user_idExtract user from token
password$.decrypted_hash
inserted_atTimestamp: now()Get current date-time

3. Not allow to use recently used passwords

...