This is a discussion on SELinux and login problem within the Linux Security forums, part of the System Security and Security Related category; Hello Group, Long story short, I'm using a thrid-party file for my website at the login page (index....
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Hello Group, Long story short, I'm using a thrid-party file for my website at the login page (index.php). When I set: #setenforce 1 I cannot get to the page unless I set it back to 0. I've started reading about SELinux but due to the deadline project I'm on rush. Would you give me some advice on how I can fix this up as SELinux is enabled? For your information, I check the log file /var/log/messages and saw: Jan 4 09:37:20 a1040 kernel: audit(1168022180.930:2): avc: denied { getattr } FOR pid=3252 comm="httpd" name="index.php" dev=sda3 ino=25528159 scontext=user_u:system_r:httpd_t tcontext=root:object_r:user_home_t tclass=fileJan 5 10:36:20 a1040 kernel: audit(1168022180.930:3) so regarding an expert suggestions I did: # chcon -t httpd_user_content_t index.php but still have same problem but at least I got this page this time: Warning: main(mainfile.php): failed to open stream: Permission denied in /var/www/html/index.php on line 35 Warning: main(): Failed opening 'mainfile.php' for inclusion (include_path='.:/usr/share/pear:/usr/local/ws/x/includes') in /var/www/html/index.php on line 35 Warning: main(header.php): failed to open stream: Permission denied in /var/www/html/index.php on line 43 Warning: main(): Failed opening 'header.php' for inclusion (include_path='.:/usr/share/pear:/usr/local/ws/x/includes') in /var/www/html/index.php on line 43 Warning: main(footer.php): failed to open stream: Permission denied in /var/www/html/index.php on line 44 Warning: main(): Failed opening 'footer.php' for inclusion (include_path='.:/usr/share/pear:/usr/local/ws/x/includes') in /var/www/html/index.php line 44 Any advice or suggestions will be appreciated greatly. Thanks, amit |
![]() |
| Thread Tools | |
| Display Modes | |
|
|