Lab 10.1 - Adam-Hachem/SEC335 GitHub Wiki

Finding misconfigured file permissions

How to find SUID files

find / -perm -u=s 2>/dev/null

2>/dev/null removes the errors from the output

How to find globally-writable files

find / -perm -o=w 2>/dev/null

Other options for find

-not -path "/sys/*" prevents find from searching a specific directory

-type f lists only files

-maxdepth X limits the recursion to X depth