Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
0

Set Maximum number of LOG IN failures

Enthusiast ,
May 03, 2007 May 03, 2007

Copy link to clipboard

Copied

I have password protected pages and would like to find a way to limit the number of failed login attempts by a user. Is there code to use. I am using DW 8 in ASP and the 'LOG IN USER' server behavior. I am recording the 'REMOTE_ADDR' server variable and the time-date of the login. Can this help i would like to block a IP address for a set time if more than 3 log in attempts fail. Goto
http://www.gohbcc.com/CallCenter/LOGIN.asp
username; admin
password; 1234
Thanks MikeL7
TOPICS
Server side applications

Views

202
Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
May 03, 2007 May 03, 2007

Copy link to clipboard

Copied

LATEST
Have your login form send users to a second script page....

<form name="form1" method="post" action="secondpage.asp">

... that compares results against the database and adds criteria based on the failed response, and redirecting users appropriately.

rs("LastLogin") = date()
rs("ip") = Request.ServerVariables("REMOTE_HOST")
rs("loginstatus") = "blocked"
rs.Update

You can update fields into that users recordset when they login. Add fields into the DB table as needed (above is just an example of criteria you may wish to capture)

Add the redirects based on your recordset queries

if ip = "" THEN
response.redirect "whereever they are going.asp"
elseif ip = "duplicate ip address" THEN
response.redirect "failed logins .asp"

else
response.redirect "login.asp?err=true"

end if


You can get as fancy or simple as you want. for example, you could have multiple criteria for each response redirect. You just have to make sure you define the variables...

ip = rs("ip")
or
session("name") = rs("name")
etc.

Make sense? Ditch the premade stuff that dreamweaver uses and create your own login scripts.

Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines