]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blame - security/apparmor/include/ipc.h
Merge tag 'reset-fixes-for-4.14' of git://git.pengutronix.de/git/pza/linux into fixes
[mirror_ubuntu-bionic-kernel.git] / security / apparmor / include / ipc.h
CommitLineData
0ed3b28a
JJ
1/*
2 * AppArmor security module
3 *
4 * This file contains AppArmor ipc mediation function definitions.
5 *
6 * Copyright (C) 1998-2008 Novell/SUSE
b2d09ae4 7 * Copyright 2009-2017 Canonical Ltd.
0ed3b28a
JJ
8 *
9 * This program is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU General Public License as
11 * published by the Free Software Foundation, version 2 of the
12 * License.
13 */
14
15#ifndef __AA_IPC_H
16#define __AA_IPC_H
17
18#include <linux/sched.h>
19
20struct aa_profile;
21
b2d09ae4
JJ
22#define AA_PTRACE_TRACE MAY_WRITE
23#define AA_PTRACE_READ MAY_READ
290f458a
JJ
24#define AA_MAY_BE_TRACED AA_MAY_APPEND
25#define AA_MAY_BE_READ AA_MAY_CREATE
26#define PTRACE_PERM_SHIFT 2
27
28#define AA_PTRACE_PERM_MASK (AA_PTRACE_READ | AA_PTRACE_TRACE | \
29 AA_MAY_BE_READ | AA_MAY_BE_TRACED)
cd1dbf76
JJ
30#define AA_SIGNAL_PERM_MASK (MAY_READ | MAY_WRITE)
31
32#define AA_SFS_SIG_MASK "hup int quit ill trap abrt bus fpe kill usr1 " \
33 "segv usr2 pipe alrm term stkflt chld cont stop stp ttin ttou urg " \
34 "xcpu xfsz vtalrm prof winch io pwr sys emt lost"
0ed3b28a 35
b2d09ae4
JJ
36int aa_may_ptrace(struct aa_label *tracer, struct aa_label *tracee,
37 u32 request);
cd1dbf76 38int aa_may_signal(struct aa_label *sender, struct aa_label *target, int sig);
0ed3b28a
JJ
39
40#endif /* __AA_IPC_H */