How To Create and Apply a Patch File Using the diff and patch Commands

Author: , January 25th, 2016

Create the patch by using the diff -u command:

To use the patch file, apply it to the original. The patch command will create a backup with the extension .orig, and the original file will be updated:

You may need to add the flag –ignore-whitespace to the patch command.

How To Check for Infected Files Using Nagios Plugins

Author: , January 25th, 2016

This example shows how to look for infection patterns inside all .php files in a directory tree using find and grep called from a Nagios NRPE plugin written in PERL. You can adjust the behavior by modifying the script, described at the bottom of this post in the Advanced section. On the host to be […]