1CAPNG_APPLY_CAPS_FD(3)           Libcap-ng API          CAPNG_APPLY_CAPS_FD(3)
2
3
4

NAME

6       capng_apply_caps_fd -
7

SYNOPSIS

9       #include <cap-ng.h>
10
11       int capng_apply_caps_fd(int fd);
12
13

DESCRIPTION

15       This  function  will  write the file based capabilities to the extended
16       attributes of the file that the  descriptor  was  opened  against.  The
17       bounding  set  is  not  included in file based capabilities operations.
18       Note that this function will only work if compiled  on  a  kernel  that
19       supports file based capabilities such as 2.6.2 6 and later.
20
21

RETURN VALUE

23       This  returns  0  on success, -1 if something besides a regular file is
24       passed, and -2 if a non-root namespace id is being used for rootid.
25
26

SEE ALSO

28       capng_get_caps_fd(3), capabilities(7)
29
30

AUTHOR

32       Steve Grubb
33
34
35
36Red Hat                            Sept 2020            CAPNG_APPLY_CAPS_FD(3)
Impressum