1.1.1.4 Ensure hfsplus kernel module is not available

Information

The hfsplus filesystem type is a hierarchical filesystem designed to replace hfs that allows you to mount Mac OS filesystems.

Removing support for unneeded filesystem types reduces the local attack surface of the system. If this filesystem type is not needed, disable it.

Solution

Run the following to unload and disable the hfsplus kernel module. This can also be done by running the script included below.

Run the following commands to unload the hfsplus kernel module:

# modprobe -r hfsplus 2>/dev/null
# rmmod hfsplus 2>/dev/null

Perform the following to disable the hfsplus kernel module:

Create a file ending inconf with install hfsplus /bin/false in the /etc/modprobe.d/ directory

Example:

# printf '\n%s\n' "install hfsplus /bin/false" >> hfsplus.conf

Create a file ending inconf with blacklist hfsplus in the /etc/modprobe.d/ directory

Example:

# printf '\n%s\n' "blacklist hfsplus" >> hfsplus.conf

See Also

https://workbench.cisecurity.org/benchmarks/21369

Item Details

Category: CONFIGURATION MANAGEMENT

References: 800-53|CM-6, 800-53|CM-7, CSCv7|9.2

Plugin: Unix

Control ID: 46482dd185489548de615755c6a94c8ccdca530f5ee1076d5fcb05b24442b7aa