Help with RDP Script


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Help with RDP Script
# 1  
Old 05-31-2010
Help with RDP Script

I am trying to write a bash script to pull out a variable from a dynamically generated "launch.rdp" remote desktop file, and then open rdesktop with that variable. Here's what I have so far:

Code:
#!/bin/bash

rdpfile="$1"

resolution=1024x768
server=$(cat launch.rdp | sed -n "21p" | sed 's/^.\{30\}//g')

/usr/bin/rdesktop -d Domain -g "$resolution" "$server"

sed is pulling out the hostname of the server from the launch.rdp file, and stripping it down to only the address. The script does work, however I'm wanting to get this to work when opening from Mozilla; I.E open with. Any help is appreciated, thank you.
Login or Register to Ask a Question

Previous Thread | Next Thread

8 More Discussions You Might Find Interesting

1. Windows & DOS: Issues & Discussions

Port forwarding to windows rdp

I need assistance with a port forwarding related problem. ssh root@adress.com -p2222 -L 3389:192.168.0.10:3389 Have to connect to this 192.168.0.10 ip via rdp standard port from my windows machine. I got the linux command which should work but I just don't know how to use it... (1 Reply)
Discussion started by: genius90
1 Replies

2. IP Networking

VPN ssh access over RDP port?

Guys, Can I use an open RDP port to gain ssh access to my Linux server running the other side of our firewall? I work from home on the odd occasion, we only have RDP port 3389 available once logged into the VPN. I would rather ssh into my workstation without the need for a desktop display. ... (3 Replies)
Discussion started by: general_lee
3 Replies

3. Shell Programming and Scripting

RDP access from UNIX.

Hi, How can I access remote desktop shared area from Unix. Like on Windows in Run we use //IP/address Is there any similar command on Unix. I am using HP-UX. Basically I need to transfer a file to Windows from Unix using a shell script. Quick response will be appreciated. Thanks in... (5 Replies)
Discussion started by: Peeyush Sehgal
5 Replies

4. UNIX for Dummies Questions & Answers

Copy file from RDP to Local

Hi All, I am trying to copy a file from remote desktop to my local system using copy and xcopy commands...but none of them worked..is there any batch file or commands to do the copying .if do please share with me..... (5 Replies)
Discussion started by: navsan420
5 Replies

5. Cybersecurity

RDP over SSH Tunnel

Hi all, I'm trying have an alternative way of connecting into a Corporate network. Mostly in case the VPN down as I cannot also change the security policy. I want to expose windows RDP over ssh tunnel. I have 3 hosts in my scenario 1- Host a : Windows 2k8 has no internet access just only an... (3 Replies)
Discussion started by: h@foorsa.biz
3 Replies

6. Red Hat

Is there a way to use windows RDP with red hat 6

Besides installing VNC on the red hat server which i know i can do, is there any RDP servers (using the windows rdp client) to remote control a red hat 6.2 server? Thanks in advance for this. (1 Reply)
Discussion started by: frankkahle
1 Replies

7. Solaris

How can i connect to win2k3 RDP from Solaris10 or Open Solaris

Hi all, O people of expert how can i connect to windows server 2003 remote desktop through Microsoft terminal server i don't want to install third parties products such VNC server or any web browser tools such as Remotely AnyWhere on the windows box what options and what procedures do i have to... (2 Replies)
Discussion started by: h@foorsa.biz
2 Replies

8. Shell Programming and Scripting

runx and rdp command

Hi, Iam stuck with a problem... Iam trying to automate some commands by script. I want to execute the script from text mode. My script calls runx, then the window comes, and i have to give commands like "rdp IP_address" I need to pass the command "rdp IP_address" to runx in the script... (1 Reply)
Discussion started by: esham
1 Replies
Login or Register to Ask a Question
XFREERDP(1)							     xfreerdp							       XFREERDP(1)

