Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 157761 - Apache: Load of PHP extensions failed when SELinux mode enforcing
Summary: Apache: Load of PHP extensions failed when SELinux mode enforcing
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: libselinux
Version: 3.0
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Daniel Walsh
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2005-05-14 17:18 UTC by Tomi Malkki
Modified: 2007-11-30 22:07 UTC (History)
0 users

Fixed In Version: Current
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2005-09-27 20:38:32 UTC


Attachments (Terms of Use)

Description Tomi Malkki 2005-05-14 17:18:39 UTC
PROBLEM LIKELY OCCURS ON OTHER PLATFORMS TOO

Description of problem:
Can't use PHP extensions when SELinux mode is enforcing, at least xmlrpc
extension fails to work.

Version-Release number of selected component (if applicable):
RPMS:
libsepol-1.1.1-2
libselinux-1.19.1-7
httpd-2.0.52-9.ent
php-4.3.9-3.6
php-pgsql-4.3.9-3.6
php-xmlrpc-4.3.9-3.6

How reproducible:


Steps to Reproduce:
1. Install php-xmlrpc
2. setenforce 1
3. /etc/init.d/httpd/restart
4. Try with /var/www/html/xmlrpc.php:
   <?
   $server = xmlrpc_server_create();
   ?>
5. Look /var/log/httpd/error_log
   
Actual results:


Expected results:


Apache error_log after /etc/httpd/start - last line is after pointing web
browser to http://localhost/xmlrpc.php:
[Sat May 14 20:08:04 2005] [notice] suEXEC mechanism enabled (wrapper:
/usr/sbin/suexec)
[Sat May 14 20:08:06 2005] [notice] Digest: generating secret for digest
authentication ...
[Sat May 14 20:08:06 2005] [notice] Digest: done
[Sat May 14 20:08:06 2005] [notice] LDAP: Built with OpenLDAP LDAP SDK
[Sat May 14 20:08:06 2005] [notice] LDAP: SSL support unavailable
PHP Warning:  Unknown(): Unable to load dynamic library '/usr/lib/php4/pgsql.so'
- /usr/lib/php4/pgsql.so: failed to map segment from shared object: Permission
denied in Unknown on line 0
PHP Warning:  Unknown(): Unable to load dynamic library
'/usr/lib/php4/xmlrpc.so' - /usr/lib/php4/xmlrpc.so: failed to map segment from
shared object: Permission denied in Unknown on line 0
[Sat May 14 20:08:06 2005] [notice] mod_python: Creating 4 session mutexes based
on 256 max processes and 0 max threads.
[Sat May 14 20:08:06 2005] [notice] Apache/2.0.52 (Red Hat) configured --
resuming normal operations
[client 127.0.0.1] PHP Fatal error:  Call to undefined function: 
xmlrpc_server_create() in /var/www/html/xmlrpc.php on line 2

Comment 1 Daniel Walsh 2005-05-14 22:40:39 UTC
restorecon -R -v /usr/lib 

should fix it.


How did this file get there?


Note You need to log in before you can comment on or make changes to this bug.