From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 80F36C433F5 for ; Fri, 1 Oct 2021 19:53:33 +0000 (UTC) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id DF79B61A58 for ; Fri, 1 Oct 2021 19:53:32 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org DF79B61A58 Authentication-Results: mail.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1633118011; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=Yevxa/Ck3XlbaIjscl4swRFt3AEowb3IyWYEejdSK6Y=; b=hub3z2kjNt/wOgXBW2o0LrGd2kMovCEqSwAWnK8PbkIPcNz2WTtDLD/Vpuws/HYNPIJV+w wtzPuYjvqAyBGYBcZygKRKUyFWHZzfz+KIlXcTBhIzVyuO+xK1w5rEcnc6aagpPKwytU2r 3FLbMI2/h6h3zQrqOwFn3BcaoqtqJW0= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-399-p8lTx4CKM1u8iH35bhYyEA-1; Fri, 01 Oct 2021 15:53:30 -0400 X-MC-Unique: p8lTx4CKM1u8iH35bhYyEA-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 0B74DDF8A3; Fri, 1 Oct 2021 19:53:27 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 1EA3917CF0; Fri, 1 Oct 2021 19:53:26 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 7CA141800B8B; Fri, 1 Oct 2021 19:53:23 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 191JrKYM012072 for ; Fri, 1 Oct 2021 15:53:20 -0400 Received: by smtp.corp.redhat.com (Postfix) id E955B18A66; Fri, 1 Oct 2021 19:53:20 +0000 (UTC) Received: from madcap2.tricolour.ca (unknown [10.3.128.4]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 75A6A5DEFB; Fri, 1 Oct 2021 19:53:09 +0000 (UTC) Date: Fri, 1 Oct 2021 15:53:06 -0400 From: Richard Guy Briggs To: Paul Moore Subject: Re: [PATCH v4 1/3] audit: replace magic audit syscall class numbers with macros Message-ID: <20211001195306.GC3977594@madcap2.tricolour.ca> References: <2300b1083a32aade7ae7efb95826e8f3f260b1df.1621363275.git.rgb@redhat.com> MIME-Version: 1.0 In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-loop: linux-audit@redhat.com Cc: Linux-Audit Mailing List X-BeenThere: linux-audit@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Linux Audit Discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-audit-bounces@redhat.com Errors-To: linux-audit-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=linux-audit-bounces@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Disposition: inline Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit On 2021-09-30 16:38, Paul Moore wrote: > On Thu, Aug 5, 2021 at 6:01 PM Paul Moore wrote: > > On Wed, May 19, 2021 at 4:01 PM Richard Guy Briggs wrote: > > > Replace audit syscall class magic numbers with macros. > > > > > > This required putting the macros into new header file > > > include/linux/auditsc_classmacros.h since the syscall macros were > > > included for both 64 bit and 32 bit in any compat code, causing > > > redefinition warnings. > > > > > > Signed-off-by: Richard Guy Briggs > > > Link: https://lore.kernel.org/r/2300b1083a32aade7ae7efb95826e8f3f260b1df.1621363275.git.rgb@redhat.com > > > --- > > > MAINTAINERS | 1 + > > > arch/alpha/kernel/audit.c | 8 ++++---- > > > arch/ia64/kernel/audit.c | 8 ++++---- > > > arch/parisc/kernel/audit.c | 8 ++++---- > > > arch/parisc/kernel/compat_audit.c | 9 +++++---- > > > arch/powerpc/kernel/audit.c | 10 +++++----- > > > arch/powerpc/kernel/compat_audit.c | 11 ++++++----- > > > arch/s390/kernel/audit.c | 10 +++++----- > > > arch/s390/kernel/compat_audit.c | 11 ++++++----- > > > arch/sparc/kernel/audit.c | 10 +++++----- > > > arch/sparc/kernel/compat_audit.c | 11 ++++++----- > > > arch/x86/ia32/audit.c | 11 ++++++----- > > > arch/x86/kernel/audit_64.c | 8 ++++---- > > > include/linux/audit.h | 1 + > > > include/linux/auditsc_classmacros.h | 23 +++++++++++++++++++++++ > > > kernel/auditsc.c | 12 ++++++------ > > > lib/audit.c | 10 +++++----- > > > lib/compat_audit.c | 11 ++++++----- > > > 18 files changed, 102 insertions(+), 71 deletions(-) > > > create mode 100644 include/linux/auditsc_classmacros.h > > > > ... > > > > > diff --git a/include/linux/auditsc_classmacros.h b/include/linux/auditsc_classmacros.h > > > new file mode 100644 > > > index 000000000000..18757d270961 > > > --- /dev/null > > > +++ b/include/linux/auditsc_classmacros.h > > > @@ -0,0 +1,23 @@ > > > +/* SPDX-License-Identifier: GPL-2.0-or-later */ > > > +/* auditsc_classmacros.h -- Auditing support syscall macros > > > + * > > > + * Copyright 2021 Red Hat Inc., Durham, North Carolina. > > > + * All Rights Reserved. > > > + * > > > + * Author: Richard Guy Briggs > > > + */ > > > +#ifndef _LINUX_AUDITSCM_H_ > > > +#define _LINUX_AUDITSCM_H_ > > > + > > > +enum auditsc_class_t { > > > + AUDITSC_NATIVE = 0, > > > + AUDITSC_COMPAT, > > > + AUDITSC_OPEN, > > > + AUDITSC_OPENAT, > > > + AUDITSC_SOCKETCALL, > > > + AUDITSC_EXECVE, > > > + > > > + AUDITSC_NVALS /* count */ > > > +}; > > > + > > > +#endif > > > > My apologies Richard, for some reason I had it in my mind that this > > series was waiting on you to answer a question and/or respin; however, > > now that I'm clearing my patch queues looking for any stragglers I see > > that isn't the case. Looking over the patchset I think it looks okay > > to me, my only concern is that "auditsc_classmacros.h" is an awfully > > specific header file name and could prove to be annoying if we want to > > add to it in the future. What do you think about something like > > "audit_arch.h" instead? > > > > If that change is okay with you I can go ahead and do the rename while > > I'm merging the patches, I'll consider it penance for letting this > > patchset sit for so long :/ > > [NOTE: trimmed the To/CC line as it is excessive for a ping like this] > > Going through the patch queue and I see this never got a response, or > rather none that hit my inbox. Richard? Hmmm, sorry about that, delay my fault this time. I don't have a strong opinion about it, but prefer the original, or auditsc_arch.h at least. > paul moore - RGB -- Richard Guy Briggs Sr. S/W Engineer, Kernel Security, Base Operating Systems Remote, Ottawa, Red Hat Canada IRC: rgb, SunRaycer Voice: +1.647.777.2635, Internal: (81) 32635 -- Linux-audit mailing list Linux-audit@redhat.com https://listman.redhat.com/mailman/listinfo/linux-audit