Bug 503756 - Denials of setenforce are not being reported in the audit.log
Summary: Denials of setenforce are not being reported in the audit.log
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: kernel
Version: rawhide
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Eric Paris
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-06-02 14:51 UTC by Daniel Walsh
Modified: 2009-06-02 20:56 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-06-02 15:54:51 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Daniel Walsh 2009-06-02 14:51:05 UTC
Description of problem:

If I execute 

sandbox setenforce 0

I would expect a big denial in the audit.log

# sandbox setenforce 0
/usr/sbin/setenforce:  setenforce() failed
sh-4.0# ausearch -m avc -ts recent
<no matches>

Sadly no AVC is reported.

If I put the machine in permissive mode I do see the AVC.

#============= sandbox_t ==============
allow sandbox_t security_t:file write;
allow sandbox_t security_t:security setenforce;

Comment 1 Eric Paris 2009-06-02 15:02:28 UTC
Do you have dontaudit on open of security_t:file?  I don't see the open...

Comment 2 Stephen Smalley 2009-06-02 15:09:38 UTC
Ditto for security_t:dir search.
You aren't ever reaching the setenforce check in enforcing mode.

Comment 3 Daniel Walsh 2009-06-02 15:54:51 UTC
I am an idiot, never mind.

I will allow domains to getattr on /selinux and search the selinux_t so that we can get them attempting to write the security_t file.

Comment 4 Daniel Walsh 2009-06-02 20:56:54 UTC
BTW There is n o open of security_t.


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