PurposeCommand or Action
Generates RSA key pairs.crypto key generate rsa
Example:
host1(config)# crypto key generate rsa
Step 5
Configures SSH-RSA keys for user and server authentication on the
SSH server and enters public-key configuration mode.
ip ssh pubkey-chain
Example:
host1(config)# ip ssh pubkey-chain
Step 6
Enables the SSH server for public-key authentication on the device
and enters public-key server configuration mode.
server server-name
Example:
host1(conf-ssh-pubkey)# server server1
Step 7
Specifies the RSA public-key of the remote peer and enters public
key data configuration mode.
key-string
Example:
host1(conf-ssh-pubkey-server)#
key-string
Step 8
You can obtain the public key value from an open SSH
client; that is, from the .ssh/id_rsa.pub file.
Note
Exits public-key data configuration mode and enters public-key server
configuration mode.
exit
Example:
host1(conf-ssh-pubkey-data)# exit
Step 9
(Optional) Specifies the SSH key type and version.
key-hash key-type key-name
Step 10
Example:
host1(conf-ssh-pubkey-server)# key-hash
ssh-rsa key1
•
The key type must be ssh-rsa for the configuration of
private/public key pairs.
•
This step is optional only if the key-string command is
configured.
•
You must configure either the key-string command or the
key-hash command.
You can use a hashing software to compute the hash of the
public key string, or you can copy the hash value from
another Cisco device. Entering the public key data using the
key-string command is the preferred way to enter the public
key data for the first time.
Note
Exits public-key server configuration mode and returns to privileged
EXEC mode.
end
Example:
host1(conf-ssh-pubkey-server)# end
Step 11
Consolidated Platform Configuration Guide, Cisco IOS Release 15.2(4)E (Catalyst 2960-X Switches)
1099
How to Configure Secure Shell Version 2 Support