WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: ssh kex_exchange_identification  (Read 420 times)

Offline andyj

  • Hero Member
  • *****
  • Posts: 1047
ssh kex_exchange_identification
« on: December 01, 2025, 12:33:39 PM »
I updated a few servers this weekend from TC 15 to TC 16.2 (all 64-bit). On just one of them, when I try to ssh into it I get
Code: [Select]
kex_exchange_identification: read: Connection reset by peer
Connection reset by 192.168.3.4 port 22
Why just one, and why when I revert it back to TC 15 it works fine again?

Offline patrikg

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 801
Re: ssh kex_exchange_identification
« Reply #1 on: December 01, 2025, 01:00:12 PM »
time ?

Offline Paul_123

  • Administrator
  • Hero Member
  • *****
  • Posts: 1453
Re: ssh kex_exchange_identification
« Reply #2 on: December 01, 2025, 01:39:14 PM »
What key algo are you using on that client server combo?   

I forget what version of OpenSSH is in 16.2, but on piCore16, OpenSSH removed DSA keys from support.





Offline andyj

  • Hero Member
  • *****
  • Posts: 1047
Re: ssh kex_exchange_identification
« Reply #3 on: December 01, 2025, 03:07:48 PM »
I switched it back to TC 16 and making no other changes now it works, of course. Thanks for everyone's help!

Offline andyj

  • Hero Member
  • *****
  • Posts: 1047
Re: ssh kex_exchange_identification
« Reply #4 on: December 06, 2025, 12:20:36 PM »
While I'm in this rabbit hole, I noticed that in the openssh extension /usr/local/etc/init.d/openssh has a few references to DSA keys which are no longer supported by ssh-keygen in the same extension. Other than complaining about an unknown key type it starts ok, but for the next time it's updated a clean up is in order.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 12341
Re: ssh kex_exchange_identification
« Reply #5 on: December 06, 2025, 12:39:19 PM »
Hi andyj
Maybe you could post which keys should be removed?
Are there any new keys that should be added?

Offline Paul_123

  • Administrator
  • Hero Member
  • *****
  • Posts: 1453
Re: ssh kex_exchange_identification
« Reply #6 on: December 06, 2025, 12:59:53 PM »
The openssh init.d script needs updated.

This is what I use in piCore  (The line doing ssh-keygen -t dsa ........ was removed)

Code: [Select]
keygen(){
   ssh-keygen -t rsa -N "" -f /usr/local/etc/ssh/ssh_host_rsa_key
   ssh-keygen -t ecdsa -N "" -f /usr/local/etc/ssh/ssh_host_ecdsa_key
   ssh-keygen -t ed25519 -N "" -f /usr/local/etc/ssh/ssh_host_ed25519_key
}

Offline patrikg

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 801
Re: ssh kex_exchange_identification
« Reply #7 on: December 06, 2025, 01:15:07 PM »
Has also seen that the keyfiles being backup with filetool.sh -bv

That reads the .filetool.lst file and what populate that file with the keyfiles ?

Offline Paul_123

  • Administrator
  • Hero Member
  • *****
  • Posts: 1453
Re: ssh kex_exchange_identification
« Reply #8 on: December 06, 2025, 01:24:47 PM »
update your /opt/.filetool.lst to remove the missing keys.

Offline patrikg

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 801
Re: ssh kex_exchange_identification
« Reply #9 on: December 06, 2025, 01:48:36 PM »
update your /opt/.filetool.lst to remove the missing keys.

A was only hinting what to do some changes to ?
Don't know then the .filetool.lst being populated with these files.
Maybe when you install openssh client/server.
In the install script.