Skip to content

Remote desktop rdp file generated

lokakuu 23, 2017

When using a lot of virtual machines or any other remotedesktop connection, it would be nice to get personal rdp file properly saved  – ready to use on own work pc / cloud drive. After this I can get my most used remote desktop connection open quicly and without typing logins over and over again

I thought it is time to re-post this. I find a good solution from Petri.com with a help of Remko Weijnen password encryption utility.

image

Original posts :

https://petri.com/forums/forum/microsoft-networking-services/terminal-services/25839-automatically-create-rdp-file-with-password

And

https://www.remkoweijnen.nl/blog/2007/10/18/how-rdp-passwords-are-encrypted/

Simply check rdp file (saved by you) on your machine. It looks something like this (minimum as it generated by azure)

full address:s:52.169.105.36:3389
prompt for credentials:i:1
administrative session:i:1

download cryp/decrypt utility to get you password properly in:

cryptRDP5.zip (6.4 KB, 1 view)

To get it generated with a password you must do an old school cmd script like this

:: "hashtool"   – location of the hash tool
:: "outputfile" – destination and name for the .rdp file
:: "comp"       – computer name (can be FQDN or NetBIOS)
:: "domain"     – name of authenticating domain
::                  (if stand-alone enter computer name)
:: "usr"        – Username
@echo Off

If "%1"=="" Goto EOF

set pwd=%1
Set hashtool="cryptRDP5.exe"
set outputfile="computer1.rdp"
set comp=youraddress.com:[port number]
set domain=domain
set usr=myUsername

for /f "tokens=*" %%a in (’%hashtool% %pwd%’) do set pwdhash=%%a

:CreateRDP
If EXIST %outputfile% del %outputfile%
Echo screen mode id:i:2>> %outputfile%
Echo desktopwidth:i:1024>> %outputfile%
Echo desktopheight:i:768>> %outputfile%
Echo session bpp:i:24>> %outputfile%
Echo winposstr:s:0,1,32,68,800,572>> %outputfile%
Echo full address:s:%comp%>> %outputfile%
Echo compression:i:1>> %outputfile%
Echo keyboardhook:i:2>> %outputfile%
Echo audiomode:i:2>> %outputfile%
Echo redirectdrives:i:0>> %outputfile%
Echo redirectprinters:i:0>> %outputfile%
Echo redirectcomports:i:0>> %outputfile%
Echo redirectsmartcards:i:1>> %outputfile%
Echo displayconnectionbar:i:1>> %outputfile%
Echo autoreconnection enabled:i:1>> %outputfile%
Echo authentication level:i:0>> %outputfile%
Echo username:s:%usr%>> %outputfile%
Echo domain:s:%domain%>> %outputfile%
Echo alternate shell:s:>> %outputfile%
Echo shell working directory:s:>> %outputfile%
Echo password 51:b:%pwdhash%>> %outputfile%
Echo disable wallpaper:i:1>> %outputfile%
Echo disable full window drag:i:0>> %outputfile%
Echo disable menu anims:i:0>> %outputfile%
Echo disable themes:i:0>> %outputfile%
Echo disable cursor setting:i:0>> %outputfile%
Echo bitmapcachepersistenable:i:1>> %outputfile%
Echo drivestoredirect:s:*>> %outputfile%
:EOF

Mainokset

From → Azure, Cloud, Windows

Jätä kommentti

Vastaa

Täytä tietosi alle tai klikkaa kuvaketta kirjautuaksesi sisään:

WordPress.com-logo

Olet kommentoimassa WordPress.com -tilin nimissä. Log Out / Muuta )

Twitter-kuva

Olet kommentoimassa Twitter -tilin nimissä. Log Out / Muuta )

Facebook-kuva

Olet kommentoimassa Facebook -tilin nimissä. Log Out / Muuta )

Google+ photo

Olet kommentoimassa Google+ -tilin nimissä. Log Out / Muuta )

Muodostetaan yhteyttä palveluun %s

%d bloggers like this: