DOKK / manpages / debian 11 / libselinux1-dev / selinux_getpolicytype.3.en
selinux_getpolicytype(3) SELinux API documentation selinux_getpolicytype(3)

selinux_getpolicytype - get the type of SELinux policy running on the system

#include <selinux/selinux.h>

int selinux_getpolicytype(char **policytype);

selinux_getpolicytype() Reads the contents of the /etc/selinux/config file to determine the SELinux policy used on the system, and sets policytype accordingly. Free policytype with free(3).

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

selinux(8)

24 Sep 2008 dwalsh@redhat.com