cfengine/design-center — pull request #226 by mvpel (2013-01-20 00:37:23+00:00)
Title: Package method for kernel modules on Linux, HP-UX, and Solaris

This package method can only add modules that have been previously installed and made available to the currently-running kernel.

An example use for this method would be insuring that kernel-bundled USB storage drivers on a sensitive server are always unloaded. Outright deletion of the driver's object file is not always practical - driver names don't always match object file names; object files may be stored in a variety of directories, sometimes as multiple versions; renaming or deleting individual files may disrupt package integrity and complicate returning to the original state; or driver or kernel updates may be installed that affect the module.

Sample promise:

```
bundle agent disable_usb_storage
{
packages:
linux::
"usb_storage" -> { "CCE_4187_1", "NSA_GSCRHEL5_2_2_2_2_1" }
package_policy => "delete",
package_method => kernel_module,
comment => "Insure that USB drives are not recognized.";
}
```