Bug 164937 - fsadm_t should be unconfined
fsadm_t should be unconfined
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: selinux-policy-targeted (Show other bugs)
rawhide
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Daniel Walsh
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2005-08-02 17:37 EDT by Colin Walters
Modified: 2007-11-30 17:11 EST (History)
2 users (show)

See Also:
Fixed In Version: 1.25.4-8
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2005-09-04 19:48:54 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Colin Walters 2005-08-02 17:37:37 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8b3) Gecko/20050729 Fedora/1.1-0.2.5.deerpark.alpha2 Firefox/1.0+

Description of problem:
Hi, I created a swap file using:

dd if=/dev/zero of=/scratch/swap ...

Then I added to /etc/fstab:

/scratch/swap           none                    swap    defaults        0 0

This is a pretty standard way to do swap files, documented in a lot of places.  The default policy prevents this from working:

audit(1123011750.821:2): avc:  denied  { read } for  pid=1331 comm="swapon" name="swap" dev=dm-3 ino=1331 scontext=system_u:system_r:fsadm_t tcontext=root:object_r:file_t tclass=file

I suggest that we make fsadm_t be unconfined_domain() or equivalent (perhaps just allow it to read all file types) to keep compatibility here.

Version-Release number of selected component (if applicable):
selinux-policy-targeted-1.25.3-10

How reproducible:
Always

Steps to Reproduce:
1. Create swap file
2. Add to fstab
3. swapon -a

Additional info:
Comment 1 Colin Walters 2005-08-03 15:55:34 EDT
I should note this bug only happens on bootup; I'm guessing initrc_t transitions
to fsadm_t, but unconfined_t does not.
Comment 4 Daniel Walsh 2005-08-25 12:55:47 EDT
fixed in selinux-policy-targeted-1.25.4-8

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