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

NAME

6       matchmediacon - get the default SELinux security context for the speci‐
7       fied mediatype from the policy
8

SYNOPSIS

10       #include <selinux/selinux.h>
11
12       int matchmediacon(const char *media, char **con);
13

DESCRIPTION

15       matchmediacon() matches the specified media type with  the  media  con‐
16       texts  configuration  and sets the security context con to refer to the
17       resulting context.
18
19       Note: Caller must free returned security context con using freecon(3).
20

RETURN VALUE

22       Returns 0 on success or -1 otherwise.
23

Files

25       /etc/selinux/{POLICYTYPE}/contexts/files/media
26

SEE ALSO

28       selinux(8), freecon(3)
29
30
31
32dwalsh@redhat.com              15 November 2004               matchmediacon(3)
Impressum