Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 21 Feb 2019 00:30:37 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 235903] [pam] ssh-agent is not killed at terminating session
Message-ID:  <bug-235903-227@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D235903

            Bug ID: 235903
           Summary: [pam] ssh-agent is not killed at terminating session
           Product: Base System
           Version: 12.0-STABLE
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: bin
          Assignee: bugs@FreeBSD.org
          Reporter: sasaki@fcc.ad.jp

Enabling pam_ssh with want_agent in /etc/pam.d/xdm, ssh-agent is started at
login but is not killed at logout.

I added debug option to the session line and got the following logs on both
11.2-STABLE and 12.0-STABLE.

[11.2-STABLE]
Feb 18 09:24:50 XXX xdm[7352]: in pam_getenv(): entering: 'SSH_AGENT_PID'
Feb 18 09:24:50 XXX xdm[7352]: in openpam_findenv(): entering
Feb 18 09:24:50 XXX xdm[7352]: in openpam_findenv(): returning 1
Feb 18 09:24:50 XXX xdm[7352]: in pam_getenv(): returning '7364'
Feb 18 09:24:50 XXX xdm[7352]: in pam_sm_close_session(): killing ssh agent
7364

[12.0-STABLE]
Feb 18 09:14:04 XXX xdm[4425]: in pam_getenv(): entering: 'SSH_AGENT_PID'
Feb 18 09:14:04 XXX xdm[4425]: in openpam_findenv(): entering
Feb 18 09:14:04 XXX xdm[4425]: in openpam_findenv(): returning 1
Feb 18 09:14:04 XXX xdm[4425]: in pam_getenv(): returning '=3D4437'
Feb 18 09:14:04 XXX xdm[4425]: in pam_sm_close_session(): invalid ssh agent=
 pid

Comparing the both version of /usr/src/contrib/openpam/lib/libpam/pam_geten=
v.c,
I suspect that 12.0-STABLE's pam_getenv() is wrong.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-235903-227>