Control: tags -1 moreinfo

On Thu, Jun 09, 2016 at 07:09:46PM -0700, Nye Liu wrote:
> Package: libpam-modules
> Version: 1.1.8-3.3
> Severity: minor

> Dear Maintainer,

> pam_open_session() causes libasan to report a memory leak due to dl_open:

> ==32701==ERROR: LeakSanitizer: detected memory leaks

> Direct leak of 4096 byte(s) in 1 object(s) allocated from:
>     #0 0x7f44685c8f4a in malloc 
> (/usr/lib/x86_64-linux-gnu/libasan.so.2+0x93f4a)
>     #1 0x7f446964e101  (<unknown module>)

> A dump of proc/xxx/maps shows 0x7f446964e101 to be in ld-2.22.so, dl_open

> pamtest.c to demonstrate the bug:
> 
> // compile with: gcc pamtest.c -lasan -lpam -lpam_misc -o pamtest
> // "pamtest" will fail, "pamtest 0" succeeds

And what makes you so sure this is a pam bug, rather than a libasan bug (or
a glibc bug)?

Compiling without -lasan and running under valgrind doesn't show any such
leak.

And running pamtest under 'ltrace -e dlopen+dlclose -l
/lib/x86_64-linux-gnu/libdl.so.2' shows an equal number of calls to dlopen()
and dlclose().

So I don't see any way that this is a pam bug.

-- 
Steve Langasek                   Give me a lever long enough and a Free OS
Debian Developer                   to set it on, and I can move the world.
Ubuntu Developer                                    http://www.debian.org/
slanga...@ubuntu.com                                     vor...@debian.org

Reply via email to