]> git.ipfire.org Git - thirdparty/systemd.git/blame - src/shared/label.h
relicense to LGPLv2.1 (with exceptions)
[thirdparty/systemd.git] / src / shared / label.h
CommitLineData
03467c88 1/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
e51bc1a2
LP
2
3#ifndef foolabelhfoo
4#define foolabelhfoo
5
6/***
7 This file is part of systemd.
8
9 Copyright 2010 Lennart Poettering
10
11 systemd is free software; you can redistribute it and/or modify it
5430f7f2
LP
12 under the terms of the GNU Lesser General Public License as published by
13 the Free Software Foundation; either version 2.1 of the License, or
e51bc1a2
LP
14 (at your option) any later version.
15
16 systemd is distributed in the hope that it will be useful, but
17 WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5430f7f2 19 Lesser General Public License for more details.
e51bc1a2 20
5430f7f2 21 You should have received a copy of the GNU Lesser General Public License
e51bc1a2
LP
22 along with systemd; If not, see <http://www.gnu.org/licenses/>.
23***/
24
25#include <sys/types.h>
c904f64d 26#include <stdbool.h>
f13e30d2 27#include <sys/socket.h>
e51bc1a2
LP
28
29int label_init(void);
30void label_finish(void);
31
c904f64d 32int label_fix(const char *path, bool ignore_enoent);
e51bc1a2
LP
33
34int label_socket_set(const char *label);
35void label_socket_clear(void);
36
049f8642 37int label_fifofile_set(const char *path);
5c0532d1 38int label_symlinkfile_set(const char *path);
e51bc1a2
LP
39void label_file_clear(void);
40
41void label_free(const char *label);
42
189583d7 43int label_get_create_label_from_exe(const char *exe, char **label);
e51bc1a2
LP
44
45int label_mkdir(const char *path, mode_t mode);
46
4d4c7486
LP
47void label_retest_selinux(void);
48
f13e30d2
LP
49int label_bind(int fd, const struct sockaddr *addr, socklen_t addrlen);
50
e51bc1a2 51#endif