As a security best practice, configure your host machines to use IPv4 reverse path filtering. Reverse path filtering protects against spoofed source addresses by causing the system to discard packets with source addresses that have no route or if the route does not point towards the originating interface.
About this task
Configure your system to use reverse-path filtering whenever possible. Depending on the system role, reverse-path filtering might cause legitimate traffic to be discarded. In such cases, you might need to use a more permissive mode or disable reverse-path filtering altogether.
- Run the # grep  /proc/sys/net/ipv4/conf/*/rp_filter|egrep "default|all" command on the host system to check whether the system uses IPv4 reverse path filtering.
- Configure the host system to use IPv4 reverse path filtering.
- Open the /etc/sysctl.conf file to configure the host system.
- If the values are not set to
1, add the following entries to the file or update the existing entries accordingly. Set the value to
- Save the changes and close the file.