aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Gabriel <mike.gabriel@das-netzwerkteam.de>2018-05-06 15:17:45 +0200
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2018-05-06 15:17:45 +0200
commit0eb7be3b9a5ca10e945aa134e2ec0176848135ec (patch)
tree232efc04ac3aa967ea9eb586197c148236f0d993
parent011f9bf3493a0552dcdd6b66e9433ea2ed945bfc (diff)
downloadlightdm-remote-session-freerdp2-0eb7be3b9a5ca10e945aa134e2ec0176848135ec.tar.gz
lightdm-remote-session-freerdp2-0eb7be3b9a5ca10e945aa134e2ec0176848135ec.tar.bz2
lightdm-remote-session-freerdp2-0eb7be3b9a5ca10e945aa134e2ec0176848135ec.zip
freerdp2-session.in: FreeRDP2 API for /from-stdin has changed. Only the password is expected on stdin, on all other params need to be passed-in as options.
-rwxr-xr-xfreerdp2-session.in8
1 files changed, 7 insertions, 1 deletions
diff --git a/freerdp2-session.in b/freerdp2-session.in
index fe6fb62..d6a168e 100755
--- a/freerdp2-session.in
+++ b/freerdp2-session.in
@@ -22,7 +22,13 @@
socket="$HOME/.freerdp2-socket";
if [ -e "$socket" ]; then
- socat unix-connect:"$socket" - | /usr/bin/xfreerdp /sound:sys:pulse /f /from-stdin
+ AUTH_INFO="$(socat unix-connect:"$socket" -)"
+ AUTH_INFO_USER=$(echo "$AUTH_INFO" | awk '{ print $1 }')
+ AUTH_INFO_PASSWORD=$(echo "$AUTH_INFO" | awk '{ print $2 }')
+ AUTH_INFO_DOMAIN=$(echo "$AUTH_INFO" | awk '{ print $3 }')
+ AUTH_INFO_HOST=$(echo "$AUTH_INFO" | awk '{ print $4 }')
+ echo "$AUTH_INFO_PASSWORD" | /usr/bin/xfreerdp /sound:sys:pulse /f /v:"${AUTH_INFO_HOST}" /u:"${AUTH_INFO_USER} /d:"${AUTH_INFO_DOMAIN} /from-stdin
+ unse AUTH_INFO_PASSWORD
else
zenity --warning --text="Unable to locate FreeRDP socket"
fi;