hashicorp / vagrant

Vagrant is a tool for building and distributing development environments.
https://www.vagrantup.com
Other
26.28k stars 4.44k forks source link

vagrant rdp needs to be able to accept certificate #11766

Open pbrezina opened 4 years ago

pbrezina commented 4 years ago

I'm using rdesktop to access Windows machines. Sometimes, vagrant rdp commands gets stuck because rdesktop requires user input (to accept the certificate) so I have to run rdesktop manually before using vagrant rdp Vagrant should allow communication between user and the underlying tool.

$ vagrant rdp ad
==> ad: Detecting RDP info...
    ad: Address: 192.168.121.6:3389
    ad: Username: .\Administrator
==> ad: Vagrant will now launch your RDP client with the connection parameters
==> ad: above. If the connection fails, verify that the information above is
==> ad: correct. Additionally, make sure the RDP server is configured and
==> ad: running in the guest machine (it is disabled by default on Windows).
==> ad: Also, verify that the firewall is open to allow RDP connections.
^C (it is stuck here)

$ /usr/bin/rdesktop -u .\Administrator -p ... 192.168.121.6:3389
Autoselecting keyboard map 'en-us' from locale

ATTENTION! Found a certificate stored for host '192.168.121.6', but it does not match the certificate
received from server.
Review the following certificate info before you trust it to be added as an exception.
If you do not trust the certificate the connection atempt will be aborted:

    Subject: ...
     Issuer: ...
 Valid From: Mon Jul 13 13:58:58 2020
         To: Tue Jan 12 12:58:58 2021

  Certificate fingerprints:

       sha1: ...
     sha256: ...

Do you trust this certificate (yes/no)? yes
jbonhag commented 4 years ago

Related: https://github.com/rdesktop/rdesktop/issues/349