NAME
xfreerdp - FreeRDP X11 client SYNOPSIS
xfreerdp [options] server[:port] [[options] server[:port] ...] DESCRIPTION
xfreerdp is an X11 Remote Desktop Protocol (RDP) client which is part of the FreeRDP project. An RDP server is built-in to many editions of Windows. Alternative servers included xrdp and VRDP (VirtualBox). OPTIONS
-0 Attach to the admin console of the server. -a bpp Sets the color depth for the connection to bpp bits per pixel. Valid values are 8, 15, 16, 24 and 32. The default value is the color depth of the FreeRDP-window. -c dir Sets the working-dir to dir. This parameter is only used when an AlternateShell (-s shell) is requested. dir should contain the executable file specified in the AlternateShell. -D Removes the windows decorations. -d Domain used in authentication. -f start in full screen mode. This mode can always be en- and disabled using Ctrl-Alt-Enter. -T text Sets the window title to text. -g geometry Sets the size of the FreeRDP window (and of the remote desktop, when establishing a new connection). geometry can have one of the following forms: o WxH - in this case the resulting window will be of WxH pixels. o P% - in this case the resulting window will be P% of your screen. o The special keyword workarea - in this case the resulting window will be of the same size as your workarea. -k id Sets the keyboard-layout-id to id. -m Don't send mouse motion events. -n hostname Set the reported client hostname to hostname. Default is to automatically detect the hostname. -o Play audio on the console instead of redirecting to the client. -p password Password used in authentication. -s shell Sets the startup-shell to shell. This parameter should contain a complete path to the alternate shell. If the alternete shell requires a different working directory use -c dir. -t port Connect to port, instead of the default 3389. -u username Username used in authentication. -x flag Set the experiance performance flags. flag can be one of: o m - (modem): Equivalent to 15. o b - (broadband): Equivalent to 1. o l - (lan): Equivalent to 0. o num - A hexadecimal number that represents a bit-mask, were numbers mean the following [1]: o 1: Disable desktop wallpaper. o 2: Disable full-window drag (only the window outline is displayed when the window is moved). o 4: Disable menu animations. o 8: Disable user interface themes. o 20: Disable mouse cursor shadows. o 40: Disable cursor blinking. o 80: Enable font smoothing. o 100: Enable Desktop Composition. -z Enable compression. --app initialize a RemoteApp connection. This implies -g workarea. --ext load an extension --no-auth Skips authentication. This is useful e.g. for the current FreeRDP server that doesn't yet support server-side authentication. --no-fastpath Disables fast-path. Use slow-path packets instead, which have larger headers. It might be good for debugging certain issues when you suspect it might be linked to the parsing of one of the two header types. --gdi GDI rendering backend. backend can be either sw (software) or hw (hardware). --no-osb Disable off screen bitmaps. --no-bmp-cache Disable bitmap cache. --plugin load a plugin --rfx Enable RemoteFX. --rfx-mode RemoteFX operational flags. flags can be either v[ideo], i[mage]), default is video. --nsc Enable NSCodec. --disable-wallpaper Disable wallpaper. --composition Enable composition (RDVH only, not to be confused with remote composition). --disable-full-window-drag Disable full window drag. --disable-menu-animations Disable menu animations. --disable-theming Disable theming. --no-rdp Disable Standard RDP encryption. --no-tls Disable TLS encryption. --no-nla Disable network level authentication. --sec proto force protocol security. proto can be one of rdp, tls or nla. --ntlm force NTLM protocol version. version can be one of 1 or 2. --ignore-certificate ignore verification of logon certificate. --version Print version information. LINKS
http://www.freerdp.com/ AUTHOR
The FreeRDP Team NOTES
1. Taken from MS-RDPBCGR Section 2.2.1.11.1.1.1 - Extended Info Packet 2. MS-RDPBCGR Section 2.2.1.11.1.1.1 - Extended Info Packet http://msdn.microsoft.com/en-us/library/cc240476%28v=prot.10%29.aspx freerdp 2011-08-27 XFREERDP(1)