1selabel_media(5) SELinux API documentation selabel_media(5)
2
3
4
6 selabel_media - userspace SELinux labeling interface: media contexts
7 backend.
8
10 #include <selinux/selinux.h>
11
12 #include <selinux/label.h>
13
14 int selabel_lookup(struct selabel_handle *hnd,
15 security_context_t *context,
16
17 const char *device_name, int unused);
18
19
21 The media contexts backend maps from media device names such as "cdrom"
22 or "floppy" into security contexts. It is used to find the appropriate
23 context for establishing context mounts on these devices.
24
25 The integer lookup argument is currently unused and should be set to
26 zero.
27
28
30 In addition to the global options described in selabel_open(3), this
31 backend recognizes the following options:
32
33
34 SELABEL_OPT_PATH
35 A non-null value for this option specifies a path to a file that
36 will be opened in lieu of the standard media contexts file.
37
38
40 selabel_open(3), selabel_lookup(3), selabel_stats(3), selinux(8)
41
42
43
44
45 18 Jun 2007 selabel_media(5)