From:             brunobenchimol at terra dot com dot br
Operating system: Linux - Debian 3.0r2
PHP version:      4.3.5
PHP Bug Type:     LDAP related
Bug description:  bug while reading libnss-ldap.conf

Description:
------------
# strace -f ./httpd -X 



<snip> 

.... 

brk(0x810a000) = 0x810a000 

open("/etc/libnss-ldap.conf", O_RDONLY) = 3 

fstat64(3, {st_mode=S_IFREG|0644, st_size=63, ...}) = 0 

old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1,
0) = 0x40015000 

read(3, "host 192.168.1.2\nbase dc=tcm,dc="..., 4096) = 63 

read(3, "", 4096) = 0 

close(3) = 0 

munmap(0x40015000, 4096) = 0 

brk(0x810c000) = 0x810c000 

brk(0x810d000) = 0x810d000 

old_mmap(NULL, 143360, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS,
-1, 0) = 0x409dc000 

brk(0x810f000) = 0x810f000 

--- SIGSEGV (Segmentation fault) --- 

+++ killed by SIGSEGV +++ 

web:/usr/local/apache/bin# 





When i try to run php4 (as a module from apache) i also compiled php4 with
oracle 8 support (oracle and oci8), it crashes every time it reads my
libnss-ldap.conf which has my host, my base and my ldap version (in this
case its v3) only those 3 lines, which is needed for others programs to
access my ldap base.

When i remove the file libnss-ldap.conf , php4 load normally without
segmentat faulting, anyway when i dont load the php4 module , apache works
fine, so it isnt a bug in apache, but in the php4, i also tried php 4.3.4
and 4.1.2 but still gave me the same.



for now i have disabled php4 and im running with apache (1.3.29) and
coldfusion mx 6.1 without any problems.



a small fix imho would make php not read this file, but well i dont know
WHY it reads it and which impacts would if he doesnt read. 



i hope i can get some help about this stuff, either if i can get a patch
(or tell me which part in code) it does this call open().



any help is appreciated.



thanks in advance.


-- 
Edit bug report at http://bugs.php.net/?id=27969&edit=1
-- 
Try a CVS snapshot (php4):  http://bugs.php.net/fix.php?id=27969&r=trysnapshot4
Try a CVS snapshot (php5):  http://bugs.php.net/fix.php?id=27969&r=trysnapshot5
Fixed in CVS:               http://bugs.php.net/fix.php?id=27969&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=27969&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=27969&r=needtrace
Need Reproduce Script:      http://bugs.php.net/fix.php?id=27969&r=needscript
Try newer version:          http://bugs.php.net/fix.php?id=27969&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=27969&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=27969&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=27969&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=27969&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=27969&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=27969&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=27969&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=27969&r=isapi
Install GNU Sed:            http://bugs.php.net/fix.php?id=27969&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=27969&r=float

Reply via email to