php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #23733 Immediate coredump under non-privileged user
Submitted: 2003-05-21 05:50 UTC Modified: 2003-06-03 07:48 UTC
Votes:4
Avg. Score:5.0 ± 0.0
Reproduced:4 of 4 (100.0%)
Same Version:3 (75.0%)
Same OS:2 (50.0%)
From: novicky at aarongroup dot cz Assigned:
Status: Closed Package: OCI8 related
PHP Version: 4.3.2 OS: Linux
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: novicky at aarongroup dot cz
New email:
PHP Version: OS:

 

 [2003-05-21 05:50 UTC] novicky at aarongroup dot cz
This problem is related to bug #22521. I open a new one because status of the bug is closed.

When I run php (cli) as a non-root user, I get immediate coredump. I guess the problem is that non-privileged user cannot connect to oracle using OCI_SHARED flag as follows from the trace bellow.

My system is Linux RedHat 8, Oracle 9.2.0, PHP-4.3.2RC3.
I also have checked php4-STABLE-200305210930.

This is a piece of strace dump:

shmget(1894756744, 4194304, IPC_CREAT|IPC_EXCL|0x1a0|0640) = -1 EEXIST (File exists)
nanosleep({0, 2000}, NULL)              = 0
shmget(1894756744, 4194304, IPC_CREAT|IPC_EXCL|0x1a0|0640) = -1 EEXIST (File exists)
nanosleep({0, 2000}, NULL)              = 0
shmget(1894756744, 4194304, IPC_CREAT|IPC_EXCL|0x1a0|0640) = -1 EEXIST (File exists)
nanosleep({0, 2000}, NULL)              = 0
shmget(1894756744, 4194304, IPC_CREAT|IPC_EXCL|0x1a0|0640) = -1 EEXIST (File exists)
nanosleep({0, 2000}, NULL)              = 0
shmget(1894756744, 4194304, IPC_CREAT|IPC_EXCL|0x1a0|0640) = -1 EEXIST (File exists)
nanosleep({0, 2000}, NULL)              = 0
shmget(1894756744, 4194304, IPC_CREAT|IPC_EXCL|0x1a0|0640) = -1 EEXIST (File exists)
nanosleep({0, 2000}, NULL)              = 0
shmget(1894756744, 4194304, IPC_CREAT|IPC_EXCL|0x1a0|0640) = -1 EEXIST (File exists)
nanosleep({0, 2000}, NULL)              = 0
shmget(1894756744, 4194304, IPC_CREAT|IPC_EXCL|0x1a0|0640) = -1 EEXIST (File exists)
nanosleep({0, 2000}, NULL)              = 0
shmget(1894756744, 4194304, IPC_CREAT|IPC_EXCL|0x1a0|0640) = -1 EEXIST (File exists)
nanosleep({0, 2000}, NULL)              = 0
shmget(1894756744, 4194304, IPC_CREAT|IPC_EXCL|0x1a0|0640) = -1 EEXIST (File exists)
nanosleep({0, 2000}, NULL)              = 0
shmget(1894756744, 4194304, IPC_CREAT|IPC_EXCL|0x1a0|0640) = -1 EEXIST (File exists)
shmget(1894756744, 0, 0)                = 98304
shmctl(98304, 0x102 /* SHM_??? */, 0xbfffbf54) = -1 EACCES (Permission denied)
--- SIGSEGV (Segmentation fault) ---
+++ killed by SIGSEGV +++


This is a gdb backtrace:

Program received signal SIGSEGV, Segmentation fault.
0x4076a6c2 in sskgmstat () from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0

#0  0x4076a6c2 in sskgmstat ()
   from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#1  0x40764a07 in skgmidrealm ()
   from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#2  0x40764511 in skgmlocate ()
   from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#3  0x40763f08 in skgmcrone ()
   from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#4  0x407685bc in skgmcrmany ()
   from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#5  0x40761ded in skgmcreate ()
   from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#6  0x403689bb in kgupmcreate_sga ()
   from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#7  0x40366218 in kgup_startup ()
   from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#8  0x402af183 in kpushInit ()
   from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#9  0x407707e7 in kpummpin ()
   from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#10 0x402af4d9 in kpupin () from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#11 0x40303d0c in OCIInitialize ()
   from /opt/oracle/product/9.2.0/lib/libclntsh.so.9.0
#12 0x08075a10 in zm_startup_oci (type=1, module_number=8)
    at /home/linux/php/php-4.3.2RC3/ext/oci8/oci8.c:489
#13 0x0810fa1f in zend_startup_module (module=0x81526e0)
    at /home/linux/php/php-4.3.2RC3/Zend/zend_API.c:1005
#14 0x080ec381 in php_startup_extensions (ptr=0x815cd3c, count=135603936)
    at /home/linux/php/php-4.3.2RC3/main/main.c:1048
#15 0x0811ce3e in php_startup_internal_extensions ()
    at main/internal_functions_cli.c:69
#16 0x080ec71f in php_module_startup (sf=0xffffffff, additional_modules=0x0,
    num_additional_modules=0) at /home/linux/php/php-4.3.2RC3/main/main.c:1216
#17 0x0811c375 in main (argc=2, argv=0xbffff824)
    at /home/linux/php/php-4.3.2RC3/sapi/cli/php_cli.c:516
#18 0x420158d4 in __libc_start_main () from /lib/i686/libc.so.6


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-05-30 07:11 UTC] tim at digicol dot de
I'm having exactly the same problem with PHP 4.3.2 (Release), Red Hat 7.3, Oracle 9.2.0.
 [2003-06-03 07:12 UTC] ohrn at chl dot chalmers dot se
I get hit by the exact same problem, both when running standalone and as an Apache module.

Setup is Linux RedHat 8, Oracle 9.2.0 and PHP-4.3.2

Version 4.3.0 works just fine.
 [2003-06-03 07:48 UTC] edink@php.net
This bug has been fixed in CVS.

In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at http://snaps.php.net/.
 
In case this was a documentation problem, the fix will show up soon at
http://www.php.net/manual/.

In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites in short time.
 
Thank you for the report, and for helping us make PHP better.

For a temporary fix you can edit your main/php_config.h *after* running configure and comment out line containing HAVE_OCI8_SHARED_MODE.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Nov 21 20:01:29 2024 UTC