byobu breaks ssh-agent SSH_AUTH_SOCK

Bug #549091 reported by Daniel Hahler on 2010-03-26
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
byobu (Ubuntu)
Medium
Dustin Kirkland 

Bug Description

Binary package hint: byobu

I have "keychain" (a package) being launched in ~/.bash_profile:
It sets up environment vars for ssh-agent and gpg-agent.

However, after screen/byobu has been started (after keychain) in bash_profile, the environment is not valid anymore for at least SSH_AUTH_SOCK.
There's code in byobu-janitor:

# Establish ssh-agent socket, helps when reconnecting to a detached session
if [ -S "$SSH_AUTH_SOCK" ] && [ -w "$RUN" ]; then
        rm -f "$RUN/$PKG.ssh-agent"
        ln -sf "$SSH_AUTH_SOCK" "$RUN/$PKG.ssh-agent"
fi

The same code is present in /usr/bin/byobu, after janitor has been called.

So, we're creating a link first (in janitor), then removing it forcefully in the byobu script.

It ends up with a symlink pointing to itself, at least for myself.

This results in "ssh-add" not being able to connect to an agent. You would have to start keychain or a similar process, again.

ProblemType: Bug
Architecture: i386
Date: Fri Mar 26 20:02:19 2010
DistroRelease: Ubuntu 10.04
Package: byobu 2.65-0ubuntu1
PackageArchitecture: all
ProcEnviron:
 LANGUAGE=
 PATH=(custom, user)
 LANG=de_DE.UTF-8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.32-17.26-generic 2.6.32.10+drm33.1
ScreenRC:

SourcePackage: byobu
Uname: Linux 2.6.32-17-generic i686

Related branches

Daniel Hahler (blueyed) wrote :
Daniel Hahler (blueyed) on 2010-03-26
Changed in byobu (Ubuntu):
importance: Undecided → Medium
Changed in byobu (Ubuntu):
status: New → Triaged
assignee: nobody → Dustin Kirkland (kirkland)
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package byobu - 2.66-0ubuntu1

---------------
byobu (2.66-0ubuntu1) lucid; urgency=low

  * usr/bin/byobu, usr/bin/byobu-janitor: ensure that the SSH_AUTH_SOCK
    link is not circular, LP: #549091
 -- Dustin Kirkland <email address hidden> Tue, 16 Mar 2010 23:27:30 -0500

Changed in byobu (Ubuntu):
status: Triaged → Fix Released
Pontus Freyhult (pontusf) wrote :

It sems this fix does not work on the first run for a user after a restart or /var/run/ cleanup, the link is not created (as $RUN does not yet exist), but SSH_AUTH_SOCKS will still be pointed to the link position later.

This is with 2.68-0ubuntu1.

Daniel Nelson (packetcollision) wrote :

I am seeing the same issue in 2.68-0ubuntu1.1, disconnecting and reconnecting seems to have fixed it, but the first time byobu is called, the symlink is invalid.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers