]> git.ipfire.org Git - pakfire.git/commitdiff
FHS: Check permissions of files in /usr/include
authorMichael Tremer <michael.tremer@ipfire.org>
Fri, 17 Mar 2023 10:53:50 +0000 (10:53 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 17 Mar 2023 10:53:50 +0000 (10:53 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/libpakfire/fhs.c

index bf4ad3e855a90c722020670cf8bf99413485ee1b..a4352a65d11fe8c1f52e5bc2aac627c55bdbf0a7 100644 (file)
@@ -64,6 +64,12 @@ static const struct pakfire_fhs_check {
        { "/usr/bin/*",   S_IFREG, 0, 0755, "root", "root" },
        { "/usr/sbin/*",  S_IFREG, 0, 0755, "root", "root" },
 
+       // /usr/include: Ensure that:
+       //   * All files are non-executable and belong to root
+       //   * All directories have 0755 and belong to root
+       { "/usr/include/**", S_IFREG, 0, 0644, "root", "root" },
+       { "/usr/include/**", S_IFDIR, 0, 0755, "root", "root" },
+
        // /var
        { "/var",         S_IFDIR, 0, 0755, "root", "root" },
        { "/var/cache",   S_IFDIR, 0, 0755, "root", "root" },