XK0-004 · Question #129
A Linux administrator has installed a web application firewall in front of a web server running on HTTP port 8080 and successfully started the HTTP server. However, after opening the application URL…
The correct answer is B. Edit /etc/sysctl.conf file and add net.ipv4.ip_forward = 1 then run sysctl -p. When a WAF forwards traffic to a backend web server, the Linux kernel must have IP forwarding enabled. Editing /etc/sysctl.conf and running sysctl -p makes this change permanent at the kernel level.
Question
A Linux administrator has installed a web application firewall in front of a web server running on HTTP port 8080 and successfully started the HTTP server. However, after opening the application URL in an Internet browser, the administrator discovered that the application does not work. The administrator performed the following diagnostic steps:
Output of sysctl -a command:
Output of iptables -L command:
Output of netstat –nltop | grep "8080":
Which of the following is the NEXT step the administrator should perform to permanently fix the issue at the kernel level?
Exhibits
Options
- Athen run to enable
- BEdit /etc/sysctl.conf file and add net.ipv4.ip_forward = 1 then run sysctl -p
- CAdd iptables rule iptables -A INPUT -m state --state NEW -p tcp --dport 8080
- DAdd iptables rule
How the community answered
(28 responses)- A29% (8)
- B54% (15)
- C7% (2)
- D11% (3)
Why each option
When a WAF forwards traffic to a backend web server, the Linux kernel must have IP forwarding enabled. Editing /etc/sysctl.conf and running sysctl -p makes this change permanent at the kernel level.
This option is incomplete and does not reference a specific persistent configuration method to enable IP forwarding at the kernel level.
A web application firewall acting as a reverse proxy requires the Linux kernel to forward IP packets between network interfaces. Setting net.ipv4.ip_forward = 1 in /etc/sysctl.conf and running sysctl -p applies the change immediately and persists it across reboots, which is the definition of a permanent kernel-level fix.
Adding an iptables INPUT rule for port 8080 allows new incoming connections but does not enable IP forwarding, which is required for traffic to be routed from the WAF to the backend server.
This option is incomplete and does not address the root cause of the missing kernel-level IP forwarding configuration.
Concept tested: Linux kernel IP forwarding via sysctl
Source: https://www.kernel.org/doc/html/latest/networking/ip-sysctl.html
Topics
Community Discussion
No community discussion yet for this question.

