Files
serenity/Kernel/API/prctl_numbers.h
Liav A. b93ca74d81 Kernel: Add a prctl option to enter jail mode until an execve syscall
In addition to the already existing option to enter jail mode (which is
set indefinitely), there should be a less restrictive option that should
allow exiting jail mode when doing the execve syscall.

This option will be useful for programs that need this kind of security
layer only in their runtime, but they're meant to actually initiate
another program in the end.
2024-10-03 12:39:45 +02:00

21 lines
576 B
C

/*
* Copyright (c) 2020, Andreas Kling <kling@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#pragma once
#define PR_SET_DUMPABLE 1
#define PR_GET_DUMPABLE 2
#define PR_SET_NO_NEW_SYSCALL_REGION_ANNOTATIONS 3
#define PR_GET_NO_NEW_SYSCALL_REGION_ANNOTATIONS 4
#define PR_SET_COREDUMP_METADATA_VALUE 5
#define PR_SET_PROCESS_NAME 6
#define PR_GET_PROCESS_NAME 7
#define PR_SET_THREAD_NAME 8
#define PR_GET_THREAD_NAME 9
#define PR_SET_NO_TRANSITION_TO_EXECUTABLE_FROM_WRITABLE_PROT 10
#define PR_SET_JAILED_UNTIL_EXIT 11
#define PR_SET_JAILED_UNTIL_EXEC 12