policy configuration problems
Hi, I have installed 2.4-based SELinux on Redhat9.0 and I want to eliminate the denied messages now. But there are several problems about my policy configuration.
First,there are still several system processes run within the initrc_t domain. I have moved up the .te files for these programes from the policy/domains/program/unused directory before building the policy and the pathname for these programs in the .fc files are right as well. Below is the associated messages with the command "ps -e --context":
--------------------------------------------------------------------------------------------------------------------
PID CONTEXT COMMAND 925 system_u:system_r:initrc_t portmap 944 system_u:system_r:initrc_t rpc.statd 1054 system_u:system_r:initrc_t xinetd -stayalive -reuse -pidfile 1074 system_u:system_r:initrc_t sendmail: accepting connections 1083 system_u:system_r:initrc_t sendmail: Queue runner@01:00:00 f 1093 system_u:system_r:initrc_t gpm -t imps2 -m /dev/mouse 1103 system_u:system_r:initrc_t /usr/sbin/cannaserver -syslog -u
-------------------------------------------------------------------------------------------------------------------
The second problem is that I used the "newrule.pl -d" command to automaticaly generate the allow rules.But there is no effect after I append the rules in the associated .te files and run the command "make load". The same denied messages are still there. Thanks a lot!
Quoted 3 lines · lky
Hi, I have installed 2.4-based SELinux on Redhat9.0 and I want to eliminate the denied messages now. But there are several problems about my policy configuration.
First,there are still several system processes run within theinitrc_tdomain. I have moved up the .te files for these programes from the policy/domains/program/unused directory before building the policy and the pathname for these programs in the .fc files are right as well. Below is the associated messages with the command "ps -e --context":
Check if the binaries are labelled correctly, i.e. do something like:
ls --context /usr/sbin/xinetd
(or wherever it is installed in redhat)
it should be system_u:system_r:inetd_exec_t if I remember correctly. If it's the generic :sbin_t then no transition happens.
same for the other programs.
Signature · 8 lines
http://web.lemuria.org/pubkey.html pub 1024D/2D7A04F5 2002-05-16 Tom Vogt <[email protected]> Key fingerprint = C731 64D1 4BCF 4C20 48A4 29B2 BF01 9FA1 2D7A 04F5 -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 9 lines
Check if the binaries are labelled correctly, i.e. do something like:
ls --context
/usr/sbin/xinetd
(or wherever it is installed in redhat)it should be system_u:system_r:inetd_exec_t if I remember correctly. If it's the generic :sbin_t then no transition happens.
same for the other programs.
Absolutely right! The file contexts aren't labelled correctly. After make relabel and append some allow rules the most programes run within their own domains and denied messages have been eliminated. Thanks!
------------------------------------------------------------------------
Another problem:
I want to use webmin to configure the system remotely,but now the webmin daemon still run within the initrc_t domain. I didn't find the .te and .fc files under the policy/domain/program and /policy/file_context/ directories. Should I have to create a new domain and a new .fc file for the program? I think it's fairly hard for me because webmin is a complicated program and I'm not very family with it. Is there any easier way I can take or can I add the webmin program to an existing domain?
-------------------------------------------------------------------------
Another question:
I'm not sure about my policy configuration steps.After changing the policy I take the following steps:
1.make reload
2.create the initrd-xx.img file
3.reboot
4.make relabel
5.reboot
Is this the only way if I want to reboot with the new policy? Can I omit the 4 and 5 steps if I just move up the .te file from the unused directory and add some allow permissions? I don't know clearly when I must use "make relabel".
Thanks a lot!
--
This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.