MIT licensed by John Lenz, Felipe Lessa
Maintained by Felipe Lessa
This version can be pinned in stack with:yesod-auth-account-fork-2.0.3@sha256:0141c76377d170d0463d669e2fc36f1e49b5440b04001ad801ee0ced5b6f439c,3005

Module documentation for 2.0.3

This package provides a Yesod authentication plugin for accounts. Each account consists of an username, email, and password. When initially creating an account, the email is verified by sending a link in an email. The plugin also supports password reset via email.

The plugin provides default pages implementing all of this functionality, but it has been designed to allow all the pages (new account page, password reset, etc.) to be customized or for the forms to be embedded into your own pages allowing you to just ignore the routes inside the plugin. The details are contained in the haddock documentation.

The plugin supports any form data storage by requiring you to implement a couple of interfaces for data access. The plugin has instances of these interfaces using persistent, but you can create your own implementation if you are not using persistent or want more control over user data access and storage.

A complete working example using persistent is example.hs. Also, see the haddock documentation.

Fork

This is a fork of the yesod-auth-account package with the following additions:

  • Login using either username or e-mail.

  • JSON support for single page applications.

We’d like to merge these changes back upstream but its maintainer has been unresponsive.

Changes

Fork: 1.0

  • Changed into an official fork after being an unofficial one for a long time. An e-mail was sent about this fork to John Lenz on 2015-05-08, but as of 2015-06-01 no reply has been received.

  • Moved to a Git repo on GitHub.

1.4.0

  • Add proper support for i18n:

    • Moved messages into Yesod.Auth.Account.Message module
    • Added renderAccountMessage function to YesodAuthAccount class, which defaults to the english messages.
    • resendVerifyEmailWidget, resetPasswordWidget, newAccountForm, resetPasswordForm, and runAccountPersistDB had their context’s updated with a constraint for YesodAuthAccount db master, which shouldn’t be a problem.
  • Use the nonce package for generating the keys sent in the verification and reset password emails. The nonce package provides efficient and cryptographically secure nonces.

  • Support yesod 1.4 and persistent 2.1 (also bump our version to 1.4 to match yesod)