D
D
Davidaa_WoW2022-04-12 13:17:06
SSH
Davidaa_WoW, 2022-04-12 13:17:06

Why can't I connect via ssh key between windows and a virtual machine?

There is a main system on Windows 10, there is Ubuntu on Virtual box. You need to configure a connection between them without a password using ssh keys. I generate keys on Windows, send them to the virtual machine with the command:
scp C:/Users/User/.ssh/id_rsa.pub [email protected]:/home/david/.ssh/authorized_keys
Everything works, it connects from Windows to the virtual machine without a password
I generate keys on a virtual machine, send them to Windows with the command:
scp /home/david/.ssh/id_rsa.pub [email protected]:C:/Users/User/.ssh/authorized_keys The
key seems to be even displayed in this created file on Windows , but when you try to connect, it still asks for a password.
What am I doing wrong?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
P
pfg21, 2022-04-12
@pfg21

specify in the manuals for your ssh server for Windows where it stores authorized_keys.
and see if it finds it in the logs.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question