Comments (8)
暂时没有支持,目前逻辑应该是等价于 StrictHostKeyChecking=no
BRs
from ssh-rs.
谢谢您的回复,PreferredAuthentications这个参数的设置应该也没有吧。ssh登录的时候会弹出Kerberos身份验证提示,在jsch里可以通过设置put("PreferredAuthentications", "publickey,keyboard-interactive,password")来解决弹出提示的问题
from ssh-rs.
对,我们还没做gssapi
认证的支持,目前只支持公钥和密码两种认证模式,
等价于jsch里面的 put("PreferredAuthentications", "publickey,password")
每次连接的时候都会优先去尝试公钥认证,当且仅当没有私钥文件加载或者认证失败时会回退到密码认证,如果密码认证失败就会断开。
您可以同时设置私钥文件路径和用户名密码,ssh本身是支持一条连接多次认证尝试的。
Brs.
from ssh-rs.
期待以后的版本中能有这个支持,谢谢
from ssh-rs.
您的应用场景是需要连接到只接受gssapi认证的ssh服务器吗?
如果只是想类比jsch解决弹出提示问题的话,因为我们不支持gssapi所以天然不存在类似问题。
如果必须要使用gssapi认证的话可能我们的库暂且无法使用。
我们会在后续的开发中加入gssapi认证的计划。
BRs
from ssh-rs.
应用场景中不需要连接gssapi认证的服务器。
连接的服务器比较多,每个服务器设置私钥很麻烦的。类似ssh client连接需要私钥的ssh服务器,可以通过keyboard-interactive输入密码实现正常认证登录。
from ssh-rs.
理解了,是需要在认证过程中提供回调函数来输入用户名密码,当然目前也可以在建立session前先行询问用户名密码作为workaround
BRs
from ssh-rs.
在用jsch的时候,最开始就放弃了publickey的方式,采用了keyboard-interactive和password登录方式,但有个问题,每个ssh服务器需要确认是否可以用password认证登录(如果可以就用password登录方式,否则用keyboard-interactive方式登录),并提前做好标志。后来发现在jsch设置一个("PreferredAuthentications", "publickey,keyboard-interactive,password"),然后直接按password的登录方式即可,很方便
from ssh-rs.
Related Issues (20)
- channel_scp_u 文件的错误 HOT 3
- Data transfer greater than 1GB HOT 1
- Problem with minimum libc version HOT 2
- Looping ssh connection Timeout HOT 9
- Add hmac-sha256 and hmac-512 HOT 4
- user auth failure, auth type is password. HOT 7
- Shell command execution HOT 4
- [Bug] Can't use example to connect to sshd server: key exchange error. HOT 6
- Can you make an example of tokio? HOT 3
- ssh-ed25519 HOT 2
- 读写分离还没有实现? HOT 5
- Exec commands that need sudo HOT 2
- 怎么判断shell.read是否完成呢 HOT 2
- `connect(..)` does not timeout HOT 3
- Tunnel without executing commands HOT 1
- 标准输出和错误输出 HOT 2
- 上传目录能排除某些文件吗 HOT 1
- 增加任务状态的建议 HOT 1
- How to obtain SshError HOT 8
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.