7.1.1 Disable IP Forwarding

Information

The net.ipv4.ip_forward flag is used to tell the server whether it can forward packets or
not. If the server is not to be used as a router, set the flag to 0.

*Rationale*

Setting the flag to 0 ensures that a server with multiple interfaces (for example, a hard
proxy), will never be able to forward packets, and therefore, never serve as a router.

Solution

Set the net.ipv4.ip_forward parameter to 0 in /etc/sysctl.conf-
net.ipv4.ip_forward=0
Modify active kernel parameters to match-
# /sbin/sysctl -w net.ipv4.ip_forward=0
# /sbin/sysctl -w net.ipv4.route.flush=1

See Also

https://workbench.cisecurity.org/files/91

Item Details

Category: SYSTEM AND COMMUNICATIONS PROTECTION

References: 800-53|SC-7(12), CSCv6|9.2

Plugin: Unix

Control ID: 98d355c71d462faf175a1ff5add6bec780efd8d5b56efc38e45ffe8f60c2ddad