Forum |  HardWare.fr | News | Articles | PC | S'identifier | S'inscrire | Shop Recherche
1377 connectés 

  FORUM HardWare.fr
  Programmation
  Perl

  Net::SSH::Perl problème d'authentification

 


 Mot :   Pseudo :  
 
Bas de page
Auteur Sujet :

Net::SSH::Perl problème d'authentification

n°1444556
deepcore
Posté le 19-09-2006 à 11:46:38  profilanswer
 

Bonjour à tous.
 
Je suis en train d'écrire un petit script utilisant le module perl Net::SSH. Malheureusement,  je ne dépasse pas l'étape de l'authentification. Quelqu'un pourrait m'aider siou'plait ??
 

Code :
  1. use Net::SSH::Perl;
  2. my $ssh = Net::SSH::Perl->new("XXXXXXX",debug => 1);
  3. $ssh->login("XXXXX", "XXXXXX" );
  4. my($out, $err, $exit) = $ssh->cmd("ls" );
  5. print "$out\n$err\n$exit";


 
Et voila ce que ça donne...

Citation :


SLTSSI01: Remote protocol version 2.0, remote software version OpenSSH_3.9p1 Debian-1ubuntu2.2
SLTSSI01: Net::SSH::Perl Version 1.30, protocol version 2.0.
SLTSSI01: No compat match: OpenSSH_3.9p1 Debian-1ubuntu2.2.
SLTSSI01: Connection established.
SLTSSI01: Sent key-exchange init (KEXINIT), wait response.
SLTSSI01: Algorithms, c->s: 3des-cbc hmac-sha1 none
SLTSSI01: Algorithms, s->c: 3des-cbc hmac-sha1 none
SLTSSI01: Entering Diffie-Hellman Group 1 key exchange.
SLTSSI01: Sent DH public key, waiting for reply.
SLTSSI01: Received host key, type 'ssh-dss'.
SLTSSI01: Host 'localhost' is known and matches the host key.
SLTSSI01: Computing shared secret key.
SLTSSI01: Verifying server signature.
SLTSSI01: Waiting for NEWKEYS message.
SLTSSI01: Enabling incoming encryption/MAC/compression.
SLTSSI01: Send NEWKEYS, enable outgoing encryption/MAC/compression.
SLTSSI01: Sending request for user-authentication service.
SLTSSI01: Service accepted: ssh-userauth.
SLTSSI01: Trying empty user-authentication request.
SLTSSI01: Authentication methods that can continue: publickey,keyboard-interactive.
SLTSSI01: Next method to try is publickey.
Permission denied at testSSH.pl line 12


 
Je ne comprends pas trop le "Trying empty user-authentication request.", j'ai pourtant mis un login et un pass (qui dont bon).


---------------
"Si ça peut déconner, ça va déconner..."
mood
Publicité
Posté le 19-09-2006 à 11:46:38  profilanswer
 

n°1444604
deepcore
Posté le 19-09-2006 à 13:53:35  profilanswer
 

J'ai fait de nouveaux tests. En mettant la methode à "Interactive", le script me demande mon mot de passe (normal après tout) et là, ça marche... :??:


---------------
"Si ça peut déconner, ça va déconner..."

Aller à :
Ajouter une réponse
  FORUM HardWare.fr
  Programmation
  Perl

  Net::SSH::Perl problème d'authentification

 

Sujets relatifs
[wsh]WMI et methode qui ne fonctionne pas[PHP] Probleme de tri d'arrays
probleme de position pour un info bulleProbleme traitement de données
[MING] Problème de rotation d'un objet ( + police TTF > FDB)Visual C++ : Problème d'éxécution
problème de navigation[C#.NET] Repertoire courant du programme, ya un raccourci ?
Probleme avec mon forum PhpBBProblème d'affichage inline !!!
Plus de sujets relatifs à : Net::SSH::Perl problème d'authentification


Copyright © 1997-2022 Hardware.fr SARL (Signaler un contenu illicite / Données personnelles) / Groupe LDLC / Shop HFR