After upgrading my Ubuntu server, some security applications grumped about changed contents of some common binaries.

Just to be safe, I wanted to verify them explicitly with debsums, but debsums looks for package names, not paths to binaries. Here’s a script that validates chattr, find, perl, and lsattr–the “-s” option to debsums is “silent”, so no news is good news:

for i in /usr/bin/chattr /usr/bin/find /usr/bin/perl /usr/bin/lsattr ; do
  echo $i
  debsums -as $(dpkg -S $i | cut -d':' -f1 | sort -u)
done