# SOME DESCRIPTIVE TITLE # Copyright (C) YEAR Free Software Foundation, Inc. # This file is distributed under the same license as the PACKAGE package. # FIRST AUTHOR , YEAR. # #, fuzzy msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "POT-Creation-Date: 2024-06-01 06:20+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" "Language: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" #. type: TH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "seccomp" msgstr "" #. type: TH #: archlinux debian-unstable opensuse-tumbleweed #, no-wrap msgid "2024-05-02" msgstr "" #. type: TH #: archlinux debian-unstable #, no-wrap msgid "Linux man-pages 6.8" msgstr "" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "NAME" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "seccomp - operate on Secure Computing state of the process" msgstr "" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "LIBRARY" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Standard C library (I, I<-lc>)" msgstr "" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "SYNOPSIS" msgstr "" #. Kees Cook noted: Anything that uses SECCOMP_RET_TRACE returns will #. need #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "B<#include Elinux/seccomp.hE> /* Definition of B constants */\n" "B<#include Elinux/filter.hE> /* Definition of B */\n" "B<#include Elinux/audit.hE> /* Definition of B constants */\n" "B<#include Elinux/signal.hE> /* Definition of B constants */\n" "B<#include Esys/ptrace.hE> /* Definition of B constants */\n" "B<#include Esys/syscall.hE> /* Definition of B constants */\n" "B<#include Eunistd.hE>\n" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "BIB<, unsigned int >IB<,>\n" "B< void *>IB<);>\n" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "I: glibc provides no wrapper for B(), necessitating the use " "of B(2)." msgstr "" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "DESCRIPTION" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B() system call operates on the Secure Computing (seccomp) " "state of the calling process." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Currently, Linux supports the following I values:" msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The only system calls that the calling thread is permitted to make are " "B(2), B(2), B<_exit>(2) (but not B(2)), and " "B(2). Other system calls result in the termination of the " "calling thread, or termination of the entire process with the B " "signal when there is only one thread. Strict secure computing mode is " "useful for number-crunching applications that may need to execute untrusted " "byte code, perhaps obtained by reading from a pipe or socket." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Note that although the calling thread can no longer call B(2), " "it can use B(2) to block all signals apart from B and " "B. This means that B(2) (for example) is not sufficient " "for restricting the process's execution time. Instead, to reliably " "terminate the process, B must be used. This can be done by using " "B(2) with B and I set to " "B, or by using B(2) to set the hard limit for " "B." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "This operation is available only if the kernel is configured with " "B enabled." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "The value of I must be 0, and I must be NULL." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "This operation is functionally identical to the call:" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "prctl(PR_SET_SECCOMP, SECCOMP_MODE_STRICT);\n" msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The system calls allowed are defined by a pointer to a Berkeley Packet " "Filter (BPF) passed via I. This argument is a pointer to a I; it can be designed to filter arbitrary system calls and system " "call arguments. If the filter is invalid, B() fails, returning " "B in I." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "If B(2) or B(2) is allowed by the filter, any child processes " "will be constrained to the same system call filters as the parent. If " "B(2) is allowed, the existing filters will be preserved across a " "call to B(2)." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "In order to use the B operation, either the calling " "thread must have the B capability in its user namespace, or " "the thread must already have the I bit set. If that bit was " "not already set by an ancestor of this thread, the thread must make the " "following call:" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "prctl(PR_SET_NO_NEW_PRIVS, 1);\n" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Otherwise, the B operation fails and returns " "B in I. This requirement ensures that an unprivileged " "process cannot apply a malicious filter and then invoke a set-user-ID or " "other privileged program using B(2), thus potentially compromising " "that program. (Such a malicious filter might, for example, cause an attempt " "to use B(2) to set the caller's user IDs to nonzero values to " "instead return 0 without actually making the system call. Thus, the program " "might be tricked into retaining superuser privileges in circumstances where " "it is possible to influence it to do dangerous things because it did not " "actually drop privileges.)" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "If B(2) or B() is allowed by the attached filter, further " "filters may be added. This will increase evaluation time, but allows for " "further reduction of the attack surface during execution of a thread." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B operation is available only if the kernel is " "configured with B enabled." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "When I is 0, this operation is functionally identical to the call:" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, args);\n" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "The recognized I are:" msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B (since Linux 4.14)" msgstr "" #. commit e66a39977985b1e69e17c4042cb290768eca9b02 #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "All filter return actions except B should be logged. An " "administrator may override this filter flag by preventing specific actions " "from being logged via the I file." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B (since Linux 5.0)" msgstr "" #. commit 6a21cc50f0c7f87dae5259f6cfefe024412313f6 #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "After successfully installing the filter program, return a new user-space " "notification file descriptor. (The close-on-exec flag is set for the file " "descriptor.) When the filter returns B a " "notification will be sent to this file descriptor." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "At most one seccomp filter using the B " "flag can be installed for a thread." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "See B(2) for further details." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B (since Linux 4.17)" msgstr "" #. commit 00a02d0c502a06d15e07b857f8ff921e3e402675 #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Disable Speculative Store Bypass mitigation." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "When adding a new filter, synchronize all other threads of the calling " "process to the same seccomp filter tree. A \"filter tree\" is the ordered " "list of filters attached to a thread. (Attaching identical filters in " "separate B() calls results in different filters from this " "perspective.)" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "If any thread cannot synchronize to the same filter tree, the call will not " "attach the new seccomp filter, and will fail, returning the first thread ID " "found that cannot synchronize. Synchronization will fail if another thread " "in the same process is in B or if it has attached new " "seccomp filters to itself, diverging from the calling thread's filter tree." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B (since Linux 4.14)" msgstr "" #. commit d612b1fd8010d0d67b5287fe146b8b55bcbb8655 #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Test to see if an action is supported by the kernel. This operation is " "helpful to confirm that the kernel knows of a more recently added filter " "return action since the kernel treats all unknown actions as " "B." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The value of I must be 0, and I must be a pointer to an " "unsigned 32-bit filter return action." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B (since Linux 5.0)" msgstr "" #. commit 6a21cc50f0c7f87dae5259f6cfefe024412313f6 #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Get the sizes of the seccomp user-space notification structures. Since " "these structures may evolve and grow over time, this command can be used to " "determine how much memory to allocate for sending and receiving " "notifications." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The value of I must be 0, and I must be a pointer to a I, which has the following form:" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "struct seccomp_notif_sizes\n" " __u16 seccomp_notif; /* Size of notification structure */\n" " __u16 seccomp_notif_resp; /* Size of response structure */\n" " __u16 seccomp_data; /* Size of \\[aq]struct seccomp_data\\[aq] */\n" "};\n" msgstr "" #. type: SS #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "Filters" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "When adding filters via B, I points to a " "filter program:" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "struct sock_fprog {\n" " unsigned short len; /* Number of BPF instructions */\n" " struct sock_filter *filter; /* Pointer to array of\n" " BPF instructions */\n" "};\n" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Each program must contain one or more BPF instructions:" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "struct sock_filter { /* Filter block */\n" " __u16 code; /* Actual filter code */\n" " __u8 jt; /* Jump true */\n" " __u8 jf; /* Jump false */\n" " __u32 k; /* Generic multiuse field */\n" "};\n" msgstr "" #. Quoting Kees Cook: #. If BPF even allows changing the data, it's not copied back to #. the syscall when it runs. Anything wanting to do things like #. that would need to use ptrace to catch the call and directly #. modify the registers before continuing with the call. #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "When executing the instructions, the BPF program operates on the system call " "information made available (i.e., use the B addressing mode) as a " "(read-only) buffer of the following form:" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "struct seccomp_data {\n" " int nr; /* System call number */\n" " __u32 arch; /* AUDIT_ARCH_* value\n" " (see Elinux/audit.hE) */\n" " __u64 instruction_pointer; /* CPU instruction pointer */\n" " __u64 args[6]; /* Up to 6 system call arguments */\n" "};\n" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Because numbering of system calls varies between architectures and some " "architectures (e.g., x86-64) allow user-space code to use the calling " "conventions of multiple architectures (and the convention being used may " "vary over the life of a process that uses B(2) to execute binaries " "that employ the different conventions), it is usually necessary to verify " "the value of the I field." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "It is strongly recommended to use an allow-list approach whenever possible " "because such an approach is more robust and simple. A deny-list will have " "to be updated whenever a potentially dangerous system call is added (or a " "dangerous flag or option if those are deny-listed), and it is often possible " "to alter the representation of a value without altering its meaning, leading " "to a deny-list bypass. See also I below." msgstr "" # #. As noted by Dave Drysdale in a note at the end of #. https://lwn.net/Articles/604515/ #. One additional detail to point out for the x32 ABI case: #. the syscall number gets a high bit set (__X32_SYSCALL_BIT), #. to mark it as an x32 call. #. If x32 support is included in the kernel, then __SYSCALL_MASK #. will have a value that is not all-ones, and this will trigger #. an extra instruction in system_call to mask off the extra bit, #. so that the syscall table indexing still works. #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The I field is not unique for all calling conventions. The x86-64 ABI " "and the x32 ABI both use B as I, and they run on " "the same processors. Instead, the mask B<__X32_SYSCALL_BIT> is used on the " "system call number to tell the two ABIs apart." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "This means that a policy must either deny all syscalls with " "B<__X32_SYSCALL_BIT> or it must recognize syscalls with and without " "B<__X32_SYSCALL_BIT> set. A list of system calls to be denied based on " "I that does not also contain I values with B<__X32_SYSCALL_BIT> set " "can be bypassed by a malicious program that sets B<__X32_SYSCALL_BIT>." msgstr "" #. commit 6365b842aae4490ebfafadfc6bb27a6d3cc54757 #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Additionally, kernels prior to Linux 5.4 incorrectly permitted I in the " "ranges 512-547 as well as the corresponding non-x32 syscalls ORed with " "B<__X32_SYSCALL_BIT>. For example, I == 521 and I == (101 | " "B<__X32_SYSCALL_BIT>) would result in invocations of B(2) with " "potentially confused x32-vs-x86_64 semantics in the kernel. Policies " "intended to work on kernels before Linux 5.4 must ensure that they deny or " "otherwise correctly handle these system calls. On Linux 5.4 and newer, such " "system calls will fail with the error B, without doing anything." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The I field provides the address of the machine-" "language instruction that performed the system call. This might be useful " "in conjunction with the use of IpidI to perform checks based " "on which region (mapping) of the program made the system call. (Probably, " "it is wise to lock down the B(2) and B(2) system calls to " "prevent the program from subverting such checks.)" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "When checking values from I, keep in mind that arguments are often " "silently truncated before being processed, but after the seccomp check. For " "example, this happens if the i386 ABI is used on an x86-64 kernel: although " "the kernel will normally not look beyond the 32 lowest bits of the " "arguments, the values of the full 64-bit registers will be present in the " "seccomp data. A less surprising example is that if the x86-64 ABI is used " "to perform a system call that takes an argument of type I, the more-" "significant half of the argument register is ignored by the system call, but " "visible in the seccomp data." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "A seccomp filter returns a 32-bit value consisting of two parts: the most " "significant 16 bits (corresponding to the mask defined by the constant " "B) contain one of the \"action\" values listed " "below; the least significant 16-bits (defined by the constant " "B) are \"data\" to be associated with this return value." msgstr "" # #. From an Aug 2015 conversation with Kees Cook where I asked why *all* #. filters are applied even if one of the early filters returns #. SECCOMP_RET_KILL: #. It's just because it would be an optimization that would only speed up #. the RET_KILL case, but it's the uncommon one and the one that doesn't #. benefit meaningfully from such a change (you need to kill the process #. really quickly?). We would speed up killing a program at the (albeit #. tiny) expense to all other filtered programs. Best to keep the filter #. execution logic clear, simple, and as fast as possible for all #. filters. #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "If multiple filters exist, they are I executed, in reverse order of " "their addition to the filter tree\\[em]that is, the most recently installed " "filter is executed first. (Note that all filters will be called even if one " "of the earlier filters returns B. This is done to " "simplify the kernel code and to provide a tiny speed-up in the execution of " "sets of filters by avoiding a check for this uncommon case.) The return " "value for the evaluation of a given system call is the first-seen action " "value of highest precedence (along with its accompanying data) returned by " "execution of all of the filters." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "In decreasing order of precedence, the action values that may be returned by " "a seccomp filter are:" msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B (since Linux 4.14)" msgstr "" #. commit 4d3b0b05aae9ee9ce0970dc4cc0fb3fad5e85945 #. commit 0466bdb99e8744bc9befa8d62a317f0fd7fd7421 #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "This value results in immediate termination of the process, with a core " "dump. The system call is not executed. By contrast with " "B below, all threads in the thread group are " "terminated. (For a discussion of thread groups, see the description of the " "B flag in B(2).)" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The process terminates I killed by a B signal. Even if a " "signal handler has been registered for B, the handler will be " "ignored in this case and the process always terminates. To a parent process " "that is waiting on this process (using B(2) or similar), the " "returned I will indicate that its child was terminated as though by " "a B signal." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B (or B)" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "This value results in immediate termination of the thread that made the " "system call. The system call is not executed. Other threads in the same " "thread group will continue to execute." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The thread terminates I killed by a B signal. See " "B above." msgstr "" #. See these commits: #. seccomp: dump core when using SECCOMP_RET_KILL #. (b25e67161c295c98acda92123b2dd1e7d8642901) #. seccomp: Only dump core when single-threaded #. (d7276e321ff8a53106a59c85ca46d03e34288893) #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Before Linux 4.11, any process terminated in this way would not trigger a " "coredump (even though B is documented in B(7) as having a " "default action of termination with a core dump). Since Linux 4.11, a single-" "threaded process will dump core if terminated in this way." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "With the addition of B in Linux 4.14, " "B was added as a synonym for B, " "in order to more clearly distinguish the two actions." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "B: the use of B to kill a single thread in a " "multithreaded process is likely to leave the process in a permanently " "inconsistent and possibly corrupt state." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "This value results in the kernel sending a thread-directed B signal " "to the triggering thread. (The system call is not executed.) Various " "fields will be set in the I structure (see B(2)) " "associated with signal:" msgstr "" #. type: IP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "\\[bu]" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "I will contain B." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "I will show the address of the system call instruction." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "I and I will indicate which system call was attempted." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "I will contain B." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "I will contain the B portion of the filter " "return value." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The program counter will be as though the system call happened (i.e., the " "program counter will not point to the system call instruction). The return " "value register will contain an architecture-dependent value; if resuming " "execution, set it to something appropriate for the system call. (The " "architecture dependency is because replacing it with B could " "overwrite some useful information.)" msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "This value results in the B portion of the filter's return " "value being passed to user space as the I value without executing the " "system call." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B (since Linux 5.0)" msgstr "" #. commit 6a21cc50f0c7f87dae5259f6cfefe024412313f6 #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Forward the system call to an attached user-space supervisor process to " "allow that process to decide what to do with the system call. If there is " "no attached supervisor (either because the filter was not installed with the " "B flag or because the file descriptor was " "closed), the filter returns B (similar to what happens when a filter " "returns B and there is no tracer). See " "B(2) for further details." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Note that the supervisor process will not be notified if another filter " "returns an action value with a precedence greater than " "B." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "When returned, this value will cause the kernel to attempt to notify a " "B(2)-based tracer prior to executing the system call. If there is " "no tracer present, the system call is not executed and returns a failure " "status with I set to B." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "A tracer will be notified if it requests B using " "I. The tracer will be notified of a " "B and the B portion of the filter's " "return value will be available to the tracer via B." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The tracer can skip the system call by changing the system call number to " "-1. Alternatively, the tracer can change the system call requested by " "changing the system call to a valid system call number. If the tracer asks " "to skip the system call, then the system call will appear to return the " "value that the tracer puts in the return value register." msgstr "" #. This was changed in ce6526e8afa4. #. A related hole, using PTRACE_SYSCALL instead of SECCOMP_RET_TRACE, was #. changed in arch-specific commits, e.g. 93e35efb8de4 for X86 and #. 0f3912fd934c for ARM. #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Before Linux 4.8, the seccomp check will not be run again after the tracer " "is notified. (This means that, on older kernels, seccomp-based sandboxes " "B allow use of B(2)\\[em]even of other sandboxed " "processes\\[em]without extreme care; ptracers can use this mechanism to " "escape from the seccomp sandbox.)" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Note that a tracer process will not be notified if another filter returns an " "action value with a precedence greater than B." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B (since Linux 4.14)" msgstr "" #. commit 59f5cf44a38284eb9e76270c786fb6cc62ef8ac4 #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "This value results in the system call being executed after the filter return " "action is logged. An administrator may override the logging of this action " "via the I file." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "This value results in the system call being executed." msgstr "" #. commit 4d3b0b05aae9ee9ce0970dc4cc0fb3fad5e85945 #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "If an action value other than one of the above is specified, then the filter " "action is treated as either B (since Linux 4.14) " "or B (in Linux 4.13 and earlier)." msgstr "" #. type: SS #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "/proc interfaces" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The files in the directory I provide additional " "seccomp information and configuration:" msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "I (since Linux 4.14)" msgstr "" #. commit 8e5f1ad116df6b0de65eac458d5e7c318d1c05af #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "A read-only ordered list of seccomp filter return actions in string form. " "The ordering, from left-to-right, is in decreasing order of precedence. The " "list represents the set of seccomp filter return actions supported by the " "kernel." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "I (since Linux 4.14)" msgstr "" #. commit 0ddec0fc8900201c0897b87b762b7c420436662f #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "A read-write ordered list of seccomp filter return actions that are allowed " "to be logged. Writes to the file do not need to be in ordered form but " "reads from the file will be ordered in the same way as the I " "file." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "It is important to note that the value of I does not prevent " "certain filter return actions from being logged when the audit subsystem is " "configured to audit a task. If the action is not found in the " "I file, the final decision on whether to audit the action " "for that task is ultimately left up to the audit subsystem to decide for all " "filter return actions other than B." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The \"allow\" string is not accepted in the I file as it is " "not possible to log B actions. Attempting to write " "\"allow\" to the file will fail with the error B." msgstr "" #. type: SS #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "Audit logging of seccomp actions" msgstr "" #. commit 59f5cf44a38284eb9e76270c786fb6cc62ef8ac4 #. or auditing could be enabled via the netlink API (AUDIT_SET) #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Since Linux 4.14, the kernel provides the facility to log the actions " "returned by seccomp filters in the audit log. The kernel makes the decision " "to log an action based on the action type, whether or not the action is " "present in the I file, and whether kernel auditing is " "enabled (e.g., via the kernel boot option I). The rules are as " "follows:" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "If the action is B, the action is not logged." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Otherwise, if the action is either B or " "B, and that action appears in the I " "file, the action is logged." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Otherwise, if the filter has requested logging (the " "B flag) and the action appears in the " "I file, the action is logged." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Otherwise, if kernel auditing is enabled and the process is being audited " "(B(8)), the action is logged." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Otherwise, the action is not logged." msgstr "" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "RETURN VALUE" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "On success, B() returns 0. On error, if " "B was used, the return value is the ID of the " "thread that caused the synchronization failure. (This ID is a kernel thread " "ID of the type returned by B(2) and B(2).) On other errors, " "-1 is returned, and I is set to indicate the error." msgstr "" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "ERRORS" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "B() can fail for the following reasons:" msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The caller did not have the B capability in its user " "namespace, or had not set I before using " "B." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "While installing a new filter, the B flag " "was specified, but a previous filter had already been installed with that " "flag." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "I was not a valid address." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "I is unknown or is not supported by this kernel version or " "configuration." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "The specified I are invalid for the given I." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "I included B, but the specified offset was not aligned " "to a 32-bit boundary or exceeded I." msgstr "" #. See kernel/seccomp.c::seccomp_may_assign_mode() in Linux 3.18 sources #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "A secure computing mode has already been set, and I differs from " "the existing setting." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "I specified B, but the filter program " "pointed to by I was not valid or the length of the filter program was " "zero or exceeded B (4096) instructions." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Out of memory." msgstr "" #. ENOMEM in kernel/seccomp.c::seccomp_attach_filter() in Linux 3.18 sources #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The total length of all filter programs attached to the calling thread would " "exceed B (32768) instructions. Note that for the " "purposes of calculating this limit, each already existing filter program " "incurs an overhead penalty of 4 instructions." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "I specified B, but the kernel does not " "support the filter return action specified by I." msgstr "" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Another thread caused a failure during thread sync, but its ID could not be " "determined." msgstr "" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "STANDARDS" msgstr "" #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-leap-15-6 opensuse-tumbleweed msgid "Linux." msgstr "" #. type: SH #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "HISTORY" msgstr "" #. FIXME . Add glibc version #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-leap-15-6 opensuse-tumbleweed msgid "Linux 3.17." msgstr "" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "NOTES" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Rather than hand-coding seccomp filters as shown in the example below, you " "may prefer to employ the I library, which provides a front-end " "for generating seccomp filters." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The I field of the IpidI file provides a method of " "viewing the seccomp mode of a process; see B(5)." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "B() provides a superset of the functionality provided by the " "B(2) B operation (which does not support I)." msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Since Linux 4.4, the B(2) B operation " "can be used to dump a process's seccomp filters." msgstr "" #. type: SS #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "Architecture support for seccomp BPF" msgstr "" #. Check by grepping for HAVE_ARCH_SECCOMP_FILTER in Kconfig files in #. kernel source. Last checked in Linux 4.16-rc source. #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Architecture support for seccomp BPF filtering is available on the following " "architectures:" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "x86-64, i386, x32 (since Linux 3.5)" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "ARM (since Linux 3.8)" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "s390 (since Linux 3.8)" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "MIPS (since Linux 3.16)" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "ARM-64 (since Linux 3.19)" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "PowerPC (since Linux 4.3)" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Tile (since Linux 4.3)" msgstr "" #. User mode Linux since Linux 4.6 #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "PA-RISC (since Linux 4.6)" msgstr "" #. type: SS #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "Caveats" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "There are various subtleties to consider when applying seccomp filters to a " "program, including the following:" msgstr "" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Some traditional system calls have user-space implementations in the " "B(7) on many architectures. Notable examples include " "B(2), B(2), and B