Cisco devices SSH autologin
05 Aug 2013Below is a quick expect script that enables you to autologin on Cisco devices with a predefined clear text password by using an OpenSSH client :
#!/usr/bin/expect
set password "yourverycleartextpassword"
spawn ssh [lindex $argv 0] -o PreferredAuthentications=keyboard-interactive,password
expect "Password: "
send "$password\r"
interact
exit