From: AKASHI Takahiro <takahiro.akashi@linaro.org>
To: "linux-audit@redhat.com" <linux-audit@redhat.com>
Cc: Will Deacon <will.deacon@arm.com>
Subject: lib/audit.c (kernel)
Date: Thu, 14 Nov 2013 14:45:51 +0900 [thread overview]
Message-ID: <5284638F.20203@linaro.org> (raw)
Hi
I'm working on audit/seccomp support for AArch64 as you see in
[0/4] arm64: Add audit support
https://www.redhat.com/archives/linux-audit/2013-November/msg00040.html
ARM sub-system maintainer asked me whether it would be possible
to re-work lib/audit.c to work with "compat" syscalls.
My question is, "Is this reasonable to think about?"
(I know all the existing architectures already have their own
implementations.)
I'd like to get any comments before going further.
One of possible solutions is
* Add lib/compat_audit.c, where
#include "asm/unistd32.h" <= it seems somewhat arch-specific.
static unsigned dir_class[] = {
...
int audit_classify_compat_syscall() {
...
static int __init audit_compat_classes_init() {
...
__initcall(audit_compat_classes_init);
* In lib/audit.c,
#include <asm/audit.h>
#include <asm/unistd.h>
...
int audit_classify_arch(arch) {
#ifdef CONFIG_COMPAT
if (audit_is_compat(arch))
return 1;
#endif
return 0;
}
int audit_classify_syscall(abi, syscall) {
#ifdef CONFIG_COMPAT
if (audit_is_compat(arch))
return audit_classify_compat_syscall(abi, syscall);
#endif
...
}
* In arch/*/include/asm/audit.h,
#inlcude <linux/audit.h>
...
#define audit_is_compat(arch) \
((arch == AUDIT_ARCH_x) || (arch == AUDIT_ARCH_y))
-Takahiro AKASHI
reply other threads:[~2013-11-14 5:47 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5284638F.20203@linaro.org \
--to=takahiro.akashi@linaro.org \
--cc=linux-audit@redhat.com \
--cc=will.deacon@arm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.