| Summary: | SELinux is preventing horizon from accessing a shared secret | ||
|---|---|---|---|
| Product: | Red Hat OpenStack | Reporter: | Ryan Hallisey <rhallise> |
| Component: | openstack-selinux | Assignee: | Ryan Hallisey <rhallise> |
| Status: | CLOSED ERRATA | QA Contact: | Ido Ovadia <iovadia> |
| Severity: | unspecified | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 9.0 (Mitaka) | CC: | lhh, mgrepl, oblaut, srevivo, ssekidde |
| Target Milestone: | async | Keywords: | Triaged, ZStream |
| Target Release: | 8.0 (Liberty) | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | openstack-selinux-0.7.3-2.el7ost | Doc Type: | Bug Fix |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2016-11-14 19:44:48 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
* Mon Apr 18 2016 Ryan Hallisey <rhallise> 0.7.3-2 - Horizon needs the ability to access its shared secret - Resolves: rhbz#1328177 Adds to postinstall: fcontext -N -a -t httpd_var_lib_t /var/lib/openstack-dashboard Which results in: [root@rhel7 ~]# ls -ldZ /var/lib/openstack-dashboard drwxr-x---. apache apache system_u:object_r:httpd_var_lib_t:s0 /var/lib/openstack-dashboard Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHBA-2016-2708.html |
The openstack dashboard's secret key is not accessible. 1) install rhel7.2 2) install openstack-selinux 3) install httpd mod_wsgi mod_ssl openstack-dashboard memcached python-memcached 4) modify secret_key variable on /etc/openstack-dashboard/local_settings with this: ... from horizon.utils import secret_key SECRET_KEY = secret_key.generate_or_read_from_file('/var/lib/openstack-dashboard/secret_key') ... 5) systemctl start httpd.service After starting httpd, under /var/lib/openstack-dashboard apache successfully created two files owned by root: [root@mi-lab-horizon01 ~]# ll /var/lib/openstack-dashboard/ totale 4 -rw-------. 1 root root 64 15 apr 11.07 secret_key -rw-r--r--. 1 root root 0 15 apr 11.07 _var_lib_openstack-dashboard_secret_key.lock [root@mi-lab-horizon01 ~]# but apache user can't read those files and also SELinux prevent append on file under var/lib to httpd process.