lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1217611980.4000.10.camel@new-host-2>
Date:	Fri, 01 Aug 2008 13:33:00 -0400
From:	Mimi Zohar <zohar@...ux.vnet.ibm.com>
To:	Randy Dunlap <randy.dunlap@...cle.com>
Cc:	linux-next@...r.kernel.org, LKML <linux-kernel@...r.kernel.org>,
	Stephen Rothwell <sfr@...b.auug.org.au>,
	safford@...son.ibm.com, serue@...ux.vnet.ibm.com,
	sailer@...son.ibm.com, zohar@...ibm.com
Subject: Re: linux-next: Tree for July 31 (IMA build error)


Randy Dunlap <randy.dunlap@...cle.com> wrote on 08/01/2008 01:34:14 AM:
> security/integrity/ima:
> 
> linux-next-20080731/security/integrity/ima/ima_policy.c:81: error: implicit 
> declaration of function 'security_audit_rule_match'
> linux-next-20080731/security/integrity/ima/ima_policy.c:206: error: implicit 
> declaration of function 'security_audit_rule_init'
> make[4]: *** [security/integrity/ima/ima_policy.o] Error 1

- Update security/integrity/ima/Kconfig for LSM based policy rules 
  to select CONFIG_AUDIT.
- Add dummy security_filter_rule_init/match routines for when 
  CONFIG_AUDIT is not configured.

Signed-off-by: Mimi Zohar <zohar@...ibm.com>

Index: security-testing-2.6/security/integrity/ima/Kconfig
===================================================================
--- security-testing-2.6.orig/security/integrity/ima/Kconfig
+++ security-testing-2.6/security/integrity/ima/Kconfig
@@ -39,3 +39,11 @@ config IMA_BASE_HOOKS
 	default n
 	help
 	  Enable this option to allow the LSM module to enforce integrity.
+
+config IMA_LSM_BASED_RULES
+	bool "Enable LSM based measurement policy rules(requires audit)"
+	depends on IMA
+	select AUDIT
+	default y
+	help
+	  Disabling this option will not enforce LSM based policy rules.
Index: security-testing-2.6/security/integrity/ima/ima.h
===================================================================
--- security-testing-2.6.orig/security/integrity/ima/ima.h
+++ security-testing-2.6/security/integrity/ima/ima.h
@@ -145,4 +145,25 @@ struct ima_iint_cache {
 	u8 		digest[IMA_DIGEST_SIZE];
 	struct mutex mutex;
 };
+
+/* LSM based policy rules require audit */
+#ifdef CONFIG_AUDIT
+
+#define security_filter_rule_init security_audit_rule_init
+#define security_filter_rule_match security_audit_rule_match
+
+#else
+
+static inline int security_filter_rule_init(u32 field, u32 op, char *rulestr,
+					    void **lsmrule)
+{
+	return -EINVAL;
+}
+
+static inline int security_filter_rule_match(u32 secid, u32 field, u32 op,
+				   void *lsmrule, struct audit_context *actx)
+{
+	return -EINVAL;
+}
+#endif
 #endif
Index: security-testing-2.6/security/integrity/ima/ima_policy.c
===================================================================
--- security-testing-2.6.orig/security/integrity/ima/ima_policy.c
+++ security-testing-2.6/security/integrity/ima/ima_policy.c
@@ -20,9 +20,6 @@
 
 #include "ima.h"
 
-#define security_filter_rule_init security_audit_rule_init
-#define security_filter_rule_match security_audit_rule_match
-
 struct ima_measure_rule_entry {
 	struct list_head list;
 	int action;


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