initrc_t bash: /etc/init.d/network: /bin/bash: bad interpreter: Permission denied

sluge

New Member
Joined
Sep 18, 2019
Messages
4
Reaction score
0
Credits
38
Hello, on my CentOS 7.6 with SELinux enforcing I faced with the issue:
Code:
# id
uid=0(root) gid=0(root) groups=0(root) context=sysadm_u:sysadm_r:sysadm_t:s0-s0:c0.c1023

#ls -lZ /etc/init.d/network
-rwxr-x---. root root system_u:object_r:initrc_exec_t:s0 /etc/init.d/network

#  /etc/init.d/network
bash: /etc/init.d/network: /bin/bash: bad interpreter: Permission denied

# sh /etc/init.d/network
Usage: /etc/init.d/network {start|stop|status|restart|force-reload}


# runcon -r sysadm_r /etc/init.d/network
Usage: /etc/init.d/network {start|stop|status|restart|force-reload}

So, it looks like some restriction doesn't allow to execute files with initrc_exec_t type.
Any Ideas of how to fix that?
 
Last edited:




Top