From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755903AbbCFPl2 (ORCPT ); Fri, 6 Mar 2015 10:41:28 -0500 Received: from mail-wi0-f173.google.com ([209.85.212.173]:46886 "EHLO mail-wi0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755718AbbCFPlS (ORCPT ); Fri, 6 Mar 2015 10:41:18 -0500 From: David Drysdale To: Brian Gerst , Ingo Molnar Cc: "H. Peter Anvin" , AKASHI Takahiro , Richard Guy Briggs , Eric Paris , Paul Moore , stable@vger.kernel.org, linux-audit@redhat.com, linux-kernel@vger.kernel.org, David Drysdale Subject: [PATCH 2/2] audit,x86: add x32_execve[at] to syscall classification Date: Fri, 6 Mar 2015 15:40:38 +0000 Message-Id: <1425656438-3884-3-git-send-email-drysdale@google.com> X-Mailer: git-send-email 2.2.0.rc0.207.ga3a616c In-Reply-To: <1425656438-3884-1-git-send-email-drysdale@google.com> References: <1425656438-3884-1-git-send-email-drysdale@google.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Treat x32 ABI variants of execve[at] the same as x86_64 variants. Slightly speculative as the audit subsystem doesn't currently work with x32 ABI syscalls. If and when audit+x32 does work, this should correctly classify exec calls. Signed-off-by: David Drysdale --- arch/x86/kernel/audit_64.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/arch/x86/kernel/audit_64.c b/arch/x86/kernel/audit_64.c index f3672508b249..0aec72d8d3c7 100644 --- a/arch/x86/kernel/audit_64.c +++ b/arch/x86/kernel/audit_64.c @@ -49,6 +49,12 @@ int audit_classify_syscall(int abi, unsigned syscall) return 2; case __NR_openat: return 3; +#ifdef __NR_x32_execve + case __NR_x32_execve: +#endif +#ifdef __NR_x32_execveat + case __NR_x32_execveat: +#endif case __NR_execve: case __NR_execveat: return 5; -- 1.9.1