aspose file tools
The moose likes JSP and the fly likes Implement forgot password Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » JSP
Reply Bookmark "Implement forgot password" Watch "Implement forgot password" New topic
Author

Implement forgot password

ravisha andar
Ranch Hand

Joined: Feb 25, 2011
Posts: 55
Hi All i want to implement forgot password by

Sending an email to the customers id
This link should be one time used and short lived.
The link should also have a andom token associated with it.
Once the user clicks resets the password the link should no longer be useful.


How do I implement this?

A sample code or link would help me a lot.


Thanks


Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 56185
    
  13

What have you thought of so far? You need to put some effort into this if you want help.


[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
mohana krishna
Greenhorn

Joined: Apr 12, 2005
Posts: 8
1 ) Create a token and store token number and created time in the table.
2) In the link add token as parameter
3 ) When user clicks on the link you check the difference between current time and token created time. If its more than the predefined time iterval show valid erro message to user.
4) Otherwise do a soft delete of the token frm the database.

Dear ranchers if there is any better please provide info
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19216

You have to ensure that the token is unique though.


SCJP 1.4 - SCJP 6 - SCWCD 5
How To Ask Questions How To Answer Questions
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: Implement forgot password
 
Similar Threads
FBN confusing about design choice
need help with design of a Login page in JSP
URLs in a Portlet
Spring ACEGI Forgot Password implementaion
Forgot admin login ID and password