Today I will be showing you how to run basic shell commands from a PHP script. While you can’t interact with these commands (for example top will not output or update, you can still use them to somewhat interact with your web server. Note that most shared web hosting providers block these functions in their php.ini settings for security reasons. After showing how this works, I will also show you how to block these functions on your own web server.
In this post I will show you how to install and run Rootkit Hunter on your Linux based servers. Rootkit Hunter does what it’s name suggests, hunts for potential rootkits on your server. If you are infected you can try to clean it but you really may want to nuke the server and start from scratch or revert to a previous backup/snapshot if possible. For more information about RKHunter please visit the official Rootkit Hunter website.