aboutsummaryrefslogtreecommitdiff
path: root/sbopkglint.d/50-icons.t.sh
diff options
context:
space:
mode:
Diffstat (limited to 'sbopkglint.d/50-icons.t.sh')
-rw-r--r--sbopkglint.d/50-icons.t.sh10
1 files changed, 9 insertions, 1 deletions
diff --git a/sbopkglint.d/50-icons.t.sh b/sbopkglint.d/50-icons.t.sh
index 1f1f032..8b3303a 100644
--- a/sbopkglint.d/50-icons.t.sh
+++ b/sbopkglint.d/50-icons.t.sh
@@ -75,9 +75,17 @@ for icondir in usr/share/pixmaps usr/share/icons/hicolor; do
if [ -d "$icondir" ]; then
find -L "$icondir" -type f | while read i; do
check_image "$i"
+ [ "$( stat -Lc '%a %U %G' "$i" )" = "644 root root" ] || \
+ ls -ld "$i" >> .badperms.$$
done
fi
done
[ -s .nonimages.$$ ] && warn "non-image files in icon dirs:" && cat .nonimages.$$
-rm -f .nonimages.$$
+
+if [ -s .badperms.$$ ]; then
+ warn "bad permissions/owner on icon(s) (should be 0644 root:root):"
+ cat .badperms.$$
+fi
+
+rm -f .nonimages.$$ .badperms.$$