Bug 503286
Summary: | SELinux prevents chsh from changing file | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Michael Krauss <hippodriver> |
Component: | selinux-policy | Assignee: | Miroslav Grepl <mgrepl> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | low | Docs Contact: | |
Priority: | low | ||
Version: | 11 | CC: | daryll, dwalsh, kzak, mgrepl |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2010-04-27 14:42:11 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
Michael Krauss
2009-05-30 19:42:05 UTC
I guess the problem is: if (access (shell, X_OK) < 0) { printf (_("%s: \"%s\" is not executable.\n"), whoami, shell); return (-1); } The SELinux message SELinux is preventing chsh (chfn_t) "execute" bin_t. is strange, chsh(1) is not executing any shell. Note also that the file is labeled "chfn_f", but we are talking about "chsh". If you change the context of the fish shell to shell_exec_t it should work. chcon -t shell_exec_t /usr/bin/fish If you want this label permanent execute semanage fcontext -a -t shell_exec_t /usr/bin/fish I will add fish as a shell. Currently access checks the exact same SELinux access checks as actually executing the shell. So access(shell, X_OK) == exec(shell) from an SELinux point of view. Hopefully this will be changing soon. Fixed in selinux-policy-3.6.12-44.fc11 This bug appears to have been reported against 'rawhide' during the Fedora 11 development cycle. Changing version to '11'. More information and reason for this action is here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping This also happens with /sbin/nologin. So I expect that label on nologin has to be added to the system default. Miroslav can you add this label to /bin/nologin Fixed in selinux-policy-3.6.12-76.fc11 This message is a reminder that Fedora 11 is nearing its end of life. Approximately 30 (thirty) days from now Fedora will stop maintaining and issuing updates for Fedora 11. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as WONTFIX if it remains open with a Fedora 'version' of '11'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version prior to Fedora 11's end of life. Bug Reporter: Thank you for reporting this issue and we are sorry that we may not be able to fix it before Fedora 11 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora please change the 'version' of this bug to the applicable version. If you are unable to change the version, please add a comment here and someone will do it for you. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete. The process we are following is described here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping |