]> git.ipfire.org Git - people/stevee/selinux-policy.git/blobdiff - Rules.monolithic
Allow ssh derived domain to execute ssh-keygen in the ssh_keygen_t domain
[people/stevee/selinux-policy.git] / Rules.monolithic
index d93524ea9e93985c6785a49d6ce976719eb2f667..5b0d53477615edbffacadda4d4ff4f8fb3f46fae 100644 (file)
@@ -23,7 +23,7 @@ M4PARAM += -D self_contained_policy
 # install paths
 loadpath = $(policypath)/$(notdir $(polver))
 
-appfiles += $(installdir)/booleans $(userpath)/local.users
+appfiles += $(installdir)/booleans $(installdir)/seusers $(userpath)/local.users
 
 # for monolithic policy use all base and module to create policy
 all_modules := $(strip $(base_mods) $(mod_mods))
@@ -32,7 +32,7 @@ all_interfaces := $(all_modules:.te=.if) $(off_mods:.te=.if)
 all_te_files := $(all_modules)
 all_fc_files := $(all_modules:.te=.fc)
 
-pre_te_files := $(secclass) $(isids) $(avs) $(m4support) $(poldir)/mls $(poldir)/mcs
+pre_te_files := $(secclass) $(isids) $(avs) $(m4support) $(poldir)/mls $(poldir)/mcs $(policycaps)
 post_te_files := $(user_files) $(poldir)/constraints
 
 policy_sections := $(tmpdir)/pre_te_files.conf $(tmpdir)/all_attrs_types.conf $(tmpdir)/global_bools.conf $(tmpdir)/only_te_rules.conf $(tmpdir)/all_post.conf
@@ -96,7 +96,7 @@ endif
 #
 # Load the binary policy
 #
-reload $(tmpdir)/load: $(loadpath) $(fcpath) $(ncpath) $(appfiles)
+reload $(tmpdir)/load: $(loadpath) $(fcpath) $(appfiles)
        @echo "Loading $(NAME) $(loadpath)"
        $(verbose) $(LOADPOLICY) -q $(loadpath)
        @touch $(tmpdir)/load
@@ -124,11 +124,10 @@ $(tmpdir)/generated_definitions.conf: $(all_te_files)
 $(tmpdir)/global_bools.conf: $(m4support) $(tmpdir)/generated_definitions.conf $(globalbool) $(globaltun)
        $(verbose) $(M4) $(M4PARAM) $^ > $@
 
-$(tmpdir)/all_interfaces.conf: $(m4support) $(all_interfaces)
+$(tmpdir)/all_interfaces.conf: $(m4support) $(all_interfaces) $(m4iferror)
        @test -d $(tmpdir) || mkdir -p $(tmpdir)
-       @echo "ifdef(\`__if_error',\`m4exit(1)')" > $(tmpdir)/iferror.m4
        @echo "divert(-1)" > $@
-       $(verbose) $(M4) $^ $(tmpdir)/iferror.m4 >> $(tmpdir)/$(@F).tmp
+       $(verbose) $(M4) $^ >> $(tmpdir)/$(@F).tmp
        $(verbose) $(SED) -e s/dollarsstar/\$$\*/g $(tmpdir)/$(@F).tmp >> $@
        @echo "divert" >> $@
 
@@ -143,7 +142,7 @@ endif
        @test -d $(tmpdir) || mkdir -p $(tmpdir)
        $(verbose) $(M4) $(M4PARAM) -s $^ > $@
 
-$(tmpdir)/post_te_files.conf: $(m4support) $(post_te_files)
+$(tmpdir)/post_te_files.conf: $(m4support) $(tmpdir)/generated_definitions.conf $(post_te_files)
        @test -d $(tmpdir) || mkdir -p $(tmpdir)
        $(verbose) $(M4) $(M4PARAM) $^ > $@
 
@@ -177,8 +176,8 @@ enableaudit: $(policy_conf)
 #
 $(fc): $(tmpdir)/$(notdir $(fc)).tmp $(fcsort)
        $(verbose) $(fcsort) $< $@
-       $(verbose) $(GREP) -e HOME -e ROLE $@ > $(homedir_template)
-       $(verbose) $(SED) -i -e /HOME/d -e /ROLE/d $@
+       $(verbose) $(GREP) -e HOME -e ROLE -e USER $@ > $(homedir_template)
+       $(verbose) $(SED) -i -e /HOME/d -e /ROLE/d -e /USER/d $@
 
 $(tmpdir)/$(notdir $(fc)).tmp: $(m4support) $(tmpdir)/generated_definitions.conf $(all_fc_files)
 ifeq ($(all_fc_files),)
@@ -239,6 +238,10 @@ $(appdir)/customizable_types: $(policy_conf)
        $(verbose) $(GREP) '^[[:blank:]]*type .*customizable' $< | cut -d';' -f1 | cut -d',' -f1 | cut -d' ' -f2 | $(SORT) -u > $(tmpdir)/customizable_types
        $(verbose) $(INSTALL) -m 644 $(tmpdir)/customizable_types $@ 
 
+$(installdir)/seusers: $(seusers)
+       @mkdir -p $(installdir)
+       $(verbose) $(INSTALL) -m 644 $^ $@
+
 ########################################
 #
 # Clean the sources