summaryrefslogtreecommitdiffstats
path: root/src/shared/smack-util.h
diff options
context:
space:
mode:
authorDaan De Meyer <daan.j.demeyer@gmail.com>2023-03-26 18:20:41 +0200
committerDaan De Meyer <daan.j.demeyer@gmail.com>2023-05-31 13:15:53 +0200
commita452c807a447121ce4ba100863cdc4fb81cde047 (patch)
tree7a4f45b84a5dc321514e89bf41d4e2c8ce117e14 /src/shared/smack-util.h
parentlabel: Rename to label-util.h (diff)
downloadsystemd-a452c807a447121ce4ba100863cdc4fb81cde047.tar.xz
systemd-a452c807a447121ce4ba100863cdc4fb81cde047.zip
label: Introduce LabelOps to do pre/post labelling operations
By default, label_ops is initialized with a NULL pointer which translates to noop labelling operations. In mac_selinux_init() and the new mac_smack_init(), we initialize label_ops with a MAC specific LabelOps pointer. We also introduce mac_init() to initialize any configured MACs and replace all usages of mac_selinux_init() with mac_init().
Diffstat (limited to 'src/shared/smack-util.h')
-rw-r--r--src/shared/smack-util.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/shared/smack-util.h b/src/shared/smack-util.h
index 953bf91358..f6ed2ece38 100644
--- a/src/shared/smack-util.h
+++ b/src/shared/smack-util.h
@@ -28,6 +28,7 @@ typedef enum SmackAttr {
} SmackAttr;
bool mac_smack_use(void);
+int mac_smack_init(void);
int mac_smack_fix_full(int atfd, const char *inode_path, const char *label_path, LabelFixFlags flags);
static inline int mac_smack_fix(const char *path, LabelFixFlags flags) {