Comments (7)
Hi @MoskalykA ,
Is it okay to show your codes here and provide env info such as the version of ssh-server and target OS.
Also, cloud you provide the log with ssh::is_enable_log(true);
on?
BRs.
from ssh-rs.
You can also check if your server's sshd_config has password login disabled.
vim /etc/ssh/sshd_config
PasswordAuthentication no
PubkeyAuthentication yes
from ssh-rs.
/etc/ssh/sshd_config
SSH Version: OpenSSH_9.0p1 Ubuntu-1ubuntu7, OpenSSL 3.0.5 5 Jul 2022
OS: Ubuntu 22.10
Logs:
[SSH]-[INFO]: prepare for version negotiation.
[SSH]-[INFO]: server version: [SSH-2.0-OpenSSH_9.0p1 Ubuntu-1ubuntu7]
[SSH]-[INFO]: client version: [SSH-2.0-SSH_RS-0.2.1]
[SSH]-[INFO]: version negotiation was successful.
[SSH]-[INFO]: prepare for key negotiation.
[SSH]-[INFO]: client algorithms: ["curve25519-sha256,ecdh-sha2-nistp256","ssh-ed25519,ssh-rsa","[email protected],aes128-ctr","[email protected],aes128-ctr","hmac-sha1","hmac-sha1","none","none"]
[SSH]-[INFO]: server algorithms: ["[email protected],curve25519-sha256,[email protected],ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group16-sha512,diffie-hellman-group18-sha512,diffie-hellman-group14-sha256","rsa-sha2-512,rsa-sha2-256,ecdsa-sha2-nistp256,ssh-ed25519","[email protected],aes128-ctr,aes192-ctr,aes256-ctr,[email protected],[email protected]","[email protected],aes128-ctr,aes192-ctr,aes256-ctr,[email protected],[email protected]","[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-sha1","[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-sha1","none,[email protected]","none,[email protected]"]
[SSH]-[INFO]: signature verification success.
[SSH]-[INFO]: send new keys
[SSH]-[INFO]: key negotiation successful.
[SSH]-[INFO]: public key authentication.
[SSH]-[ERROR]: user auth failure.
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Error: { Kind(SshError("user auth failure, auth type is password.")), Message(user auth failure, auth type is password.) }', src\main.rs:114:42
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
[SSH]-[TRACE]: returning
[SSH]-[TRACE]: event Readable Token(4194303)
[SSH]-[TRACE]: loop process - 1 events, 0.000s
from ssh-rs.
You can also check if your server's sshd_config has password login disabled.
vim /etc/ssh/sshd_config PasswordAuthentication no PubkeyAuthentication yes
This does not work
from ssh-rs.
However, with these versions, it works:
OS: Ubuntu 20.04.4 LTS
SSH: OpenSSH_8.2p1 Ubuntu-4ubuntu0.5, OpenSSL 1.1.1f 31 Mar 2020
from ssh-rs.
Hi @MoskalykA
Please add the following line to your sshd_config and test again
pubkeyacceptedalgorithms ssh-rsa
Or you can add the default algorithm list listed in sshd -T | grep pubkeyacceptedalgorithms
pubkeyacceptedalgorithms [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
and then append ssh-rsa
to this line
BRs.
from ssh-rs.
According to the changlog from OpenSSH 8.7
Imminent deprecation notice
===========================
OpenSSH will disable the ssh-rsa signature scheme by default in the
next release.
from ssh-rs.
Related Issues (20)
- 是否可以在登录的时候设置StrictHostKeyChecking属性? HOT 8
- 增加任务状态的建议 HOT 1
- How to obtain SshError HOT 8
- Only captures stdout HOT 2
- add more encryption algorithms HOT 3
- Bump ssh-key crate version HOT 4
- `tracing` dependency is not new enough
- Ssh-rs panic on a thread when using in multi threading HOT 4
- Error when connecting to older ExtremeXOS switch HOT 1
- 能否支持一边读取命令执行结果一遍输出,而不是等到整个命令完全执行完毕再输出所有的结果? HOT 1
- ssh -rs crashed on Zero lenght version information HOT 4
- Use Rust std TCP set_read_TimeOut instead of a custum one ? HOT 3
- add connect_with_timeout to set connection timeout HOT 4
- Getting command exit status HOT 3
- Scp: quoting errors with spaces in dest filename HOT 5
- Scp: track progress for larger transfers HOT 2
- Scp: path-related bugs on windows HOT 1
- OpenSSH client drop-in replacement
- [email protected] request ignored HOT 1
- "Auth error" against freebsd HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ssh-rs.