ProtocolsSharp SSH fails against FortiSwitch OpenSSH 9.9 after hostkeys-prove request

Resolved

ProtocolsSharp SSH fails against FortiSwitch OpenSSH 9.9 after hostkeys-prove request

avatar

RDM SSH Shell cannot establish an interactive session to multiple FortiSwitches.

Environment:

  • RDM: current version

  • ProtocolsSharp: 2026.10.29.2

  • Client OS: Windows

  • Server SSH: OpenSSH_9.9

  • Authentication: password

Authentication succeeds and the session channel is opened, but the connection stalls immediately after ProtocolsSharp processes the OpenSSH host-key update request:

Received userauth success

User authenticated successfully using password method

Sending session channel open request

Received hostkeys-00@openssh.com request

Sending hostkeys-prove-00@openssh.com request (1 unknown keys)

Received channel open confirmation

Sending pty request

SSH session: The operation was canceled

On a previous attempt ProtocolsSharp also produced:

Devolutions.Protocols.Core.Ssh.DoHostkeys()

Devolutions.Protocols.Core.Ssh.ParseGlobalRequestAsync()

Devolutions.Protocols.Core.Ssh.DispatchPacketAsync()

Devolutions.Protocols.Core.Ssh.ProcessLoopAsync()

The same switch, credentials and client workstation connect successfully using PuTTY.

A clean/new RDM SSH Shell entry reproduces the problem.

Tested without resolution:

  • xterm vs xterm-256color

  • Curve25519 vs sntrup761x25519-sha512@openssh.com

  • ChaCha disabled / AES256-CTR

  • restricted host-key algorithms

  • interactive/password authentication settings

Could you confirm whether ProtocolsSharp has a compatibility issue with hostkeys-00@openssh.com / hostkeys-prove-00@openssh.com, and whether there is a way to disable OpenSSH host-key update/proof handling in RDM?

avatar

Recommended Answer

Hello Albert,

The option to disable SSH host key updates has been implemented and should be available in version 2027.1.1 of RDM.

Best regards,

David Godin

All Comments (9)

avatar

Hello Albert,

Thank you for the detailed report and for all the tests you already ran, it helps a lot.

Your reading of the log is correct. After authentication, the switch sends the OpenSSH "hostkeys-00@openssh.com" announcement. Because one of the keys it announces is not yet in RDM's known hosts file, RDM asks the switch to prove that it owns that key ("hostkeys-prove-00@openssh.com"), and the session stops before the terminal opens. RDM does not have a setting to turn this host key update off, neither in the entry nor in the global SSH options.

To find out whether the switch answers that proof request correctly, could you please send us the following:

1. The exact RDM version (Help > About).

2. The full log of a failed attempt, including the complete exception text that goes with the DoHostkeys() stack trace (the exception type and message above the stack lines).

3. The FortiSwitch model and firmware version.

4. The result of this test with the OpenSSH client built into Windows, from the same workstation. Connect once and accept the key, then connect a second time with:

  ssh -v -o UpdateHostKeys=yes <user>@<switch>

  With -v, OpenSSH shows whether it learned the extra host keys or whether the proof from the switch failed.

In the meantime, could you please try the following? RDM only sends the proof request when the switch announces a key it does not know yet, so if all of the switch's keys are already in RDM's known hosts file, the request should not be sent:

1. Close RDM.

2. From the same workstation, run: ssh-keyscan <switch>

3. Add the lines it returns to this file (by default): %LOCALAPPDATA%\Devolutions\RemoteDesktopManager\known_host

4. Open RDM and connect to the switch again.

Please let us know whether the session opens after that.

Best regards,

Alexis Geller Peiro

avatar

Hi,

I ran the OpenSSH test twice as requested. On the second connection, the existing ED25519 host key was already trusted.

The connection successfully reaches password authentication:

Authenticated to {masked} ([{masked}]:22) using "password".

The failure happens immediately after the switch sends:

debug1: client_input_global_request: rtype hostkeys-00@openssh.com want_reply 0

OpenSSH starts processing the additional host keys:

debug1: client_input_hostkeys: searching C:\Users\{masked}\.ssh\known_hosts for {masked} / (none)

but the remote host then closes the connection:

debug1: channel 0: free: client-session, nchannels 1

Connection to {masked} closed by remote host.

This appears similar to what RDM/ProtocolsSharp is experiencing, although ProtocolsSharp explicitly logs the subsequent:

Sending hostkeys-prove-00@openssh.com request (1 unknown keys)

I also attempted the suggested ssh-keyscan workaround:

ssh-keyscan {masked}

However, no host keys are returned because ssh-keyscan fails with:

choose_kex: unsupported KEX method sntrup761x25519-sha512@openssh.com

 

For that reason, I have not manually modified RDM's known_host file.

Environment:

FortiSwitch model: {masked}

FortiSwitchOS: v7.4.8 build0929

ProtocolsSharp: 2026.10.29.2

Windows OpenSSH: OpenSSH_for_Windows_9.5p2

RDM version: latest

PuTTY still connects successfully to the same target.

Could you advise on the next test, particularly whether there is another supported way to retrieve all server host keys and preload them into RDM's known_host file?

Best regards,
Albert

What I masked

  • Switch IP address → {masked}

  • Windows username/path → {masked}

  • SSH username → {masked}

  • FortiSwitch model → {masked}

  • RDM version → {masked}

avatar

Hello Albert,

Thank you for running these tests, this is very helpful.

The Windows OpenSSH result is important: OpenSSH is also disconnected by the switch at the same step as RDM, right after the hostkeys-00@openssh.com announcement. Since two independent SSH clients fail at the same point, this points to how the FortiSwitch handles the host key update exchange rather than to ProtocolsSharp alone.

To confirm it, could you run the OpenSSH test once more, this time with the host key update disabled?

ssh -vvv -o UpdateHostKeys=no youruser@switch-address

If this one gives you a working shell, the switch is closing the session when the client asks it to prove its additional host keys.

For the known_host workaround, since ssh-keyscan fails on the KEX method, you can collect the keys with ssh itself, one key type at a time. From a Command Prompt:

ssh -o UpdateHostKeys=no -o StrictHostKeyChecking=accept-new -o UserKnownHostsFile=%TEMP%\fsw_keys -o HostKeyAlgorithms=ssh-ed25519 youruser@switch-address

ssh -o UpdateHostKeys=no -o StrictHostKeyChecking=accept-new -o UserKnownHostsFile=%TEMP%\fsw_keys -o HostKeyAlgorithms=rsa-sha2-512 youruser@switch-address

ssh -o UpdateHostKeys=no -o StrictHostKeyChecking=accept-new -o UserKnownHostsFile=%TEMP%\fsw_keys -o HostKeyAlgorithms=ecdsa-sha2-nistp256 youruser@switch-address

OpenSSH saves the key before asking for the password, so you can press Ctrl+C at the password prompt each time. If a command reports that no matching host key type was found, the switch does not have that key type and you can skip it.

Then add the lines from %TEMP%\fsw_keys to RDM's known_host file as described in my previous message, with two additions: make a backup copy of the file first, and use exactly the same host value (name or IP) that RDM already wrote in known_host for this switch.

If the session still fails after that, please send the "-vvv" output of the test above and the RDM log of that attempt with the exception message.

Best regards,

Alexis Geller Peiro

avatar

HHi Alex,

Good news, the workaround worked and I can now connect to the FortiSwitch successfully from RDM.

The UpdateHostKeys=no test with Windows OpenSSH also worked and opened the switch shell normally, which confirmed that the disconnect was triggered by the host key update/proof exchange.

For the RDM workaround, I collected the switch's ED25519 and RSA host keys separately and added the missing RSA key to RDM's known_host file. RDM already had the ED25519 key. After both keys were present, the RDM SSH session opened successfully.

So the issue is resolved from my side without making any changes to the FortiSwitch configuration.

Thanks for pointing me in the right direction and for the detailed troubleshooting steps.

Best regards,

Albert

avatar

Hello Albert,

Thank you for the update, I'm glad the SSH sessions to your FortiSwitches are working again.

For future reference: if the switch ever adds or changes a host key, the same symptom could come back. Adding the new key to RDM's known_host file the same way will fix it.

Please don't hesitate to create a new thread if you need any further assistance.

Best regards,

Alexis Geller Peiro

avatar

Hello Alexis, thank you for the guidance. It actually pains me that I have to do this for another 300 switches :) 

at this point, after decades usage of RDM it seems like I will need to switch to something else :(

avatar

Hello Albert,

Thank you for your feedback, and I completely understand that repeating this on 300 switches is not a reasonable solution.

The root cause is on the switch side, but we are investigating internally to see whether we can do something in RDM so that this situation is handled without any manual changes to the known_host file. I will update you here as soon as I have news.

Best regards,

Alexis Geller Peiro

avatar

Hello Albert,

Good news: after reviewing your case with our SSH developer, we will add an option in RDM equivalent to OpenSSH's "UpdateHostKeys=no". When enabled, RDM will skip the host key update exchange that your FortiSwitches reject, so the sessions will open without having to edit the known_host file on each switch.

I don't have a release date yet, but I will let you know here as soon as it is available and in which RDM version.

Thank you again for your detailed tests, they made it possible to pinpoint the cause quickly.

Best regards,

Alexis Geller Peiro

avatar

Hello Albert,

The option to disable SSH host key updates has been implemented and should be available in version 2027.1.1 of RDM.

Best regards,

David Godin