This is an automated email from the git hooks/post-receive script. x2go pushed a change to branch release/4.0.1.x in repository x2goserver. from ae57bba debian/x2goserver.docs: Install README.i18n file into bin:package x2goserver. new 7fdcc5d Make SSH agent forwarding work after having reconnected via SSH and having resumed a session. (Fixes: #672). Thanks to Robert Siemer for coming up with that idea. The 1 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "adds" were already present in the repository and have only been added to this reference. Summary of changes: debian/changelog | 3 +++ x2goserver/bin/x2goresume-session | 9 +++++++++ x2goserver/bin/x2goruncommand | 9 +++++++++ x2goserver/bin/x2gosuspend-session | 8 ++++++++ x2goserver/bin/x2goterminate-session | 8 ++++++++ 5 files changed, 37 insertions(+) -- Alioth's /srv/git/_hooks_/post-receive-email on /srv/git/code.x2go.org/x2goserver.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch release/4.0.1.x in repository x2goserver. commit 7fdcc5dd27566bea4171f192a1c99c3e2657ac77 Author: Mike Gabriel <mike.gabriel@das-netzwerkteam.de> Date: Thu Nov 13 12:07:22 2014 +0100 Make SSH agent forwarding work after having reconnected via SSH and having resumed a session. (Fixes: #672). Thanks to Robert Siemer for coming up with that idea. --- debian/changelog | 3 +++ x2goserver/bin/x2goresume-session | 9 +++++++++ x2goserver/bin/x2goruncommand | 9 +++++++++ x2goserver/bin/x2gosuspend-session | 8 ++++++++ x2goserver/bin/x2goterminate-session | 8 ++++++++ 5 files changed, 37 insertions(+) diff --git a/debian/changelog b/debian/changelog index 9598c24..2daf624 100644 --- a/debian/changelog +++ b/debian/changelog @@ -42,6 +42,9 @@ x2goserver (4.0.1.19-0x2go1) UNRELEASED; urgency=medium - Also enforce /bin/sh as shell in su command in x2goprint. - README.i18n: Add file that explains the translation workflow for this package. Thanks to Mark Pedersen-Cook for drafting this file. + - Make SSH agent forwarding work after having reconnected via SSH and + having resumed a session. (Fixes: #672). Thanks to Robert Siemer for coming + up with that idea. * debian/control: + Add D (x2goserver): libfile-which-perl. * debian/x2goserver.docs: diff --git a/x2goserver/bin/x2goresume-session b/x2goserver/bin/x2goresume-session index b514e03..8783dad 100755 --- a/x2goserver/bin/x2goresume-session +++ b/x2goserver/bin/x2goresume-session @@ -42,6 +42,15 @@ X2GO_ROOT="${HOME}/.x2go" X2GO_RESIZE=1 X2GO_FULLSCREEN=0 +# refresh up ssh-agent-forwarding socket file symlink +X2GOSSH_AUTH_SOCK="$X2GO_ROOT/C-$SESSION_NAME/ssh-agent.PID" +if [ -L "$X2GOSSH_AUTH_SOCK" ]; then + rm -f "$X2GOSSH_AUTH_SOCK" +fi +if [ -S "$SSH_AUTH_SOCK" ]; then + ln -sf "$SSH_AUTH_SOCK" "$X2GOSSH_AUTH_SOCK" +fi + STATE=`$X2GO_LIB_PATH/x2gogetagentstate "$SESSION_NAME"` # exit if session terminated diff --git a/x2goserver/bin/x2goruncommand b/x2goserver/bin/x2goruncommand index 55d7f38..525a3f0 100755 --- a/x2goserver/bin/x2goruncommand +++ b/x2goserver/bin/x2goruncommand @@ -53,6 +53,15 @@ export QT_GRAPHICSSYSTEM="native" IMEXIT="false" +# symlink to SSH_AUTH_SOCKET (ssh agent forwarding) so that we +# can survive session suspension / resumption... +X2GOSSH_AUTH_SOCK="$X2GO_ROOT/C-$X2GO_SESSION/ssh-agent.PID" +if [ -S "$SSH_AUTH_SOCK" ]; then + ln -sf "$SSH_AUTH_SOCK" "$X2GOSSH_AUTH_SOCK" +fi +export SSH_AUTH_SOCK="$X2GOSSH_AUTH_SOCK" + + NX_XINERAMA_LIBS="$(x2gopath xinerama)" NX_LIBS="$(x2gopath nx-x11)" test -n "$LD_LIBRARY_PATH" && \ diff --git a/x2goserver/bin/x2gosuspend-session b/x2goserver/bin/x2gosuspend-session index 69f6c2b..79b1742 100755 --- a/x2goserver/bin/x2gosuspend-session +++ b/x2goserver/bin/x2gosuspend-session @@ -26,6 +26,8 @@ else SESSION_NAME="$X2GO_SESSION" fi +X2GO_ROOT="${HOME}/.x2go" + X2GO_LIB_PATH="$(x2gopath libexec)"; $X2GO_LIB_PATH/x2gosyslog "$0" "info" "$(basename $0) called with options: $@" @@ -72,3 +74,9 @@ then else $X2GO_LIB_PATH/x2gosyslog "$0" "notice" "session with ID $SESSION_NAME is not in running state" fi + +# disable ssh-agent-forwarding socket file symlink +X2GOSSH_AUTH_SOCK="$X2GO_ROOT/C-$SESSION_NAME/ssh-agent.PID" +if [ -L "$X2GOSSH_AUTH_SOCK" ]; then + rm -f "$X2GOSSH_AUTH_SOCK" +fi diff --git a/x2goserver/bin/x2goterminate-session b/x2goserver/bin/x2goterminate-session index b896475..248765c 100755 --- a/x2goserver/bin/x2goterminate-session +++ b/x2goserver/bin/x2goterminate-session @@ -26,6 +26,8 @@ else SESSION_NAME="$X2GO_SESSION" fi +X2GO_ROOT="${HOME}/.x2go" + X2GO_LIB_PATH="$(x2gopath libexec)"; $X2GO_LIB_PATH/x2gosyslog "$0" "info" "$(basename $0) called with options: $@" @@ -57,4 +59,10 @@ else x2gofeature X2GO_RUN_EXTENSIONS &>/dev/null && x2goserver-run-extensions "$SESSION_NAME" fail-terminate || true fi +# disable ssh-agent-forwarding socket file symlink +X2GOSSH_AUTH_SOCK="$X2GO_ROOT/C-$SESSION_NAME/ssh-agent.PID" +if [ -L "$X2GOSSH_AUTH_SOCK" ]; then + rm -f "$X2GOSSH_AUTH_SOCK" +fi + $X2GO_LIB_PATH/x2gochangestatus 'F' "$SESSION_NAME" > /dev/null -- Alioth's /srv/git/_hooks_/post-receive-email on /srv/git/code.x2go.org/x2goserver.git