Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

handshake failed: [ssh: no auth passed yet] #17

Open
realyukii opened this issue Feb 24, 2025 · 3 comments
Open

handshake failed: [ssh: no auth passed yet] #17

realyukii opened this issue Feb 24, 2025 · 3 comments

Comments

@realyukii
Copy link

I tried the following on the ssh client:

$ ssh localhost hemlo
Unable to negotiate with 127.0.0.1 port 22: no matching host key type found. Their offer: ssh-rsa

and on the sshfront:

sudo ./sshfront -a "" -d -h 127.0.0.1 `which echo`
2025/02/25 04:16:58 host key file error: open ~/.ssh/id_rsa: no such file or directory
2025/02/25 04:16:58 no host key provided, generating host key
2025/02/25 04:16:58 sshfront v0.2.1 listening on 127.0.0.1:22 ...
2025/02/25 04:17:10 handshake failed: ssh: no common algorithm for host key; client offered: [[email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] ssh-ed25519 ecdsa-sha2-nistp256 ecdsa-sha2-nistp384 ecdsa-sha2-nistp521 [email protected] [email protected] rsa-sha2-512 rsa-sha2-256], server offered: [ssh-rsa]

whether the ssh username is set or not, it still shows the same error

@realyukii
Copy link
Author

realyukii commented Feb 24, 2025

now the error message changed:

$ ssh -o PubkeyAcceptedAlgorithms=+ssh-rsa -o HostkeyAlgorithms=+ssh-rsa localhost hemlo
ssh_dispatch_run_fatal: Connection to 127.0.0.1 port 22: Invalid key length
$ ssh -V
OpenSSH_9.9p2, OpenSSL 3.4.1 11 Feb 2025

found the option on stackoverflow

@realyukii realyukii changed the title how to allow all user? invalid key length Feb 24, 2025
@realyukii
Copy link
Author

realyukii commented Feb 24, 2025

Oh, I'm sorry, I didn't notice the sshfront I use is from 2016 (v0.2.1), I guess I need to build it from source

@realyukii
Copy link
Author

the error message changed:

$ sudo ./sshfront -a "" -d -h 127.0.0.1 `which echo`
<...>
2025/02/25 05:02:51 handshake failed: [ssh: no auth passed yet]

it still require authentication despite I set -a ""? :"

$ ssh -o PubkeyAcceptedAlgorithms=+ssh-rsa -o HostkeyAlgorithms=+ssh-rsa localhost hemlo
ryuzaki@localhost: Permission denied (publickey).

@realyukii realyukii changed the title invalid key length Permission denied (publickey). Feb 24, 2025
@realyukii realyukii changed the title Permission denied (publickey). handshake failed: [ssh: no auth passed yet] Feb 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant