[Bug 3508] Memory leak in auth-pam

bugzilla-daemon at mindrot.org bugzilla-daemon at mindrot.org
Fri Dec 16 15:14:05 AEDT 2022


https://bugzilla.mindrot.org/show_bug.cgi?id=3508

--- Comment #2 from Darren Tucker <dtucker at dtucker.net> ---
Actually looking more closely I don't think it can leak.

sshpam_conninfo is allocated at the same time as sshpam_rhost, which is
also a global.  On subsequent calls to sshpam_init, sshpam_rhost will
already be set so sshpam_conninfo will not be re-populated, but it will
get used again for pam_putenv.

Freeing sshpam_conninfo would mean the during subsequent calls to
sshpam_init it would not be available (either NULL if it was nulled
out, or a use-after-free if not).

-- 
You are receiving this mail because:
You are watching someone on the CC list of the bug.
You are watching the assignee of the bug.


More information about the openssh-bugs mailing list