| 1 |
|
| 2 |
|
| 3 |
pub const CAP_CHOWN: u8 = 0; |
| 4 |
pub const CAP_DAC_OVERRIDE: u8 = 1; |
| 5 |
pub const CAP_DAC_READ_SEARCH: u8 = 2; |
| 6 |
pub const CAP_FOWNER: u8 = 3; |
| 7 |
pub const CAP_FSETID: u8 = 4; |
| 8 |
pub const CAP_KILL: u8 = 5; |
| 9 |
pub const CAP_SETGID: u8 = 6; |
| 10 |
pub const CAP_SETUID: u8 = 7; |
| 11 |
pub const CAP_SETPCAP: u8 = 8; |
| 12 |
pub const CAP_LINUX_IMMUTABLE: u8 = 9; |
| 13 |
pub const CAP_NET_BIND_SERVICE: u8 = 10; |
| 14 |
pub const CAP_NET_BROADCAST: u8 = 11; |
| 15 |
pub const CAP_NET_ADMIN: u8 = 12; |
| 16 |
pub const CAP_NET_RAW: u8 = 13; |
| 17 |
pub const CAP_IPC_LOCK: u8 = 14; |
| 18 |
pub const CAP_IPC_OWNER: u8 = 15; |
| 19 |
pub const CAP_SYS_MODULE: u8 = 16; |
| 20 |
pub const CAP_SYS_RAWIO: u8 = 17; |
| 21 |
pub const CAP_SYS_CHROOT: u8 = 18; |
| 22 |
pub const CAP_SYS_PTRACE: u8 = 19; |
| 23 |
pub const CAP_SYS_PACCT: u8 = 20; |
| 24 |
pub const CAP_SYS_ADMIN: u8 = 21; |
| 25 |
pub const CAP_SYS_BOOT: u8 = 22; |
| 26 |
pub const CAP_SYS_NICE: u8 = 23; |
| 27 |
pub const CAP_SYS_RESOURCE: u8 = 24; |
| 28 |
pub const CAP_SYS_TIME: u8 = 25; |
| 29 |
pub const CAP_SYS_TTY_CONFIG: u8 = 26; |
| 30 |
pub const CAP_MKNOD: u8 = 27; |
| 31 |
pub const CAP_LEASE: u8 = 28; |
| 32 |
pub const CAP_AUDIT_WRITE: u8 = 29; |
| 33 |
pub const CAP_AUDIT_CONTROL: u8 = 30; |
| 34 |
pub const CAP_SETFCAP: u8 = 31; |
| 35 |
pub const CAP_MAC_OVERRIDE: u8 = 32; |
| 36 |
pub const CAP_MAC_ADMIN: u8 = 33; |
| 37 |
pub const CAP_SYSLOG: u8 = 34; |
| 38 |
pub const CAP_WAKE_ALARM: u8 = 35; |
| 39 |
pub const CAP_BLOCK_SUSPEND: u8 = 36; |
| 40 |
pub const CAP_AUDIT_READ: u8 = 37; |
| 41 |
pub const CAP_PERFMON: u8 = 38; |
| 42 |
pub const CAP_BPF: u8 = 39; |
| 43 |
pub const CAP_CHECKPOINT_RESTORE: u8 = 40; |
| 44 |
|
| 45 |
|
| 46 |
|
| 47 |
pub const PR_GET_KEEPCAPS: i32 = 7; |
| 48 |
pub const PR_SET_KEEPCAPS: i32 = 8; |
| 49 |
pub const PR_CAPBSET_READ: i32 = 23; |
| 50 |
pub const PR_CAPBSET_DROP: i32 = 24; |
| 51 |
pub const PR_CAP_AMBIENT: i32 = 47; |
| 52 |
pub const PR_CAP_AMBIENT_IS_SET: i32 = 1; |
| 53 |
pub const PR_CAP_AMBIENT_RAISE: i32 = 2; |
| 54 |
pub const PR_CAP_AMBIENT_LOWER: i32 = 3; |
| 55 |
pub const PR_CAP_AMBIENT_CLEAR_ALL: i32 = 4; |
| 56 |
|
| 57 |
|
| 58 |
|
| 59 |
#[cfg(target_arch = "x86")] |
| 60 |
pub const CAPGET: i32 = 184; |
| 61 |
#[cfg(target_arch = "x86")] |
| 62 |
pub const CAPSET: i32 = 185; |
| 63 |
|
| 64 |
#[cfg(all(target_arch = "x86_64", target_pointer_width = "64"))] |
| 65 |
pub const CAPGET: i64 = 125; |
| 66 |
#[cfg(all(target_arch = "x86_64", target_pointer_width = "64"))] |
| 67 |
pub const CAPSET: i64 = 126; |
| 68 |
|
| 69 |
#[cfg(all(target_arch = "x86_64", target_pointer_width = "32"))] |
| 70 |
pub const CAPGET: i32 = 0x40000000 + 125; |
| 71 |
#[cfg(all(target_arch = "x86_64", target_pointer_width = "32"))] |
| 72 |
pub const CAPSET: i32 = 0x40000000 + 126; |
| 73 |
|
| 74 |
#[cfg(target_arch = "aarch64")] |
| 75 |
pub const CAPGET: i64 = 90; |
| 76 |
#[cfg(target_arch = "aarch64")] |
| 77 |
pub const CAPSET: i64 = 91; |
| 78 |
|
| 79 |
#[cfg(target_arch = "powerpc")] |
| 80 |
pub const CAPGET: i32 = 183; |
| 81 |
#[cfg(target_arch = "powerpc")] |
| 82 |
pub const CAPSET: i32 = 184; |
| 83 |
|
| 84 |
#[cfg(target_arch = "powerpc64")] |
| 85 |
pub const CAPGET: i64 = 183; |
| 86 |
#[cfg(target_arch = "powerpc64")] |
| 87 |
pub const CAPSET: i64 = 184; |
| 88 |
|
| 89 |
#[cfg(target_arch = "mips")] |
| 90 |
pub const CAPGET: i32 = 4204; |
| 91 |
#[cfg(target_arch = "mips")] |
| 92 |
pub const CAPSET: i32 = 4205; |
| 93 |
|
| 94 |
#[cfg(target_arch = "mips64")] |
| 95 |
pub const CAPGET: i64 = 5123; |
| 96 |
#[cfg(target_arch = "mips64")] |
| 97 |
pub const CAPSET: i64 = 5124; |
| 98 |
|
| 99 |
#[cfg(target_arch = "arm")] |
| 100 |
pub const CAPGET: i32 = 184; |
| 101 |
#[cfg(target_arch = "arm")] |
| 102 |
pub const CAPSET: i32 = 185; |
| 103 |
|
| 104 |
#[cfg(target_arch = "s390x")] |
| 105 |
pub const CAPGET: i64 = 184; |
| 106 |
#[cfg(target_arch = "s390x")] |
| 107 |
pub const CAPSET: i64 = 185; |
| 108 |
|
| 109 |
#[cfg(target_arch = "sparc")] |
| 110 |
pub const CAPGET: i64 = 21; |
| 111 |
#[cfg(target_arch = "sparc")] |
| 112 |
pub const CAPSET: i64 = 22; |
| 113 |
|
| 114 |
#[cfg(target_arch = "sparc64")] |
| 115 |
pub const CAPGET: i64 = 21; |
| 116 |
#[cfg(target_arch = "sparc64")] |
| 117 |
pub const CAPSET: i64 = 22; |
| 118 |
|
| 119 |
#[cfg(target_arch = "riscv64")] |
| 120 |
pub const CAPGET: i64 = 90; |
| 121 |
#[cfg(target_arch = "riscv64")] |
| 122 |
pub const CAPSET: i64 = 91; |
| 123 |
|
| 124 |
#[cfg(target_arch = "loongarch64")] |
| 125 |
pub const CAPGET: i64 = 90; |
| 126 |
#[cfg(target_arch = "loongarch64")] |
| 127 |
pub const CAPSET: i64 = 91; |