J
Jane
I am ASP.NET newbie. I am created an application with the flowing login
requirement
if a user incorrectly enters a password, increment the amount of time before
the user is allowed to login again (start with 20 seconds, 60, 180,...) so
the first time someone incorrectly enters their password they wait for 20
seconds, second time 60, ….basically the waiting period triples with each
failed login.
this is what I have for user authentication :
if(!IsUser(UserName.Text,password.Text))
{
// error message
Page.RegisterClientScriptBlock("confirmation", "<script
language='javascript'>alert('Your username
and/or PassPhrase are incorrect. Please retry');</script>");
Response.Redirect("Login.aspx");
}
IsUser( ) authenticates users in the sql database and it works fine.
My problem is:
Since each failed login redirects to a new Login.aspx page, I cannot use a
local variable to hold the amount of time the next waiting period will be
before the user can attempt to login to the app. There has got to be a
simple way of holding this data.
thank you in advance!
requirement
if a user incorrectly enters a password, increment the amount of time before
the user is allowed to login again (start with 20 seconds, 60, 180,...) so
the first time someone incorrectly enters their password they wait for 20
seconds, second time 60, ….basically the waiting period triples with each
failed login.
this is what I have for user authentication :
if(!IsUser(UserName.Text,password.Text))
{
// error message
Page.RegisterClientScriptBlock("confirmation", "<script
language='javascript'>alert('Your username
and/or PassPhrase are incorrect. Please retry');</script>");
Response.Redirect("Login.aspx");
}
IsUser( ) authenticates users in the sql database and it works fine.
My problem is:
Since each failed login redirects to a new Login.aspx page, I cannot use a
local variable to hold the amount of time the next waiting period will be
before the user can attempt to login to the app. There has got to be a
simple way of holding this data.
thank you in advance!