2 * Copyright (C) 2015 Etienne CHAMPETIER <champetier.etienne@gmail.com>
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU Lesser General Public License version 2.1
6 * as published by the Free Software Foundation
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
13 #ifndef _JAIL_CAPABILITIES_H_
14 #define _JAIL_CAPABILITIES_H_
16 #include <libubox/blobmsg.h>
17 #include <linux/capability.h>
28 int parseOCIcapabilities(struct jail_capset
*capset
, struct blob_attr
*msg
);
29 int parseOCIcapabilities_from_file(struct jail_capset
*capset
, const char *file
);
30 int applyOCIcapabilities(struct jail_capset capset
, uint64_t retain
);
32 /* capget/capset syscall wrappers are provided by libc */
33 extern int capget(cap_user_header_t header
, cap_user_data_t data
);
34 extern int capset(cap_user_header_t header
, const cap_user_data_t data
);