Bug 459597

Summary: kio_sftp fails to pick up HostKeyAlgorithms from ~/.ssh/config
Product: [Frameworks and Libraries] kio-extras Reporter: Jan <medhefgo>
Component: SFTPAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED UPSTREAM    
Severity: normal CC: fabian, null, zawertun
Priority: NOR    
Version First Reported In: 22.08.1   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Jan 2022-09-24 11:11:49 UTC
kio_sftp does not pick up HostKeyAlgorithms from ssh config file.

STEPS TO REPRODUCE
1. Append "HostKeyAlgorithms ssh-rsa" to /etc/ssh/sshd_config
2. systemctl start sshd
3. Append "Host 127.0.0.1" and "HostKeyAlgorithms +ssh-rsa" to ~/.ssh/config
4. "ssh 127.0.0.1" works and gives me a password prompt
5. "kioclient ls sftp://127.0.0.1" gives this error:
> kioclient: kex error : no match for method server host key algo: server [ssh-rsa], client [rsa-sha2-512,rsa-sha2-256,ssh-ed25519,ecdsa-sha2-nistp521,ecdsa-sha2-nistp384,ecdsa-sha2-nistp256]
Comment 1 Fabian Vogt 2022-10-01 15:42:37 UTC
The "+" syntax is not implemented in libssh (yet): https://gitlab.com/libssh/libssh-mirror/-/issues/63