1selinux_restorecon_default_hSaEnLdilneu(x3)API docusmeelnitnautxi_ornestorecon_default_handle(3)
2
3
4
6 selinux_restorecon_default_handle - sets default parameters for
7 selinux_restorecon(3)
8
10 #include <selinux/restorecon.h>
11 #include <selinux/label.h>
12
13 struct selabel_handle *selinux_restorecon_default_handle(void);
14
16 selinux_restorecon_default_handle() sets default parameters for
17 selinux_restorecon(3) by calling selabel_open(3) with the SELA‐
18 BEL_OPT_DIGEST option only. This will enable a digest to be calculated
19 on the currently loaded policy file_contexts(5) set of files as
20 described in the NOTES section of selinux_restorecon(3).
21
22 Calling selinux_restorecon_default_handle() is optional, however if
23 used then selinux_restorecon_set_sehandle(3) should be called with the
24 returned handle to set this for use by selinux_restorecon(3).
25
26 selinux_restorecon_default_handle() is optional as selinux_restore‐
27 con(3) will automatically call this and selinux_restorecon_set_sehan‐
28 dle(3) provided a handle has not already been set, for example by
29 selinux_restorecon_set_sehandle(3) to set customised selabel_open(3)
30 parameters.
31
33 A non-NULL handle value is returned on success. On error, NULL is
34 returned and errno is set appropriately.
35
37 selinux_restorecon(3),
38 selinux_restorecon_set_sehandle(3),
39 selinux_restorecon_set_exclude_list(3)
40
41
42
43Security Enhanced Linux 20 Oct 20s1e5linux_restorecon_default_handle(3)