hi @all,

I try to connect to a cisco asa, but I always get an 
paramiko.AuthenticationException.

Here is the code: (I have replaced the IP,User,Passwd with xxx in the code and 
tracebak)


        #!/usr/bin/env python 

        import paramiko 

        ssh = paramiko.SSHClient() 

        ssh.load_system_host_keys() 

        ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy()) 

        ssh.connect('xxx', 22, username='xxx', password='xxx') 

        stdin, stdout, stderr = ssh.exec_command("show version") 

        data = stdout.read.splitlines() 

        for line in data: 
                print line 


Here the Tracebak:

        python test.py 
        Traceback (most recent call last): 
        File "test.py", line 14, in <module> 
         ssh.connect('xxx', 22, username='xxx', password='xxx') 
        File "/usr/lib/python2.6/site-packages/paramiko/client.py", line 327, 
in connect 
         self._auth(username, password, pkey, key_filenames, allow_agent, 
look_for_keys) 
        File "/usr/lib/python2.6/site-packages/paramiko/client.py", line 481, 
in _auth 
         raise saved_exception 
        paramiko.AuthenticationException: Authentication failed.


If I try to connect via linux console and openssh with the same IP, Password 
and user, the connection works without problems.

Can anyone help?
_______________________________________________
paramiko mailing list
paramiko@lag.net
http://www.lag.net/cgi-bin/mailman/listinfo/paramiko

Reply via email to