| Summary: | SELinux is preventing nginx from 'open' accesses on the file /home/mikhail/www/webdj/assets/css.js. | ||
|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Mikhail <mikhail.v.gavrilov> |
| Component: | selinux-policy | Assignee: | Lukas Vrabec <lvrabec> |
| Status: | CLOSED NOTABUG | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
| Severity: | unspecified | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 25 | CC: | bperkins, dominick.grift, dwalsh, lvrabec, mgrepl, plautrba, pmoore, ssekidde |
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | x86_64 | ||
| OS: | Unspecified | ||
| Whiteboard: | abrt_hash:a88424c5a37e6fd7e22457a6f6950323caeff6b386ea695afb9336a3ff223d7c;VARIANT_ID=workstation; | ||
| Fixed In Version: | Doc Type: | If docs needed, set a value | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2016-11-07 20:24:10 UTC | Type: | --- |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
***** Plugin restorecon (92.2 confidence) suggests ************************ If you want to fix the label. /home/mikhail/www/webdj/assets/css.js default label should be httpd_user_content_t. Then you can run restorecon. Do # /sbin/restorecon -v /home/mikhail/www/webdj/assets/css.js ***** Plugin catchall_boolean (7.83 confidence) suggests ****************** If you want to allow httpd to read user content Then you must tell SELinux about this by enabling the 'httpd_read_user_content' boolean. You can read 'None' man page for more details. Do setsebool -P httpd_read_user_content 1 *** Bug 1391229 has been marked as a duplicate of this bug. *** |
Description of problem: SELinux is preventing nginx from 'open' accesses on the file /home/mikhail/www/webdj/assets/css.js. ***** Plugin restorecon (92.2 confidence) suggests ************************ If you want to fix the label. /home/mikhail/www/webdj/assets/css.js default label should be httpd_user_content_t. Then you can run restorecon. Do # /sbin/restorecon -v /home/mikhail/www/webdj/assets/css.js ***** Plugin catchall_boolean (7.83 confidence) suggests ****************** If you want to allow httpd to read user content Then you must tell SELinux about this by enabling the 'httpd_read_user_content' boolean. You can read 'None' man page for more details. Do setsebool -P httpd_read_user_content 1 ***** Plugin catchall (1.41 confidence) suggests ************************** If you believe that nginx should be allowed open access on the css.js file by default. Then you should report this as a bug. You can generate a local policy module to allow this access. Do allow this access for now by executing: # ausearch -c 'nginx' --raw | audit2allow -M my-nginx # semodule -X 300 -i my-nginx.pp Additional Information: Source Context system_u:system_r:httpd_t:s0 Target Context unconfined_u:object_r:user_home_t:s0 Target Objects /home/mikhail/www/webdj/assets/css.js [ file ] Source nginx Source Path nginx Port <Unknown> Host (removed) Source RPM Packages Target RPM Packages Policy RPM selinux-policy-3.13.1-220.fc25.noarch Selinux Enabled True Policy Type targeted Enforcing Mode Permissive Host Name (removed) Platform Linux (removed) 4.8.5-300.fc25.x86_64+debug #1 SMP Fri Oct 28 21:21:05 UTC 2016 x86_64 x86_64 Alert Count 4 First Seen 2016-11-01 22:29:00 +05 Last Seen 2016-11-02 13:21:48 +05 Local ID 211f3276-9cce-4e76-aefc-3d84a3e58044 Raw Audit Messages type=AVC msg=audit(1478074908.708:1761): avc: denied { open } for pid=13691 comm="nginx" path="/home/mikhail/www/webdj/assets/css.js" dev="sdb" ino=6442530244 scontext=system_u:system_r:httpd_t:s0 tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file permissive=1 Hash: nginx,httpd_t,user_home_t,file,open Version-Release number of selected component: selinux-policy-3.13.1-220.fc25.noarch Additional info: reporter: libreport-2.8.0 hashmarkername: setroubleshoot kernel: 4.8.5-300.fc25.x86_64+debug type: libreport Potential duplicate: bug 1136086