1selinux_getenforcemode(3)  SELinux API documentation selinux_getenforcemode(3)
2
3
4

NAME

6       selinux_getenforcemode - get the enforcing state of SELinux
7

SYNOPSIS

9       #include <selinux/selinux.h>
10
11       int selinux_getenforcemode(int *enforce);
12

DESCRIPTION

14       selinux_getenforcemode()  Reads the contents of the /etc/selinux/config
15       file to determine how the system was setup to run SELinux.
16
17       Sets the value of enforce to 1 if SELinux should be  run  in  enforcing
18       mode.   Sets the value of enforce to 0 if SELinux should be run in per‐
19       missive mode.  Sets the value of enforce to -1  if  SELinux  should  be
20       disabled.
21

RETURN VALUE

23       On success, zero is returned.  On failure, -1 is returned.
24

SEE ALSO

26       selinux(8)
27
28
29
30dwalsh@redhat.com                 25 May 2004        selinux_getenforcemode(3)
Impressum