Predictions 4.10.0.0

hirondelle.predict.pub.lostpassword
Class LostPasswordAction

Object
  extended by ActionImpl
      extended by ActionTemplateShowAndApply
          extended by hirondelle.predict.pub.lostpassword.LostPasswordAction
All Implemented Interfaces:
Action

public final class LostPasswordAction
extends ActionTemplateShowAndApply

First step in recovering a lost password.

The second step is implemented by ResetPasswordAction.

The user inputs their email address into a form. Then, this action will send an email to the given email address. The owner of that email address will receive an email containing a special link, which will take them to a second form.

The special link will contain a one-off "nonce" value, whose value will populate a hidden variable in the second form. This nonce value amounts to a handshake between the server and the owner of the given email address. The nonce value is attached to the user account having the given email address, and is valid only for a limited time.

View : SQL Statements :

Field Summary
static RequestParameter CAPTCHA_CHALLENGE
           
static RequestParameter CAPTCHA_RESPONSE
           
static RequestParameter EMAIL
           
static SqlId FETCH_PARTIAL_USER
           
static SqlId SET_TEMP_PASSWORD_NONCE
           
 
Fields inherited from class ActionTemplateShowAndApply
SUPPORTED_OPERATION
 
Fields inherited from class ActionImpl
DATA, ERRORS, ITEM_FOR_EDIT, ITEMS_FOR_LISTING, MESSAGES, USER_ID
 
Constructor Summary
LostPasswordAction(RequestParser aRequestParser)
          Constructor.
 
Method Summary
protected  void apply()
          Send an email to the given email address, containing a link allowing the user to reset their password.
protected  void show()
          Show an empty form, with no prepopulation.
protected  void validateUserInput()
          Check that user input can build a LostPassword object.
 
Methods inherited from class ActionTemplateShowAndApply
execute
 
Methods inherited from class ActionImpl
addError, addError, addError, addMessage, addMessage, addToRequest, addToSession, copyFromSessionToRequest, createSessionAndCsrfToken, endSession, getErrors, getExistingSession, getFromSession, getIdParam, getIdParams, getLocale, getLoggedInUserName, getMessages, getOperation, getOrderBy, getParam, getParamUnsafe, getRequestParser, getResponsePage, getTimeZone, getUserId, hasErrors, removeFromSession, setResponsePage
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SET_TEMP_PASSWORD_NONCE

public static final SqlId SET_TEMP_PASSWORD_NONCE

FETCH_PARTIAL_USER

public static final SqlId FETCH_PARTIAL_USER

EMAIL

public static final RequestParameter EMAIL

CAPTCHA_CHALLENGE

public static final RequestParameter CAPTCHA_CHALLENGE

CAPTCHA_RESPONSE

public static final RequestParameter CAPTCHA_RESPONSE
Constructor Detail

LostPasswordAction

public LostPasswordAction(RequestParser aRequestParser)
Constructor.

Method Detail

show

protected void show()
             throws DAOException
Show an empty form, with no prepopulation.

Specified by:
show in class ActionTemplateShowAndApply
Throws:
DAOException

validateUserInput

protected void validateUserInput()
Check that user input can build a LostPassword object.

Specified by:
validateUserInput in class ActionTemplateShowAndApply

apply

protected void apply()
              throws AppException
Send an email to the given email address, containing a link allowing the user to reset their password.

If the given email address is not in the database, then show an error message.

Specified by:
apply in class ActionTemplateShowAndApply
Throws:
AppException

Predictions 4.10.0.0

Copyright Hirondelle Systems - Generated 2013Oct19.12.27