26

I've created one RDP file

full address:s:10.20.30.40
username:s:myuser
password:s:mypassword
domain:s:mydomain

When I open this file it still asks me for the password. What can I do to tell RDP client to use password mentioned in the file instead of asking user?

16

I had the issue on Windows 10 with perma asking password when I try to connect to a new machine.

First, the password line in the RDP must be named:

password 51:b:myEncryptedPassword

And the pass must by encrypted. You can use cryptRDP5 to convert it: https://github.com/jps-networks-modifiedOSS/openvpn-als-applications/tree/master/adito-application-rdp-xplatform-embedded/src/windows

cryptRDP5.exe yourpassword
| improve this answer | |
  • 4
    I found that Powershell's ConvertFrom-SecureString also works instead of needing that cryptRDP5.exe – jtb Feb 27 '19 at 23:03
  • 9
    For reference, the full powershell command to encrypt a password using the above would be ("MySuperSecretPassword!" | ConvertTo-SecureString -AsPlainText -Force) | ConvertFrom-SecureString; – BrainSlugs83 Mar 7 '19 at 20:36
  • Is there a linux/osx equivalent of cryptRDP5.exe? – Anthony Kong Jul 9 '19 at 0:25
  • @BrainSlugs83 Note that it doesn't fully match rdp encryption which pads the password with zero bytes to be 512 bytes before encryption. – NetMage Aug 24 at 20:38
11

Open the Group Policy editor (Start > Run > gpedit.msc) and navigate to Computer Configuration -> Administrative Templates -> Windows Components -> Remote Desktop Services -> Remote Desktop Connection Client

For value Do not allow passwords to be saved, check that is set to Disabled.

When connecting to a machine in Remote Desktop Connector, expand the Options panel and confirm that Allow me to save credentials is checked.

| improve this answer | |
  • 1
    I've disabled the value as per your suggestion but it still asks for my password. – Ganesh Satpute Aug 14 '17 at 6:24
  • This works only in case the password is encrypted/hashed. For plaintext password, it does not work. Is there any other policy which I've to check for this? – Ganesh Satpute Aug 14 '17 at 12:37
1

Try adding

prompt for credentials:i:0
| improve this answer | |
  • 1
    Have tried that but still asks me for my password. – Ganesh Satpute Aug 9 '17 at 16:22
  • Check the message that it gives to you. Maybe a GPO is blocking you to login withouth giving creds – Angel Porlan Aug 9 '17 at 16:26
  • It's not giving any message saying GPO is blocking the login. – Ganesh Satpute Aug 14 '17 at 6:24
  • Thanks, worked for me in combination with username:s:myuser and password 51:b:myEncryptedPassword. – Artem May 22 '19 at 20:49
1

I didn't managet to do this by modifying the .rdp. But a workaround is, to change the settings of the remote desktop connection application. In Preferences -> User Accounts you can add your account + password:

enter image description here

| improve this answer | |
  • That appears to be for MacOS, not Windows. – NetMage Aug 24 at 19:55
  • I asume that a similiar option might be in windows version of this Microsoft product available, too. The main trick is not to modify the rdp file, but to put it in the Remote Desktop app preferences. – DracoBlue Aug 24 at 19:57
  • Windows doesn't have app preferences. – NetMage Aug 24 at 20:02
0

To enable the setting, the user can enter promptcredentialonce:i:1 in the RDP file.

If the user wants to disable the setting, then user can enter promptcredentialonce:i:0 in the RDP file.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.