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


Tema destacado: Suscripción al boletín mensual de elhacker.net

+  Foro de elhacker.net
|-+  Programación
| |-+  Scripting (Moderadores: Novlucker, Leo Gutiérrez., EleKtro H@cker)
| | |-+  [Perl] Manager
0 Usuarios y 1 Visitante están viendo este tema.
Páginas: [1] Ir Abajo Respuesta Imprimir
Autor Tema: [Perl] Manager  (Leído 115 veces)
Doddy

Desconectado Desconectado

Mensajes: 220



Ver Perfil
[Perl] Manager
« en: 9 Octubre 2011, 17:50 »

Bueno , aca les traigo un programa que los ayudara a listar todos los
procesos y cerrar el que quieran
En esta version podran tener una interfaz grafica

Código
#!usr/bin/perl
#Manager (C) Doddy Hackman 2010
#Module neccesary
#ppm install http://trouchelle.com/ppm/Win32-Process-List.ppd
 
use Win32::Process::List;
use Win32::Process;
use Tk;
 
if ($^O eq 'MSWin32') {
use Win32::Console;
Win32::Console::Free();
}
 
$new = MainWindow->new(-background=>"black");
$new->geometry("250x300+20+20");
$new->resizable(0,0);
$new->title("Manager 0.1");
$new->Label(-background=>"black",-foreground=>"green",-font=>"Impact",-text=>"Process")->pack();
my $lists = $new->Listbox(-background=>"black",-foreground=>"green")->place(-y=>"50",-x=>"60");
$new->Button(-background=>"black",-foreground=>"green",-text=>"Close",-activebackground=>"green",-width=>"40",-command=>\&close)->place(-y=>"218");
$new->Button(-background=>"black",-foreground=>"green",-text=>"Refresh",-width=>"40",-activebackground=>"green",-command=>\&refresh)->place(-y=>"240");
$new->Button(-background=>"black",-foreground=>"green",-text=>"About",-width=>"40",-activebackground=>"green",-command=>\&about)->place(-y=>"263");
 
&refresh;
 
MainLoop;
 
 
sub refresh {
 
my @pids;
my @procer;
my $limit;
 
$lists->delete(0.0,"end");
 
my $new = Win32::Process::List->new();  
my %process = $new->GetProcesses();
my $limit = -1;
for my $pid (keys %process) {
$limit++;
push (@procer,$process{$pid});
push (@pids,$pid);
}
print "\n\n[+] ".int(@procer)."\n\n";
for my $n(0..$limit) {
print $procer[$n]."\n";
$lists->insert("end",$procer[$n]);
}
 
 
}
 
sub close {
 
$d = $lists->curselection();
 
for my $id (@$d) {
 
my $proceso = $lists->get($id);
 
my $pida = Win32::Process::List->new();
my @pid = $pida->GetProcessPid($proceso);
 
Win32::Process::KillProcess(@pid[1],$proceso);
sleep 3;
&refresh();
}
}
 
 
 
sub about {
$about = MainWindow->new(-background=>"black");
$about->title("About");
$about->geometry("150x100+20+20");
$about->resizable(0,0);
$about->Label(-background=>"black",-foreground=>"green",-font=>"Impact",-text=>"Coded By Doddy H")->pack();
$about->Label(-background=>"black",-foreground=>"green")->pack();
$about->Label(-background=>"black",-foreground=>"green",-font=>"Impact",-text=>"2011")->pack();
}
 
 
 
# ¿ The End ?
 
 


En línea

Páginas: [1] Ir Arriba Respuesta Imprimir 

Ir a:  

Mensajes similares
Asunto Iniciado por Respuestas Vistas Último mensaje
Facebook Manager [ Perl ]
Scripting
Leo Gutiérrez. 0 618 Último mensaje 31 Diciembre 2010, 00:45
por Leo Gutiérrez.
[Perl] FSD Exploit Manager
Scripting
Doddy 0 336 Último mensaje 7 Octubre 2011, 01:14
por Doddy
[Perl] Mysql Manager
Scripting
Doddy 0 136 Último mensaje 7 Octubre 2011, 01:14
por Doddy
[Perl] FTP Manager
Scripting
Doddy 0 143 Último mensaje 14 Octubre 2011, 15:25
por Doddy
[Perl] USB Manager 0.2
Scripting
Doddy 0 208 Último mensaje 3 Diciembre 2011, 16:34
por Doddy
Powered by SMF 1.1.16 | SMF © 2006-2008, Simple Machines