1security_get_boolean_names(3S)ELinux API Documentatisoencurity_get_boolean_names(3)
2
3
4
6 security_load_booleans, security_set_boolean, security_commit_booleans,
7 security_get_boolean_names, security_get_boolean_active, secu‐
8 rity_get_boolean_pending - routines for manipulating SELinux boolean
9 values
10
12 #include <selinux/selinux.h>
13
14 int security_load_booleans(char *path);
15
16 int security_get_boolean_names(char ***names, int *len);
17
18 int security_get_boolean_pending(const char *name);
19
20 int security_get_boolean_active(const char *name);
21
22 int security_set_boolean(const char *name, int value);
23
24 int security_set_boolean_list(size_t boolcnt, SELboolean *boollist, int
25 permanent);
26
27 int security_commit_booleans(void);
28
29
30
32 The SELinux policy can include conditional rules that are enabled or
33 disabled based on the current values of a set of policy booleans.
34 These policy booleans allow runtime modification of the security policy
35 without having to load a new policy.
36
37 The SELinux API allows for a transaction based update. So you can set
38 several boolean values and then commit them all at once.
39
40 security_load_booleans
41
42 loads policy boolean settings. Path may be NULL, in which case the
43 booleans are loaded from the active policy boolean configuration file.
44
45 security_get_boolean_names
46
47 provides a list of boolean names, currently supported by the loaded
48 policy.
49
50 security_get_boolean_pending
51
52 returns the pending value for boolean or -1 on failure.
53
54 security_get_boolean_active
55
56 returns the active value for boolean or -1 on failure.
57
58 security_set_boolean
59
60 sets the pending value for boolean
61
62 security_set_boolean_list
63
64 saves a list of booleans in a single transaction.
65
66 security_commit_booleans
67
68 commits all pending values for the booleans.
69
70
72 Where not otherwise stated, functions described in this manual page
73 return zero on success or -1 on error.
74
75
77 This manual page was written by Dan Walsh <dwalsh@redhat.com>.
78
79
81 selinux(8), getsebool(8), booleans(8), togglesebool(8)
82
83
84
85dwalsh@redhat.com 15 November 2004 security_get_boolean_names(3)