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 233985 - Changing from 'targeted' to 'strict' policy causes kernel panic.
Summary: Changing from 'targeted' to 'strict' policy causes kernel panic.
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy-strict
Version: 6
Hardware: i686
OS: Linux
Target Milestone: ---
Assignee: Daniel Walsh
QA Contact: Ben Levenson
Depends On:
TreeView+ depends on / blocked
Reported: 2007-03-26 14:36 UTC by Nils Hammar
Modified: 2007-11-30 22:12 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2007-03-26 17:42:37 UTC

Attachments (Terms of Use)

Description Nils Hammar 2007-03-26 14:36:59 UTC
Description of problem:
System hangs with Panic while booting and the following message:
"/sbin/init: error while loading shared libraries: failed to map
segment from shared object: Permission denied"

Version-Release number of selected component (if applicable):

Policy Related;

How reproducible:

Steps to Reproduce:
1. Installation of Fedora Core 6, selecting 'Development' usage, and no
customization of additional software. (Swedish sv-latin1 keyboard mapping)
2. Upgrading to latest patches with yum, "yum -y update" and reboot.
3. Installation of newrole package.
4. Changing from 'targeted' to 'strict' in either GUI or by editing
/etc/sysconfig/selinux and trigging relabeling.
5. reboot.
6. System hangs early in the start with:
"/sbin/init: error while loading shared libraries: failed to map
segment from shared object: Permission denied"
Actual results:

Expected results:
No "Panic!"

Additional info:
Problem seems to be present for the "mls" policy too.

Is it maybe a "catch 22" problem here where the shared library has to be
relabeled in order to be accessed, but it can't be relabeled until the system is
booted with the right policy?

Comment 1 Daniel Walsh 2007-03-26 17:42:37 UTC
In order to relabel to strict you must do it in permissive mode first.   The
problem is in targeted policy shared library files are labeled lib_t and in
strict they are labeled shlib_t.  So when init tries to execute a shared library
it sees it is labeled lib_t and fails, and this happens before relabeling.

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