chiark / gitweb /
smack: make mac_smack_fix() deal somewhat sensible with non-absolute paths
authorLennart Poettering <lennart@poettering.net>
Wed, 30 May 2018 16:21:58 +0000 (18:21 +0200)
committerSven Eden <yamakuzure@gmx.net>
Fri, 24 Aug 2018 14:47:08 +0000 (16:47 +0200)
commitaa15ecac3f6b7d995748fd668c39cf1c8c63e476
treeb105ee098c08b683bdf34c5fed6017028208ffa3
parentf0580b86936fbf46f0dd5cb2a91ad9ceff033a35
smack: make mac_smack_fix() deal somewhat sensible with non-absolute paths

This tries to improve the mac_smack_fix() logic a bit, by properly
handling non-absolute paths.

It's still pretty broken though, which is sad for security technology:
non-normalized paths (for example "/usr/../dev/sda") will still not be
treated correctly. I am not sure how to fix that properly though, and I
don't understand SMACK well enough to do so. This fix hence just fixes
to most obvious glaring issue.
src/basic/smack-util.c