如何从linux到Windows进行无密码SSH [英] How do I do passwordless SSH from linux to windows
问题描述
我有一个安装并运行OpenSSH的Debian操作系统和Windows 2016.
我可以使用密码从Debian到Windows进行ssh。
$ ssh管理员@< windows ip =>
这会提示输入密码并使用密码。
据我所知,ssh-key-gen用于生成密钥,ssh-copy-id用于将公钥复制到远程主机和我尝试从Linjx到Linux工作。
但是如何实现从Linux(Debian)到Windows的无密码SSH?
我尝试了什么:
我尝试将密钥复制到C:\ Users \\下的Windows机器上管理员\.ssh
但没有运气。 SSH仍会提示输入密码。
ssh Administrator @< windows ip =>
这会提示输入密码,它可以使用密码。
据我所知,ssh-key-gen用于生成密钥,ssh-copy-id是用于将公钥复制到远程主机,我尝试从Linjx到Linux工作。
但我如何实现从Linux(Debian)到无密码SSH Windows?
我尝试了什么:
我试过复制在C下的Windows机器的关键:\ Users \Administrator \ .ssh
但没有运气。 SSH仍然提示输入密码。
升级到Windows 10和/或服务器2019.
安装OpenSSH for Windows | Microsoft Docs [ ^
I have a Debian OS and Windows 2016 with OpenSSH installed and running.
I can do ssh from my Debian to Windows with the password.
$ ssh Administrator@<windows ip="">
This prompts for a password and it works with password.
As I know, ssh-key-gen is used to generate keys and ssh-copy-id is used to copy the public key to the remote host and I tried this from Linjx to Linux which worked.
But how do I achieve passwordless SSH from Linux (Debian) to Windows?
What I have tried:
I tried copying the key to Windows machine under C:\Users\Administrator\.ssh
But no luck. SSH still prompts for a password.
ssh Administrator@<windows ip="">
This prompts for a password and it works with password.
As I know, ssh-key-gen is used to generate keys and ssh-copy-id is used to copy the public key to the remote host and I tried this from Linjx to Linux which worked.
But how do I achieve passwordless SSH from Linux (Debian) to Windows?
What I have tried:
I tried copying the key to Windows machine under C:\Users\Administrator\.ssh
But no luck. SSH still prompts for a password.
Upgrade to Windows 10 and / or server 2019.
Installation of OpenSSH For Windows | Microsoft Docs[^]
这篇关于如何从linux到Windows进行无密码SSH的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!