AlmaLinux9(RHEL9)世代からRHEL6世代にアクセスすると下記エラー
no matching host key type found. Their offer: ssh-rsa,ssh-dss
# vi ~/.ssh/config Host hoge HostKeyAlgorithms ssh-dss,ssh-rsa PubkeyAcceptedKeyTypes +ssh-rsa KexAlgorithms +diffie-hellman-group1-sha1,diffie-hellman-group14-sha1
そして、
error in libcrypto
# update-crypto-policies --set DEFAULT:SHA1 Setting system policy to DEFAULT:SHA1 Note: System-wide crypto policies are applied on application start-up. It is recommended to restart the system for the change of policies to fully take place.
参考
https://www.unix-power.net/networking/alma9-sshclient
鍵長が2048未満1024等だと下記らしい
Bad server host key: Invalid key length
Host hoge RequiredRSASize 1024