📄 sqlin.asp
字号:
<!--#include file="../Session.asp"-->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>亿众购物系统--SQL注入日志管理</title>
<link href="../../css/site.css" rel="stylesheet" type="text/css">
</head>
<body>
<%if Request("Act")="Del" then:conn.execute("Delete From SqlIn where id="&request("id")&"")
if Request("Locked")<>"" then
if Request("Locked")=1 then
Locked=0
else
Locked=1
end if
conn.execute("update SqlIn set Locked='"&Locked&"' where id="&request("id")&"")
end if
%>
<table border="0" cellspacing="0" width="100%" cellpadding="1">
<tr>
<td height="50" colspan="9" align="center" class="tdstyle"><strong><font color="#000000" size="3">SQL注入日志</font></strong></td>
</tr>
<tr>
<form name="form1" method="post" action="?">
<td height="30" colspan="9" align="center" class="tdstyle">按IP查询:
<input name="keyword" type="text" class="input1"> <input name="Submit" type="submit" class="button" value="查 询">
</td>
</form>
</tr>
<tr>
<td width="8%" height="25" align="center" class="tdstyle"><strong>编 号</strong></td>
<td width="15%" align="center" class="tdstyle"><strong>锁定IP</strong></td>
<td width="12%" align="center" class="tdstyle"><strong>操作页面</strong></td>
<td width="8%" align="center" class="tdstyle"><strong>提交方式</strong></td>
<td width="12%" align="center" class="tdstyle"><strong>提交参数</strong></td>
<td width="15%" align="center" class="tdstyle"><strong>提交数据</strong></td>
<td width="12%" align="center" class="tdstyle"><strong>操作时间</strong></td>
<td width="8%" align="center" class="tdstyle"><strong>锁 定</strong></td>
<td width="10%" align="center" class="tdstyle"><strong>删 除</strong></td>
</tr>
<%
if request("keyword")<>"" then
sql="select * from SqlIn where IP ='"&trim(request("keyword"))&"' order by id desc"
else
sql="select * from SqlIn order by id desc"
end if
Set rs= Server.CreateObject("ADODB.Recordset")
rs.open sql,conn,1,1
if rs.eof and rs.bof then
response.write "<tr><td height=20 colspan=9 align=center class=text>没有记录 </td></tr>"
response.end
end if
rs.pagesize = 8
if request("page")="" or IsNumeric(request("page"))=False then
page = 1
else
page=int(request("page"))
end if
if page>rs.pagecount then
page=rs.pagecount
end if
if not rs.BOF then
Rs.Move Rs.PageSize*(page-1)
end if
i=1
do while not rs.eof and i<=rs.pagesize%>
<tr>
<td height="20" align="center" class="tdstyle"> <%=rs("Id")%> </td>
<td align="center" class="tdstyle"><%=rs("IP")%></td>
<td align="center" class="tdstyle"><%=rs("Web")%></td>
<td align="center" class="tdstyle"><%=rs("Mode")%></td>
<td align="center" class="tdstyle"><%=rs("Parameter")%></td>
<td align="center" class="tdstyle"><%=rs("Data")%></td>
<td align="center" class="tdstyle"><%=rs("Date")%></td>
<td align="center" class="tdstyle">
<%if rs("Locked")=1 then%>
<input name="submit2" type="button" class="button4" value="是" onClick="if(confirm('警告:您确定要为此记录锁定的IP解锁吗?')) location.href='?Locked=<%=rs("Locked")%>&Id=<%=rs("Id")%>'">
<%else%>
<input name="submit3" type="button" class="button5" value="否" onClick="if(confirm('您确定要锁定该条记录中的IP吗?')) location.href='?Locked=<%=rs("Locked")%>&Id=<%=rs("Id")%>'">
<%end if%>
</td>
<td align="center" class="tdstyle"><input name="B12" type="button" class="button" onclick="if(confirm('警告:删除后会为此记录锁定的IP解锁!\n\n您确定要删除吗 ?')) location.href='?Act=Del&Id=<%=rs("Id")%>'" value="删 除"></td>
</tr>
<%i=i+1
rs.MoveNext
loop %>
<tr align="center">
<form name=form method=get action=?>
<td height="30" colspan="9"class="tdstyle"> <%
if rs.recordcount<>0 then
if page-1 mod 10=0 then
p=(page-1) \ 10
else
p=(page-1) \ 10
end if
response.write "页次:"& page &"/"& rs.pagecount &"页 每页"& rs.pagesize &" 共"& rs.recordcount &"条记录"&_
" 分页:"
if p*10>0 then response.write "<a href='?page="&p*10&"' title=上十页>[<<]</a> "
uming_i=1
for ii=p*10+1 to P*10+10
if ii=page then
response.write "<font color=#ff0000>["+Cstr(ii)+"]</font> "
else
response.write "<a href='?page="&ii&"'>["+Cstr(ii)+"]</a> "
end if
if ii=rs.pagecount then exit for
uming_i=uming_i+1
next
if ii<=rs.pagecount and uming_i=11 then response.write "<a href='?page="&ii&"' title=下十页>[>>]</a> "
response.write(" 跳页:<input type=text name=page size=2 maxlength=3 class=input1> <input type=submit name=Submit value=Go class=button>")
end if
rs.close
set rs=nothing
conn.close
set conn=nothing%> </td>
</form>
</tr>
</table>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -