Bug 468984 - SELinux is preventing consoletype (consoletype_t) "read" to /var/lib/dhclient/dhclient-ra0.leases (dhcpc_state_t).
SELinux is preventing consoletype (consoletype_t) "read" to /var/lib/dhclient...
Product: Fedora
Classification: Fedora
Component: dhcp (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: David Cantrell
Fedora Extras Quality Assurance
: 472923 (view as bug list)
Depends On:
  Show dependency treegraph
Reported: 2008-10-29 07:27 EDT by Ralf Corsepius
Modified: 2008-12-06 23:15 EST (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2008-12-06 23:15:32 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
full sealert (2.87 KB, text/plain)
2008-10-29 07:27 EDT, Ralf Corsepius
no flags Details

  None (edit)
Description Ralf Corsepius 2008-10-29 07:27:09 EDT
Created attachment 321787 [details]
full sealert

Description of problem:
I just found this SELinux alert:
SELinux is preventing consoletype (consoletype_t) "read" to
/var/lib/dhclient/dhclient-ra0.leases (dhcpc_state_t).

Version-Release number of selected component (if applicable):
on an uptodate (2008-10-29) i386-rawhide system.

How reproducible:
No idea. I had been playing with system-config-network during the time when this alert popped up.
Comment 1 Daniel Walsh 2008-10-29 12:17:55 EDT
Leaked file descriptor in dhclient

Please call
fcntl(fd, F_SETFD, FD_CLOEXEC)
after opening the descriptor
Comment 2 David Cantrell 2008-10-29 19:36:03 EDT
The read_client_leases() function uses open(2) rather than fopen(3), which is probably why I looked past it when adding in the FD_CLOEXEC stuff.

I've modified the patch to use O_CLOEXEC on open(2) calls and add the 'e' character to the mode string in fopen(3) calls.  This works when you compile with -D_GNU_SOURCE.

While I'm pretty confident this fixes the problem you're seeing, I'm going to queue this build as an F-10 update.
Comment 3 David Cantrell 2008-10-29 19:45:24 EDT
I've built a new package as dhcp-4.0.0-31.fc10, here's the koji job:


I cannot create an F-10 update yet, so if you want to try out the packages now on rawhide, you can download them from the koji task page.
Comment 4 Fedora Update System 2008-11-04 20:13:09 EST
dhcp-4.0.0-31.fc10 has been submitted as an update for Fedora 10.
Comment 5 Fedora Update System 2008-11-22 11:46:07 EST
dhcp-4.0.0-32.fc10 has been pushed to the Fedora 10 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update dhcp'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/f10/FEDORA-2008-9915
Comment 6 Bug Zapper 2008-11-25 23:25:07 EST
This bug appears to have been reported against 'rawhide' during the Fedora 10 development cycle.
Changing version to '10'.

More information and reason for this action is here:
Comment 7 David Cantrell 2008-12-01 18:30:33 EST
*** Bug 472923 has been marked as a duplicate of this bug. ***
Comment 8 mfk.linux 2008-12-04 13:05:16 EST
I tried to install the update listed in Comment #5 and terminal told me it found the update but did not install and when I tried the link given, I got a message saying the "path /updates/f10/FEDORA-2008-9915 cannot be found." Any suggestions?
Comment 9 Fedora Update System 2008-12-06 23:15:22 EST
dhcp-4.0.0-32.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.

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