From 6876a2eaa87e3eead822e5f4f7d1fc53d0853ebd Mon Sep 17 00:00:00 2001 From: Patrick Schleizer Date: Fri, 20 Dec 2019 04:01:40 -0500 Subject: [PATCH] comment --- usr/lib/security-misc/permission-hardening | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/usr/lib/security-misc/permission-hardening b/usr/lib/security-misc/permission-hardening index 086ae8c..318f4af 100755 --- a/usr/lib/security-misc/permission-hardening +++ b/usr/lib/security-misc/permission-hardening @@ -116,10 +116,11 @@ set_file_perms() { ## Use dpkg-statoverride so permissions are not reset during upgrades. + ## Check there is an entry for the fso. if dpkg-statoverride --list | grep -q "$fso_without_trailing_slash"; then - ## If there is an entry for the fso, but the owner/group/mode do not - ## match, we remove and re-add the entry to update it. + ## There is an fso entry. Check if owner/group/mode match. if ! dpkg-statoverride --list | grep -q "$owner $group $mode_from_config $fso_without_trailing_slash"; then + ## The owner/group/mode do not match, therefore remove and re-add the entry to update it. ## fso_without_trailing_slash instead of fso to prevent ## "dpkg-statoverride: warning: stripping trailing /" echo_wrapper dpkg-statoverride --remove "$fso_without_trailing_slash"