- if (-d "$tmp/usr/lib/ada") {
- complex_doit("find $tmp/usr/lib/ada -type f",
- "-name '*.ali' $find_options -print0",
- "2>/dev/null | xargs -0r chmod uga-w");
+ complex_doit("find $tmp/usr/lib -type f",
+ "-name '*.ali' $find_options -print0",
+ "2>/dev/null | xargs -0r chmod uga-w");
+
+ # Lintian overrides should never be executable, too.
+ if (-d "$tmp/usr/share/lintian") {
+ complex_doit("find $tmp/usr/share/lintian/overrides",
+ "-type f $find_options -print0",
+ "2>/dev/null | xargs -0r chmod 644");
+ }
+
+ # Files in $tmp/etc/sudoers.d/ must be mode 440.
+ if (-d "$tmp/etc/sudoers.d") {
+ complex_doit("find $tmp/etc/sudoers.d",
+ "-type f ! -perm 440 $find_options -print0",
+ "2>/dev/null | xargs -0r chmod 440");