Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pwauth segfault when it uses pam_smbpass and pam_winbind modules #6

Open
GoogleCodeExporter opened this issue Mar 19, 2015 · 0 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1./etc/nsswitch.conf
passwd:     files winbind
shadow:     files winbind
group:      files winbind

2. /etc/pam.d/pwauth
#%PAM-1.0
auth       sufficient   /lib/security/pam_winbind.so 
account    required     /lib/security/pam_nologin.so
account    sufficient   /lib/security/pam_winbind.so
password   sufficient   /lib/security/pam_smbpass.so
password   required     /lib/security/pam_winbind.so
session    required pam_mkhomedir.so
session    required pam_winbind.so
session    required     /lib/security/pam_unix.so

3. /usb/sbin/pwauth

4. Type samba users or AD domain users credentials

What is the expected output? What do you see instead?
Although it should validate the credential, it core dumps instead.
/etc/var/log/apache_error_log
[Thu Aug 15 11:02:47.867264 2013] [authnz_external:error] [pid 8374] [client 
10.39.17.36:49897] External authenticator died on signal 11
[Thu Aug 15 11:02:47.867329 2013] [authnz_external:error] [pid 8374] [client 
10.39.17.36:49897] AuthExtern pwauth [/usr/sbin/pwauth]: Failed (-2) for user 
admin
[Thu Aug 15 11:02:47.867338 2013] [auth_basic:error] [pid 8374] [client 
10.39.17.36:49897] AH01617: user admin: authentication failure for 
"/webdav/Backups": Password Mismatch

/var/log/messages
Aug 15 10:49:15 vmstore kernel: [ 1361.635185] pwauth[9079]: segfault at 
b75b3eb7 ip b75b3eb7 sp bfb6675c error 4 in libpthread-2.13.so[b75c8000+15000]
Aug 15 10:49:18 vmstore kernel: [ 1364.566193] pwauth[9093]: segfault at 
b7561eb7 ip b7561eb7 sp bfd4ae2c error 4 in libpthread-2.13.so[b7576000+15000]
Aug 15 11:02:47 vmstore kernel: [ 2171.892085] pwauth[10695]: segfault at 
b75b2eb7 ip b75b2eb7 sp bfb96d7c error 4 in libpthread-2.13.so[b75c7000+15000]

What version of the product are you using? On what operating system?
pwauth-2.3.8 (which comes with Debian Wheezy)

Please provide any additional information below.

It seems the problem arises when it finishes the job with one pam module 
(pam_smbpass/pam_winbind) and tries to go to the next. Maybe pwauth corrupted 
pam somehow !

no talloc stackframe at ../source3/param/loadparm.c:4842, leaking memory

Program received signal SIGSEGV, Segmentation fault.
0xb7e21eb7 in ?? ()
(gdb) bt
#0  0xb7e21eb7 in ?? ()
#1  0xb7ba16e1 in _talloc_free_internal (ptr=0x8061a90, location=0xb7ba44c7 
"../lib/talloc/talloc.c:2251") at ../lib/talloc/talloc.c:831
#2  0xb7ba23f0 in _talloc_free_children_internal (tc=0x804c0a8, ptr=0x804c0d8, 
location=0xb7ba44c7 "../lib/talloc/talloc.c:2251") at 
../lib/talloc/talloc.c:1256
#3  0xb7ba1830 in _talloc_free_internal (ptr=0x804c0d8, location=0xb7ba44c7 
"../lib/talloc/talloc.c:2251") at ../lib/talloc/talloc.c:851
#4  0xb7ba2742 in _talloc_free (ptr=0x804c0d8, location=0xb7ba44c7 
"../lib/talloc/talloc.c:2251") at ../lib/talloc/talloc.c:1371
#5  0xb7ba3d82 in talloc_autofree () at ../lib/talloc/talloc.c:2251
#6  0xb7ea05e8 in __cxa_finalize () from /lib/i386-linux-gnu/libc.so.6
#7  0xb7ba0a43 in __do_global_dtors_aux () from 
/usr/local/samba/lib/private/libtalloc.so.2
#8  0xb7ff4e52 in ?? () from /lib/ld-linux.so.2
#9  0xb7ff5947 in ?? () from /lib/ld-linux.so.2
#10 0xb7e6ccc4 in ?? () from /lib/i386-linux-gnu/libdl.so.2
#11 0xb7fefde6 in ?? () from /lib/ld-linux.so.2
#12 0xb7e6d0bc in ?? () from /lib/i386-linux-gnu/libdl.so.2
#13 0xb7e6ccfa in dlclose () from /lib/i386-linux-gnu/libdl.so.2
#14 0xb7fc6f8b in ?? () from /lib/i386-linux-gnu/libpam.so.0
#15 0xb7fc48ff in ?? () from /lib/i386-linux-gnu/libpam.so.0
#16 0xb7fc1da0 in pam_end () from /lib/i386-linux-gnu/libpam.so.0
#17 0x08048bff in check_auth (login=0xbffff4aa "admin", passwd=0xbffff8ab 
"soho") at auth_pam.c:186
#18 0x0804898e in main (argc=1, argv=0xbffffd64) at main.c:94



Original issue reported on code.google.com by [email protected] on 15 Aug 2013 at 6:06

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant