Dell POWEREDGE M1000E User Manual
Page 1009
Fabric OS Command Reference
981
53-1002746-01
sshUtil
2
To set up SSH public key authentication on a switch for incoming connections:
1.
Generate a private/public key pair on a remote host (accept default directory and file name):
username@remotehost> ssh-keygen -t dsa
Generating public/private dsa key pair.
Enter file in which to save the key \
(/users/home/username/.ssh/id_dsa):
Enter passphrase (empty for no passphrase):passphrase
Enter same passphrase again: passphrase
Your identification has been saved in \
/users/home/username/.ssh/id_dsa.
Your public key has been saved in \
/users/home/username/.ssh/id_dsa.pub.
The key fingerprint is:
3 0:9f:ae:b6:7f:7e:55:e4:b2:7a:51:f0:95:44:5c:d1
2.
Import the public key from the remote host to the local switch:
switch:username> sshutil importpubkey
Enter user name for whom key is imported: username
Enter IP address:Remote host IP Address
Enter remote directory: ~username/.ssh
Enter public key name(must have .pub suffix):id_dsa.pub
Enter login name:username
Password:******
public key is imported successfully.
3.
Connect to switch using remote ssh client with the -i private_key option:
username@remotehost> ssh username@
IP Address
-i id_dsa
IP Address
-i id_dsa
IP
Address
-i id_dsa
To display the imported public keys on a switch:
switch:username> sshutil showpubkeys
Enter user name whose ssh public key is to be displayed: username
user's public keys
ssh-dss AAAAB3NzaC1kc3MAAACBANXuRsJoIA0PFJtGuZVLfqvfSr\
DYPplWuFouOmTcmuNvpTnd+yoZ
u3C/lAu930HLTmhfxeke/NWRIdj2MJS8yTf30a0u4bf9MSNB8Pt453P/+ \
7VHHxNBYsh+Z++Dv1hfcTeb
0s53bdf7jyYSUdj1k+w//sNTaz0DCs0+rimo4l2NAAAAFQDCuHKRctSH \
D8PRYu5Ee1yWCQKT/wAAAIAo
AMvr1ooq0JVXmXfd0VKcC7AImzFYgRa/FOxZBe4JDkCAXztFk5wnAFy \
UbyTWEoC955mkYGqZRydMrSNM
9wLCAf2DTxXxuHFujA1REL5NGdZqRWo2Sk5HLkYQQYM1w9r9vfK \
QnFH3wYsnHV2sq7+tyRlXfwE416ee
chdwWVpmjgAAAIEAqxcaE1vY4o/cBq1Py62lPaZTcfOHS3jjdKgSO \
BKPCCVeNyx4gxnmqvihtyroeWAY
dBDK4CFgyhut16a/QmdFjn6iyiNR2SGV7X9xqkjPN8H4EhIPXGxoD \
VOfY1Vdt3V3KUxVeEI+vTBI2KJd
PmmLfyEKZqCHOlwBx+HuuZP2BnU= username@host
To delete all imported public keys for a single user:
switch:username> sshutil delpubkeys
Enter user name for whom ssh public key is to deleted \
or all for all users:username
WARNING: It deletes all the ssh public keys for user. \
Do you want to proceed(Yes or No, default is No)?yes
ssh public keys associated to username are deleted.