Skip to contentSkip to conversation

Add recipe to build the MCS refpolicy.

PATCH In review Philip Tricca 2 participants 2 messages Oct 29, 2013 – Oct 30, 2013

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Add recipe to build the MCS refpolicy.

This is the default policy type used by most (all?) distros that support SELinux.

---
 .../refpolicy/refpolicy-mcs_2.20130424.bb          |   23 ++++++++++++++++++++
 1 file changed, 23 insertions(+)
 create mode 100644 recipes-security/refpolicy/refpolicy-mcs_2.20130424.bb
recipes-security/refpolicy/refpolicy-mcs_2.20130424.bb new file +23 -0
new file mode 100644
index 0000000..38b78f1
@@ -0,0 +1,23 @@
+SUMMARY = "MCS (Multi Category Security) variant of the SELinux policy"
+DESCRIPTION = "\
+This is the reference policy for SE Linux built with MCS support. \
+An MCS policy is the same as an MLS policy but with only one sensitivity \
+level. This is useful on systems where a hierarchical policy (MLS) isn't \
+needed (pretty much all systems) but the non-hierarchical categories are. \
+"
+
+PR = "r0"
+
+POLICY_NAME = "mcs"
+POLICY_TYPE = "mcs"
+POLICY_DISTRO = "redhat"
+POLICY_UBAC = "n"
+POLICY_UNK_PERMS = "allow"
+POLICY_DIRECT_INITRC = "n"
+POLICY_MONOLITHIC = "n"
+POLICY_CUSTOM_BUILDOPT = ""
+POLICY_QUIET = "y"
+
+POLICY_MCS_CATS = "1024"
+
+include refpolicy_${PV}.inc
Signature · 1 line
1.7.10.4
#1 lore raw

I like both this and your follow-up changes, I'd been thinking it was time to do such a cleanup myself the other day. So thanks. :-)

I just had two small things. One here, one over on the common.inc file.

Quoted 15 lines · [[yocto] [meta-selinux][PATCH] Add recipe to build the MCS refpolicy.] On…

This is the default policy type used by most (all?) distros that support SELinux.

---
 .../refpolicy/refpolicy-mcs_2.20130424.bb          |   23 ++++++++++++++++++++
 1 file changed, 23 insertions(+)
 create mode 100644 recipes-security/refpolicy/refpolicy-mcs_2.20130424.bb
recipes-security/refpolicy/refpolicy-mcs_2.20130424.bb new file +0 -0
new file mode 100644
index 0000000..38b78f1

recipes-security/refpolicy/refpolicy-mcs_2.20130424.bb line 9

Quoted 9 lines
recipes-security/refpolicy/refpolicy-mcs_2.20130424.bb new file +9 -0
@@ -0,0 +1,23 @@
+SUMMARY = "MCS (Multi Category Security) variant of the SELinux policy"
+DESCRIPTION = "\
+This is the reference policy for SE Linux built with MCS support. \
+An MCS policy is the same as an MLS policy but with only one sensitivity \
+level. This is useful on systems where a hierarchical policy (MLS) isn't \
+needed (pretty much all systems) but the non-hierarchical categories are. \
+"
+
+PR = "r0"

I don't think we need this, even for the sake of clarity.

-J.

Quoted 14 lines
recipes-security/refpolicy/refpolicy-mcs_2.20130424.bb new file +14 -0
+
+POLICY_NAME = "mcs"
+POLICY_TYPE = "mcs"
+POLICY_DISTRO = "redhat"
+POLICY_UBAC = "n"
+POLICY_UNK_PERMS = "allow"
+POLICY_DIRECT_INITRC = "n"
+POLICY_MONOLITHIC = "n"
+POLICY_CUSTOM_BUILDOPT = ""
+POLICY_QUIET = "y"
+
+POLICY_MCS_CATS = "1024"
+
+include refpolicy_${PV}.inc
Signature · 2 lines
-Joe MacDonald.
:wq