Linux Kernel
3.7.1
|
#include <linux/security.h>
#include <linux/sysctl.h>
#include <linux/ptrace.h>
#include <linux/prctl.h>
#include <linux/ratelimit.h>
Go to the source code of this file.
Data Structures | |
struct | ptrace_relation |
Macros | |
#define | YAMA_SCOPE_DISABLED 0 |
#define | YAMA_SCOPE_RELATIONAL 1 |
#define | YAMA_SCOPE_CAPABILITY 2 |
#define | YAMA_SCOPE_NO_ATTACH 3 |
Functions | |
void | yama_task_free (struct task_struct *task) |
int | yama_task_prctl (int option, unsigned long arg2, unsigned long arg3, unsigned long arg4, unsigned long arg5) |
int | yama_ptrace_access_check (struct task_struct *child, unsigned int mode) |
int | yama_ptrace_traceme (struct task_struct *parent) |
security_initcall (yama_init) | |
#define YAMA_SCOPE_CAPABILITY 2 |
Definition at line 23 of file yama_lsm.c.
#define YAMA_SCOPE_DISABLED 0 |
Definition at line 21 of file yama_lsm.c.
#define YAMA_SCOPE_NO_ATTACH 3 |
Definition at line 24 of file yama_lsm.c.
#define YAMA_SCOPE_RELATIONAL 1 |
Definition at line 22 of file yama_lsm.c.
security_initcall | ( | yama_init | ) |
int yama_ptrace_access_check | ( | struct task_struct * | child, |
unsigned int | mode | ||
) |
yama_ptrace_access_check - validate PTRACE_ATTACH calls : task that current task is attempting to ptrace : ptrace attach mode
Returns 0 if following the ptrace is allowed, -ve on error.
Definition at line 246 of file yama_lsm.c.
int yama_ptrace_traceme | ( | struct task_struct * | parent | ) |
yama_ptrace_traceme - validate PTRACE_TRACEME calls : task that will become the ptracer of the current task
Returns 0 if following the ptrace is allowed, -ve on error.
Definition at line 296 of file yama_lsm.c.
void yama_task_free | ( | struct task_struct * | task | ) |
yama_task_free - check for task_pid to remove from exception list : task being removed
Definition at line 103 of file yama_lsm.c.
int yama_task_prctl | ( | int | option, |
unsigned long | arg2, | ||
unsigned long | arg3, | ||
unsigned long | arg4, | ||
unsigned long | arg5 | ||
) |
yama_task_prctl - check for Yama-specific prctl operations : operation : argument : argument : argument : argument
Return 0 on success, -ve on error. -ENOSYS is returned when Yama does not handle the given option.
Definition at line 119 of file yama_lsm.c.