当前位置: 首页 > 图文教程 > 网络编程 > ASP > 编写一个asp代码执行器

ASP
remote script文档(转载自微软)(八)
不能ASP图像组件来生成图像的ASP计数器程序(二)
不能ASP图像组件来生成图像的ASP计数器程序(三)
用ASP发送邮件
用ASP进行网络打印功能
用ASP实现号码转换
如何用ASP创建日志文件
二十八条改善 ASP 性能和外观的技巧(1-7)
二十八条改善 ASP 性能和外观的技巧(8-14)
二十八条改善 ASP 性能和外观的技巧(15-21)
二十八条改善 ASP 性能和外观的技巧(22-28)
asp实现在web中显示电子表格数据(一)显示数据表格的应用
asp实现在web中显示电子表格数据(二)生成HTML表格
asp实现在web中显示电子表格数据(三)创建数据表列表和名字范围
asp实现在web中显示电子表格数据(四)创建文件选择列表
Carello Web 使 ASP 源码暴露 (APP,缺陷)
MS IIS虚拟主机ASP源码泄露 (MS,缺陷)
虚拟web目录容易泄露ASP源代码 (MS,缺陷)
MS IIS server的ASP安全缺陷 (MS,缺陷)
用WinSock设计Chat程序(转)

ASP 中的 编写一个asp代码执行器


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-11-03   浏览: 48 ::
收藏到网摘: n/a

 

保存为runasp.asp运行。账号密码admin,登陆后输入代码就可执行了!!

<% @ LANGUAGE="VBSCRIPT" %>
<%Option Explicit
response.buffer=true
dim Spassword,SUserName
    SUserName="admin"
    Spassword="admin"
dim SQLMutiStr
dim i
dim action
    action=request.querystring("action")

IF action="GetCode" then '---------TOT
    NumCodeJS
ELSE '--------TOT
    Response.Write("<!DOCTYPE HTML PUBLIC ""-//W3C//DTD HTML 4.0 Transitional//EN"">")
    Response.Write("<HTML>")
    Response.Write("<HEAD>")
    Response.Write("<TITLE>ASP RunCode SCR V1.0 / Create By PaintBlue.Net V37</TITLE>")
    Response.Write("<META NAME=""Generator"" CONTENT=""EditPlus,V37,PaintBlue.Net"">")
    Response.Write("<META NAME=""Author"" CONTENT=""V37,PaintBlue.Net"">")
    Response.Write("<META NAME=""Keywords"" CONTENT=""PaintBlue.Net,,V37,RunCode,ASP,Script,BlueIdea.COM,Lfgbox.com"">")
    Response.Write("<META NAME=""Description"" CONTENT=""运行ASP代码的ASP脚本!"">")
    Response.Write("</HEAD>")
    Response.Write("<BODY bgcolor=#D4D0C8>")

    SQLMutiStr=trim(Request.Form("SQLMutiStr"))
    if session("login")="" and action="chkpass" then
        session("login")=checkPass()
    end if
    if action="exit" then session("login")=""
    if session("login")="1" then
            if action="RunCode" then 
                if SQLMutiStr="" then
                    Response.write "没有输入要运行的代码!"
                    Response.write "<br><br><a href=""javascript:window.history.back();"">返回运行页面</a><br><br>"
                    Response.write "<a href=""?action=exit"">退出登陆</a>"
                    response.end
                else
                    dim ExeStrArr
                    dim re
                    dim tempSQL,tempSQL2
                        dim ScriptArr,ScriptSubArr
                        tempSQL2=""
                    tempSQL=split(SQLMutiStr,vbcrlf)
                    if inStr(lcase(tempSQL(0)),"language")>0 then
                        tempSQL2=tempSQL(1)
                 &n