linux-security-module.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Geert Uytterhoeven <geert@linux-m68k.org>
To: Casey Schaufler <casey@schaufler-ca.com>
Cc: casey.schaufler@intel.com, paul@paul-moore.com,
	linux-security-module@vger.kernel.org, jmorris@namei.org,
	keescook@chromium.org, john.johansen@canonical.com,
	penguin-kernel@i-love.sakura.ne.jp,
	stephen.smalley.work@gmail.com, linux-kernel@vger.kernel.org,
	linux-api@vger.kernel.org, mic@digikod.net,
	linux-perf-users@vger.kernel.org
Subject: Re: [PATCH v1 8/8] lsm: wireup syscalls lsm_self_attr and lsm_module_list
Date: Wed, 26 Oct 2022 10:07:43 +0200	[thread overview]
Message-ID: <CAMuHMdVCjhLeHbDp1R3QPaY-TgTx31TBUdXq8PQeUE8OKeDP5g@mail.gmail.com> (raw)
In-Reply-To: <20221025184519.13231-9-casey@schaufler-ca.com>

Hi Casey,

CC linux-perf

On Tue, Oct 25, 2022 at 8:52 PM Casey Schaufler <casey@schaufler-ca.com> wrote:
> Wireup two syscalls for Linux Security Modules.
>
> Signed-off-by: Casey Schaufler <casey@schaufler-ca.com>

Thanks for your patch!

>  arch/m68k/kernel/syscalls/syscall.tbl               | 2 ++

Acked-by: Geert Uytterhoeven <geert@linux-m68k.org> # m68k

> --- a/arch/arm64/include/asm/unistd32.h
> +++ b/arch/arm64/include/asm/unistd32.h
> @@ -907,6 +907,8 @@ __SYSCALL(__NR_process_mrelease, sys_process_mrelease)
>  __SYSCALL(__NR_futex_waitv, sys_futex_waitv)
>  #define __NR_set_mempolicy_home_node 450
>  __SYSCALL(__NR_set_mempolicy_home_node, sys_set_mempolicy_home_node)
> +#define __NR_lsm_attr_set 451
> +__SYSCALL(__NR_lsm_attr_set, sys_lsm_attr_set)

Missing lsm_module_list.

>
>  /*
>   * Please add new compat syscalls above this comment and update

> --- a/include/uapi/asm-generic/unistd.h
> +++ b/include/uapi/asm-generic/unistd.h
> @@ -886,8 +886,11 @@ __SYSCALL(__NR_futex_waitv, sys_futex_waitv)
>  #define __NR_set_mempolicy_home_node 450
>  __SYSCALL(__NR_set_mempolicy_home_node, sys_set_mempolicy_home_node)
>
> +#define __NR_lsm_self_attr 451
> +__SYSCALL(__NR_lsm_self_attr, sys_lsm_self_attr)

Missing lsm_module_list.

> +
>  #undef __NR_syscalls
> -#define __NR_syscalls 451
> +#define __NR_syscalls 452

Hence one off.

> --- a/tools/perf/arch/mips/entry/syscalls/syscall_n64.tbl
> +++ b/tools/perf/arch/mips/entry/syscalls/syscall_n64.tbl
> @@ -365,3 +365,5 @@
>  448    n64     process_mrelease                sys_process_mrelease
>  449    n64     futex_waitv                     sys_futex_waitv
>  450    common  set_mempolicy_home_node         sys_set_mempolicy_home_node
> +451    n64     lsm_self_attr                   sys_lsm_self_attr
> +452    n64     lsm_module_list                 sys_lsm_module_list
> diff --git a/tools/perf/arch/powerpc/entry/syscalls/syscall.tbl b/tools/perf/arch/powerpc/entry/syscalls/syscall.tbl
> index 2bca64f96164..7b779080acbe 100644
> --- a/tools/perf/arch/powerpc/entry/syscalls/syscall.tbl
> +++ b/tools/perf/arch/powerpc/entry/syscalls/syscall.tbl
> @@ -530,3 +530,5 @@
>  448    common  process_mrelease                sys_process_mrelease
>  449    common  futex_waitv                     sys_futex_waitv
>  450    nospu   set_mempolicy_home_node         sys_set_mempolicy_home_node
> +451    common  lsm_self_attr                   sys_lsm_self_attr
> +452    common  lsm_module_list                 sys_lsm_module_list
> diff --git a/tools/perf/arch/s390/entry/syscalls/syscall.tbl b/tools/perf/arch/s390/entry/syscalls/syscall.tbl
> index 799147658dee..eaba1ed5654e 100644
> --- a/tools/perf/arch/s390/entry/syscalls/syscall.tbl
> +++ b/tools/perf/arch/s390/entry/syscalls/syscall.tbl
> @@ -453,3 +453,5 @@
>  448  common    process_mrelease        sys_process_mrelease            sys_process_mrelease
>  449  common    futex_waitv             sys_futex_waitv                 sys_futex_waitv
>  450  common    set_mempolicy_home_node sys_set_mempolicy_home_node     sys_set_mempolicy_home_node
> +451  common    lsm_self_attr           sys_lsm_self_attr       sys_lsm_self_attr
> +452  common    lsm_module_list         sys_lsm_module_list     sys_lsm_module_list
> diff --git a/tools/perf/arch/x86/entry/syscalls/syscall_64.tbl b/tools/perf/arch/x86/entry/syscalls/syscall_64.tbl
> index c84d12608cd2..40b35e7069a7 100644
> --- a/tools/perf/arch/x86/entry/syscalls/syscall_64.tbl
> +++ b/tools/perf/arch/x86/entry/syscalls/syscall_64.tbl
> @@ -372,6 +372,8 @@
>  448    common  process_mrelease        sys_process_mrelease
>  449    common  futex_waitv             sys_futex_waitv
>  450    common  set_mempolicy_home_node sys_set_mempolicy_home_node
> +451    common  lsm_self_attr           sys_lsm_self_attr
> +452    common  lsm_module_list         sys_lsm_module_list

BTW, why are the syscall tables not shared between arch/ and tools/perf/?
They seem to be identical (except for ppc due to 32/64 vs. common)?

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

  reply	other threads:[~2022-10-26  8:08 UTC|newest]

Thread overview: 47+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20221025184519.13231-1-casey.ref@schaufler-ca.com>
2022-10-25 18:45 ` [PATCH v1 0/8] LSM: Two basic syscalls Casey Schaufler
2022-10-25 18:45   ` [PATCH v1 1/8] LSM: Identify modules by more than name Casey Schaufler
2022-10-26  5:56     ` Greg KH
2022-10-25 18:45   ` [PATCH v1 2/8] LSM: Add an LSM identifier for external use Casey Schaufler
2022-10-26  5:58     ` Greg KH
2022-10-26 19:36       ` Casey Schaufler
2022-10-27  0:11         ` Tetsuo Handa
2022-10-27  6:31         ` Greg KH
2022-10-28 16:54           ` Casey Schaufler
2022-11-09 23:33             ` Paul Moore
2022-11-10  0:57               ` Casey Schaufler
2022-11-10  2:37                 ` Paul Moore
2022-11-09 23:33     ` Paul Moore
2022-11-10  0:46       ` Casey Schaufler
2022-10-25 18:45   ` [PATCH v1 3/8] LSM: Identify the process attributes for each module Casey Schaufler
2022-10-26  5:59     ` Greg KH
2022-11-09 23:34     ` Paul Moore
2022-11-10  1:03       ` Casey Schaufler
2022-11-10  2:39         ` Paul Moore
2022-10-25 18:45   ` [PATCH v1 4/8] LSM: Maintain a table of LSM attribute data Casey Schaufler
2022-10-26  6:00     ` Greg KH
2022-10-27  0:38       ` Casey Schaufler
2022-10-27  6:29         ` Greg KH
2022-10-27 17:08           ` Casey Schaufler
2022-10-27 17:13             ` Greg KH
2022-11-09 23:34               ` Paul Moore
2022-10-25 18:45   ` [PATCH v1 5/8] proc: Use lsmids instead of lsm names for attrs Casey Schaufler
2022-10-25 18:45   ` [PATCH v1 6/8] LSM: lsm_self_attr syscall for LSM self attributes Casey Schaufler
2022-10-26  6:03     ` Greg KH
2022-10-26  7:01     ` kernel test robot
2022-10-26  8:14     ` kernel test robot
2022-10-26  9:33     ` kernel test robot
2022-11-09 23:34     ` Paul Moore
2022-11-10  1:32       ` Casey Schaufler
2022-11-10  3:02         ` Paul Moore
2022-11-10 23:36       ` Paul Moore
2022-11-11  0:36         ` Casey Schaufler
2022-11-11  3:16           ` Paul Moore
2022-10-25 18:45   ` [PATCH v1 7/8] LSM: Create lsm_module_list system call Casey Schaufler
2022-10-26  6:02     ` Greg KH
2022-10-26 12:07     ` kernel test robot
2022-11-09 23:35     ` Paul Moore
2022-11-10  1:37       ` Casey Schaufler
2022-11-10  3:17         ` Paul Moore
2022-10-25 18:45   ` [PATCH v1 8/8] lsm: wireup syscalls lsm_self_attr and lsm_module_list Casey Schaufler
2022-10-26  8:07     ` Geert Uytterhoeven [this message]
2022-11-23 19:57 [PATCH v1 0/8] LSM: Two basic syscalls Casey Schaufler
2022-11-23 19:57 ` [PATCH v1 8/8] lsm: wireup syscalls lsm_self_attr and lsm_module_list Casey Schaufler

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=CAMuHMdVCjhLeHbDp1R3QPaY-TgTx31TBUdXq8PQeUE8OKeDP5g@mail.gmail.com \
    --to=geert@linux-m68k.org \
    --cc=casey.schaufler@intel.com \
    --cc=casey@schaufler-ca.com \
    --cc=jmorris@namei.org \
    --cc=john.johansen@canonical.com \
    --cc=keescook@chromium.org \
    --cc=linux-api@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=linux-security-module@vger.kernel.org \
    --cc=mic@digikod.net \
    --cc=paul@paul-moore.com \
    --cc=penguin-kernel@i-love.sakura.ne.jp \
    --cc=stephen.smalley.work@gmail.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 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).