[Samba] pam_smbpass on Solaris box

Martynas Buozis martynas at ti.com
Thu Oct 23 10:31:58 GMT 2003


Hello


I decided to test password migration (on Solaris 8 box with SUNWspro C) and built samba with pam_smbpass module :

CC=cc ./configure --prefix=/opt/local/samba --with-acl-support --with-pam --with-pam_smbpass

Then installed bin/pam_smbpass.so in /usr/lib/security :

# ls -al /usr/lib/security/pam_smbpass.so
-rwxr-xr-x   1 root     sys      2091380 Oct 23 11:01 /usr/lib/security/pam_smbpass.so

Changed /etc/pam.conf :

other   auth sufficient /usr/lib/security/$ISA/pam_unix.so.1
other   auth requisite  /usr/lib/security/$ISA/pam_krb5.so.1 use_first_pass
other   auth optional   /usr/lib/security/$ISA/pam_smbpass.so migrate


And found, that PAM authentication it is not working at all (none of passwords are accepted). In syslog messages I see two messages for every session (for example - telnet) :

Oct 23 12:00:22 local login: [ID 487707 auth.error] load_modules: can not open module /usr/lib/security/pam_smbpass.so
Oct 23 12:00:31 local login: [ID 487707 auth.error] load_modules: can not open module /usr/lib/security/pam_smbpass.so

In truss output I see this :

9662:   stat64("/usr/lib/security/pam_smbpass.so", 0xFFBEFAB8) = 0
9662:   stat("/usr/lib/security/pam_smbpass.so", 0xFFBEF3F4) = 0
9662:   open("/usr/lib/security/pam_smbpass.so", O_RDONLY) = 3
9662:   fstat(3, 0xFFBEF3F4)                            = 0
9662:   mmap(0x00000000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF030000
9662:   mmap(0x00000000, 1392640, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFED00000
9662:   mmap(0xFEE36000, 62088, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_FIXED, 3, 1204224) = 0xFEE36000
9662:   mmap(0xFEE46000, 49716, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_FIXED|MAP_ANON, -1, 0) = 0xFEE46000
9662:   munmap(0xFEE28000, 57344)                       = 0
9662:   munmap(0xFEE54000, -8192)                       Err#22 EINVAL
9662:   memcntl(0xFED00000, 277476, MC_ADVISE, MADV_WILLNEED, 0, 0) = 0
9662:   close(3)

and later :

9662:   stat64("/usr/lib/security/pam_smbpass.so", 0xFFBEFB28) = 0
9662:   stat("/usr/lib/security/pam_smbpass.so", 0xFFBEF464) = 0
9662:   open("/usr/lib/security/pam_smbpass.so", O_RDONLY) = 6
9662:   fstat(6, 0xFFBEF464)                            = 0
9662:   mmap(0x00000000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE, 6, 0) = 0xFF030000
9662:   mmap(0x00000000, 1392640, PROT_READ|PROT_EXEC, MAP_PRIVATE, 6, 0) = 0xFEC80000
9662:   mmap(0xFEDB6000, 62088, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_FIXED, 6, 1204224) = 0xFEDB6000
9662:   mmap(0xFEDC6000, 49716, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_FIXED|MAP_ANON, -1, 0) = 0xFEDC6000
9662:   munmap(0xFEDA8000, 57344)                       = 0
9662:   munmap(0xFEDD4000, -8192)                       Err#22 EINVAL
9662:   memcntl(0xFEC80000, 277476, MC_ADVISE, MADV_WILLNEED, 0, 0) = 0
9662:   close(6) 

Whole telnet session look like this :

$ telnet testhost
Trying aaa.bbb.ccc.ddd...
Connected to testhost.
Escape character is '^]'.

testhost Login incorrect
login: martynas
Password:
Connection closed by foreign host.
$

Without pam_smbpass.so line in /etc/pam.conf session look like this :

$ telnet testhost
Trying aaa.bbb.ccc.ddd...
Connected to testhost.
Escape character is '^]'.

testhost login: martynas
Password:
Last login: Thu Oct 23 12:26:21 from aaa.bbb.ccc.ddd
$

Please note, that in first session there is "Login incorrect\n" in usual prompt "testhost login".


Google and samba list archives gave no tip about what can be wrong.

Any ideas ? Thank you for response in advance.



With best regards
Martynas


More information about the samba mailing list