Re: [PATCH v21 12/12] landlock: Add user and kernel documentation
From: Mickaël Salaün <mic@digikod.net>
Date: 2020-10-15 12:32:05
Also in:
linux-api, linux-arch, linux-doc, linux-fsdevel, linux-kselftest, lkml
On 08/10/2020 17:31, Mickaël Salaün wrote:
quoted hunk ↗ jump to hunk
From: Mickaël Salaün <redacted> This documentation can be built with the Sphinx framework. Cc: James Morris <jmorris@namei.org> Cc: Jann Horn <jannh@google.com> Cc: Kees Cook <redacted> Cc: Serge E. Hallyn <serge@hallyn.com> Signed-off-by: Mickaël Salaün <redacted> Reviewed-by: Vincent Dagonneau <redacted> --- Changes since v20: * Update examples and documentation with the new syscalls. Changes since v19: * Update examples and documentation with the new syscalls. Changes since v15: * Add current limitations. Changes since v14: * Fix spelling (contributed by Randy Dunlap). * Extend documentation about inheritance and explain layer levels. * Remove the use of now-removed access rights. * Use GitHub links. * Improve kernel documentation. * Add section for tests. * Update example. Changes since v13: * Rewrote the documentation according to the major revamp. Previous changes: https://lore.kernel.org/lkml/20191104172146.30797-8-mic@digikod.net/ (local) --- Documentation/security/index.rst | 1 + Documentation/security/landlock/index.rst | 18 ++ Documentation/security/landlock/kernel.rst | 69 ++++++ Documentation/security/landlock/user.rst | 242 +++++++++++++++++++++ 4 files changed, 330 insertions(+) create mode 100644 Documentation/security/landlock/index.rst create mode 100644 Documentation/security/landlock/kernel.rst create mode 100644 Documentation/security/landlock/user.rstdiff --git a/Documentation/security/index.rst b/Documentation/security/index.rst index 8129405eb2cc..e3f2bf4fef77 100644 --- a/Documentation/security/index.rst +++ b/Documentation/security/index.rst@@ -16,3 +16,4 @@ Security Documentation siphash tpm/index digsig + landlock/indexdiff --git a/Documentation/security/landlock/index.rst b/Documentation/security/landlock/index.rst new file mode 100644 index 000000000000..2520f8f33f5e --- /dev/null +++ b/Documentation/security/landlock/index.rst@@ -0,0 +1,18 @@ +========================================= +Landlock LSM: unprivileged access control +========================================= + +:Author: Mickaël Salaün + +The goal of Landlock is to enable to restrict ambient rights (e.g. global +filesystem access) for a set of processes. Because Landlock is a stackable +LSM, it makes possible to create safe security sandboxes as new security layers +in addition to the existing system-wide access-controls. This kind of sandbox +is expected to help mitigate the security impact of bugs or +unexpected/malicious behaviors in user-space applications. Landlock empowers +any process, including unprivileged ones, to securely restrict themselves. + +.. toctree:: + + user + kerneldiff --git a/Documentation/security/landlock/kernel.rst b/Documentation/security/landlock/kernel.rst new file mode 100644 index 000000000000..27c0933a0b6e --- /dev/null +++ b/Documentation/security/landlock/kernel.rst@@ -0,0 +1,69 @@ +============================== +Landlock: kernel documentation +==============================
Cf. https://landlock.io/linux-doc/landlock-v21/security/landlock/kernel.html I guess this is the good place for kernel API documentation.
quoted hunk ↗ jump to hunk
diff --git a/Documentation/security/landlock/user.rst b/Documentation/security/landlock/user.rst new file mode 100644 index 000000000000..e6fbc75c1af1 --- /dev/null +++ b/Documentation/security/landlock/user.rst@@ -0,0 +1,242 @@ +================================= +Landlock: userspace documentation +=================================
Cf. https://landlock.io/linux-doc/landlock-v21/security/landlock/user.html Shouldn't this go in Documentation/userspace-api/ instead? Documentation/security/lsm-development.rst says that LSM documentation should go to Documentation/admin-guide/LSM/ but this is not (like seccomp) an admin documentation. Should the Documentation/userspace-api/landlock.rst be linked from Documentation/admin-guide/LSM/index.rst too?