cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1576
Views
0
Helpful
4
Replies

how to automate ssh sessions using the public key instead of the password ?

nlariguet
Beginner
Beginner

can anybody tell me how to automate ssh sessions using the public key instead of the password ?

I can login with ssh#2 to the router without any problem.

I previously generated a pair of dedicated keys for ssh such as:

key name: routerSSH ... pair was generated at: 21:46:53 UTC Sep 10 2009
storage device: private-config
usage: signature key
key is not exportable
...

key name: routerSSH ... pair was generated at: 21:47:17 UTC Sep 10 2009
storage device: private-config
usage: encryption key
key is not exportable
...

key name: routerSSH.server ... pair was generated at: 03:33:33 UTC Nov 25 2009
temporary key
usage: encryption key
key is not exportable
...

I understand I need to grab the public key generated on the router, place it somewhere on my workstation telling PuTTY where it is, and then I should be able to login with -l username but without the password right ?

... problem is I don't figure which one is the public key since they the router states: signature, encryption, and temp encryption key ... so which one should I use ?

... just point to a document telling how to because it seems I cannot find it in the IOS configuration guides

1 Accepted Solution

Accepted Solutions

Joe Clarke
Hall of Fame Cisco Employee Hall of Fame Cisco Employee
Hall of Fame Cisco Employee

Public key authentication is not supported with IOS.  That is, you will not be able to login to an IOS device just using a public key.  You will always need to enter your password.

View solution in original post

4 Replies 4

Joe Clarke
Hall of Fame Cisco Employee Hall of Fame Cisco Employee
Hall of Fame Cisco Employee

Public key authentication is not supported with IOS.  That is, you will not be able to login to an IOS device just using a public key.  You will always need to enter your password.

well, at least that explains why I didn't find it on the configuration guides; thanks !

This is only supported in IOS v15:

http://blog.ioshints.info/2009/10/ssh-rsa-authentication-works-in-ios.html

Cheers,

Christian

I wonder if NX-OS supports SSH pub key auth.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Recognize Your Peers