]> git.ipfire.org Git - pakfire.git/commitdiff
FHS: Enfore that all files in /usr/*bin are executable
authorMichael Tremer <michael.tremer@ipfire.org>
Fri, 17 Mar 2023 10:49:21 +0000 (10:49 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 17 Mar 2023 10:49:21 +0000 (10:49 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/libpakfire/fhs.c

index b09da67fe91465dbea28a11ab2ea2ba4385837a7..14dd70ff53e01b9c6a9a30e32fa6d09d50ae2599 100644 (file)
@@ -60,6 +60,10 @@ static const struct pakfire_fhs_check {
        { "/usr/bin/*",   S_IFDIR, PAKFIRE_FHS_MUSTNOTEXIST, 0, NULL, NULL },
        { "/usr/sbin/*",  S_IFDIR, PAKFIRE_FHS_MUSTNOTEXIST, 0, NULL, NULL },
 
+       // Any files in /usr/{,s}bin must be owned by root and have 0755
+       { "/usr/bin/*",   S_IFREG, 0, 0755, "root", "root" },
+       { "/usr/sbin/*",  S_IFREG, 0, 0755, "root", "root" },
+
        // /var
        { "/var",         S_IFDIR, 0, 0755, "root", "root" },
        { "/var/cache",   S_IFDIR, 0, 0755, "root", "root" },