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