yeahh all the retour du gars qui a toujours des problemes en perl mdr
Alors en fait j'ai fais avec un pote un prog qui recup les proxy d'une page web.Mon but apres ca est d'implementer les reponses dans un cadre tout propre de perl tk.
Donc j'ai fais un sous programme qui appel le RecupProxy j'ai fais l'affichage mais j'ai une erreur.
Voici la source
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
 
#!/usr/bin/perl -w        
# Greetz CodeursSoH   
#                                
################
 
####DECLAR####
use Tk;
use tk::Balloon;
use Tk::Dialog;
use Tk::NoteBook;
$host ="";
$coche =0;
use IO::Socket;
$url = "www.samair.ru";
##############
 
####SUB####
sub Quit {
$quitfen = $fenetre -> Dialog (
                -title => 'Quitter',
                -text => 'Voulez vous quittez petit H4x0r ?',
                -bitmap => 'question',
                -default_button => 'Oui' ,
                -buttons => [ 'Oui','Non' ] );
    $rep = $quitfen -> Show ();
    if ($rep eq 'Oui')
    {
        exit ( 0 ) ;
    }
}
sub Get {   
$socket = IO::Socket::INET->new( Proto => "tcp",    
			         PeerAddr => "$url",   
				 PeerPort => "80");     
print $socket "GET /proxy/index.php HTTP/1.1\nHost: $url:80\nConnection: Close\n\n";
while (my $ligne = <$socket>){
if ($ligne =~ /(\d+).(\d+).(\d+).(\d+):(\S+)/gi) {
print ("ip: $1.$2.$3.$4 port: $5\n");
}
else {
}
}
}
###########
 
$fenetre = new MainWindow ();
$fenetre -> title ("Scan proxy By Nickname");
$bienvenue = $fenetre -> Label ( -text => "Entrez l'host ci dessous");
$bienvenue -> pack ();
$urla = $fenetre -> Entry  (  -textvariable => \$host);
$urla -> pack();
$clic = $fenetre -> Checkbutton (  -text => "Utilisation d'un proxy",
                                   -variable => \$coche);
$clic -> pack();
$quit = $fenetre -> Button (  -text => 'Quit',
		              -command => \&Quit,
			      -underline => 0)
			      -> pack ( -side => 'right' , -padx => 20);
$infoquit = $fenetre -> Balloon ();
$infoquit -> attach ($quit, -balloonmsg => 'Cliquer ici pour quitter',
                            -state => 'balloon');
$scan = $fenetre -> Button (  -text => 'Scan',
			      -underline => 0)
			      -> pack ( -side => 'left' , -padx => 20);
$infoscan = $fenetre -> Balloon ();
$infoscan -> attach ($scan, -balloonmsg => 'Cliquer ici pour Scanner les proxy',
                            -state => 'balloon');
$fenetre -> bind ("<Alt-Key-q>",\&Quit);
 
$img = $fenetre -> Label ( -bitmap => '@/perl/site/lib/tk/Tk.xbm');
$img -> pack ();
 
$texte = $fenetre -> Scrolled (  'Text',
                                 -scrollbars => 'se' , 
                                 -width => 10 , -height => 10 , -tabs => [ '50' ]);
$texte -> pack ();
@bla = &Get;
foreach $ligne (@bla)
{
    $texte -> insert($ligne);
}
MainLoop ();
#############################
#####MOVE YOUR BODY YEAH########
##########NICKNAME###########
############PERL#############
#############IS#############
##########FABULOUS###########
############################
et l'erreur:
wrong # args: should be ".frame.text insert index chars ?tagList chars tagList .
..?" at C:/Perl/site/lib/Tk.pm line 247, <GEN0> line 419.
Si une personne peut me venir en aide ca serai cool merci a tous 8)