* [PATCH] integrity: remove __setup auditing msgs
@ 2009-05-05 17:13 Mimi Zohar
2009-05-06 1:02 ` James Morris
0 siblings, 1 reply; 2+ messages in thread
From: Mimi Zohar @ 2009-05-05 17:13 UTC (permalink / raw)
To: linux-kernel; +Cc: James Morris, david safford
Remove integrity audit messages from __setup()
Signed-off-by: Mimi Zohar <zohar@us.ibm.com>
Index: security-testing-2.6/security/integrity/ima/ima_audit.c
===================================================================
--- security-testing-2.6.orig/security/integrity/ima/ima_audit.c
+++ security-testing-2.6/security/integrity/ima/ima_audit.c
@@ -22,18 +22,9 @@ static int ima_audit;
static int __init ima_audit_setup(char *str)
{
unsigned long audit;
- int rc, result = 0;
- char *op = "ima_audit";
- char *cause;
- rc = strict_strtoul(str, 0, &audit);
- if (rc || audit > 1)
- result = 1;
- else
- ima_audit = audit;
- cause = ima_audit ? "enabled" : "not_enabled";
- integrity_audit_msg(AUDIT_INTEGRITY_STATUS, NULL, NULL,
- op, cause, result, 0);
+ if (!strict_strtoul(str, 0, &audit))
+ ima_audit = audit ? 1 : 0;
return 1;
}
__setup("ima_audit=", ima_audit_setup);
Index: security-testing-2.6/security/integrity/ima/ima_main.c
===================================================================
--- security-testing-2.6.orig/security/integrity/ima/ima_main.c
+++ security-testing-2.6/security/integrity/ima/ima_main.c
@@ -29,20 +29,8 @@ int ima_initialized;
char *ima_hash = "sha1";
static int __init hash_setup(char *str)
{
- const char *op = "hash_setup";
- const char *hash = "sha1";
- int result = 0;
- int audit_info = 0;
-
- if (strncmp(str, "md5", 3) == 0) {
- hash = "md5";
- ima_hash = str;
- } else if (strncmp(str, "sha1", 4) != 0) {
- hash = "invalid_hash_type";
- result = 1;
- }
- integrity_audit_msg(AUDIT_INTEGRITY_HASH, NULL, NULL, op, hash,
- result, audit_info);
+ if (strncmp(str, "md5", 3) == 0)
+ ima_hash = "md5";
return 1;
}
__setup("ima_hash=", hash_setup);
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] integrity: remove __setup auditing msgs
2009-05-05 17:13 [PATCH] integrity: remove __setup auditing msgs Mimi Zohar
@ 2009-05-06 1:02 ` James Morris
0 siblings, 0 replies; 2+ messages in thread
From: James Morris @ 2009-05-06 1:02 UTC (permalink / raw)
To: Mimi Zohar; +Cc: linux-kernel, david safford
On Tue, 5 May 2009, Mimi Zohar wrote:
> Remove integrity audit messages from __setup()
>
> Signed-off-by: Mimi Zohar <zohar@us.ibm.com>
All applied to
git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6#next
--
James Morris
<jmorris@namei.org>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-05-06 1:02 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-05-05 17:13 [PATCH] integrity: remove __setup auditing msgs Mimi Zohar
2009-05-06 1:02 ` James Morris
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).