Phauxth v0.9.0 Phauxth.Confirm
Module to provide user confirmation.
This Plug can be used to provide user confirmation by email, phone, or any other method.
Options
There are two options:
identifier - how the user is identified in the confirmation request
- this should be an atom, and the default is :email
key_validity - the length, in minutes, that the token is valid for
- the default is 60 minutes (1 hour)
Examples
Add the following command to the web/router.ex
file:
get "/update", ConfirmController, :update
Then add the following to the confirm_controller.ex
file:
plug Phauxth.Confirm
Or with options:
plug Phauxth.Confirm, [key_validity: 20]
Summary
Functions
Function to confirm the user by checking the token
Generate a link containing a user-identifier and the confirmation token
Generate a confirmation token
Functions
Generate a link containing a user-identifier and the confirmation token.