Bug 246672

Summary: prelink isn't allowed to access("/proc/sys/kernel/exec-shield", F_OK)
Product: [Fedora] Fedora Reporter: Jakub Jelinek <jakub>
Component: selinux-policy-targetedAssignee: Daniel Walsh <dwalsh>
Status: CLOSED CURRENTRELEASE QA Contact: Ben Levenson <benl>
Severity: low Docs Contact:
Priority: low    
Version: 7   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Current Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-08-22 14:10:19 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jakub Jelinek 2007-07-03 20:02:56 UTC
prelink on i?86/x86_64 checks for presence of /proc/sys/kernel/exec-shield
to see whether --exec-shield or --no-exec-shield should be used by default
to lay out the shared libraries.
While as root I can
cat /proc/sys/kernel/exec-shield
1
ls -l /proc/sys/kernel/exec-shield
-rw-r--r-- 1 root root 0 2007-07-03 13:58 /proc/sys/kernel/exec-shield
when prelink is run, that fails:
strace /usr/sbin/prelink -avmR 2>&1 | grep exec-shield
access("/proc/sys/kernel/exec-shield", F_OK) = -1 EACCES (Permission denied)
while
strace -f runcon -t unconfined_t -- /usr/sbin/prelink -avmR 2>&1 | grep exec-shield
access("/proc/sys/kernel/exec-shield", F_OK) = 0

Can prelink be allowed to read this file, or do I need to do some uglier tricks
in the cron.daily script (such as checking for presence of that file and passing
--exec-shield in that case)?

Comment 1 Daniel Walsh 2007-07-06 15:18:43 UTC
What avc are you seeing?

Comment 2 Daniel Walsh 2007-07-06 15:26:37 UTC
Fixed in selinux-policy-2.6.4-27

Comment 3 Daniel Walsh 2007-08-22 14:10:19 UTC
Closing as fixes are in the current release