1 Rookie
•
4 Posts
0
92
Dell S4810 SSH RSA Authentication - Error reading host key file
Hello,
When trying to read a file containing a valid rsa key, FTOS claims it's invalid:
f10a(conf)#ip ssh pub-key-file sshkey.pub
% Error: No valid host key(s) found
OS version is 9.14(1.14)
Any tip would be truly appreciated.
Kind regards.
DELL-Charles R
Moderator
Moderator
•
3.7K Posts
0
February 20th, 2024 18:25
Hello,
You indicated you used this
f10a(conf)#ip ssh pub-key-file https://dell.to/3uEXOX4
Try this but not in conf mode:
f10a#ip ssh rsa-authentication ?
my-authorized-keys Add authorized keys
username Establish user name for RSA Key
f10a#ip ssh rsa-authentication my-authorized-keys ?
WORD File name for RSA authorized-keys
f10a#ip ssh rsa-authentication my-authorized-keys https://dell.to/3uEXOX4
DELL-Erman O
Moderator
Moderator
•
2.5K Posts
0
February 19th, 2024 08:48
Hello, error message you’re seeing typically occurs when the SSH client cannot verify the host key of the server. It's hard to say what is the main reason. you may need to remove the old host key information from your
known_hosts
file on your client machine. This file stores the host keys of the servers you have connected to before, and may cause a conflict if the host key of the server has changed. You can use thessh-keygen -R hostname -f /home/user/.ssh/known_hosts
command to remove the old host key for a specific hostnameHope that helps!
ddnet
1 Rookie
1 Rookie
•
4 Posts
0
February 19th, 2024 21:31
@DELL-Erman O Hello Dell-erman, thanks for your answer. The problem is that I can not tell the switch which is my client id-rsa.pub.
As per what I understand from the user reference the way to do it is downloading the file to the switch and then executing "ip ssh pub-key-file <file-name-containing-the-key>". Is is wrong? Is there any other way to tell the switch which is my public ssh key? (Something equivalent to when I put the my key on the authorized_keys file on a server ...)
Thanks a lot in advance.
Best regards.
(edited)
DELL-Joey C
Moderator
Moderator
•
3.4K Posts
0
February 20th, 2024 09:29
Hi,
Just to confirm, you have followed the instruction here to create the file for binding? https://dell.to/4bKlquc
ddnet
1 Rookie
1 Rookie
•
4 Posts
0
February 20th, 2024 16:15
Hi,
Those steps refer to host based authentication, what I'm looking for is RSA based authentication whose instructions are in https://www.dell.com/support/manuals/en-us/dell-emc-os-9/s4048-on-9.14.2.6-config-pub/using-rsa-authentication-of-ssh?guid=guid-c6580e5b-9cf4-4791-aa5f-eefb3188109b&lang=en-us
A couple of details happen. My switch is not "-ON" system. OS version is 9.14(1.14) not 9.14.2.2, and some of the command mentioned on that link are not existent on my switch, like:
ip ssh rsa-authentication username username my-authorized-keys flash://public_key
Command "ip ssh rsa-authentication" only accept "enable" nothing more.
May my switch and OS version is related to this problem?
If so, is there any way to activate RSA authentication on my deployment?
# show version:
Dell Real Time Operating System Software
Dell Operating System Version: 2.0
Dell Application Software Version: 9.14(1.14)
Copyright (c) 1999-2018 by Dell Inc. All Rights Reserved.
Build Time: Tue Oct 25 11:14:28 2022
Build Path: /neteng/build/clones/coveritybuild-eqx-05/build/build02/SW/SRC
Dell Networking OS uptime is 28 minute(s)
System image file is "system://A"
System Type: S4810
Control Processor: Freescale QorIQ P2020 with 2 Gbytes (2147483648 bytes) of memory, core(s) 1.
128M bytes of boot flash memory.
1 52-port GE/TE/FG (SE)
48 Ten GigabitEthernet/IEEE 802.3 interface(s)
4 Forty GigabitEthernet/IEEE 802.3 interface(s)
Thank a lot!
(edited)
ddnet
1 Rookie
1 Rookie
•
4 Posts
0
February 23rd, 2024 19:16
Hello Charles,
Yes indeed, it works great. My mistake, I wasn't in EXEC mode, sorry.
In such case, can you please clarify what is f10a(conf)#ip ssh pub-key-file <filename> used for?
Thank you so much.
DELL-Charles R
Moderator
Moderator
•
3.7K Posts
0
February 23rd, 2024 20:32
Hello,
I saw that you had used that.
I just think you were running it in the wrong mode.
Glad to see you got it resolved.