For a cyber security competition I participate in, I'm given a Debian virtual machine with many packages installed and asked to clean extraneous or malicious packages.
In the past, I've used dpkg -l | grep [searchterm]
and a list of common packages to preform this task. However, this is extremely inefficient and time-consuming.
To speed up my task, is there a way to search through the list of packages installed on a system for which processes have been installed by a user and are not system "default" packages?