feature: handle SUID and SGID bits

Implement the missing feature by merging the static implementation and dynamic methods used in chef-os-hardening.