Network Design and Operations

A router that performs NAPT (outside address 198.51.100.7) is configured with port forwarding, a static setting that translates only the destination: "forward traffic arriving at outside TCP port 8080 to port 80 on the inside web server 192.168.1.20." When host 203.0.113.9 on the internet connects from source port 51000 to port 8080 on 198.51.100.7, which is the destination and source of the packets the web server receives?

  1. ADestination 198.51.100.7:8080, source 203.0.113.9:51000
  2. BDestination 192.168.1.20:80, source 203.0.113.9:51000
  3. CDestination 192.168.1.20:80, source 198.51.100.7:51000
Show answer and explanation

Answer: B. Destination 192.168.1.20:80, source 203.0.113.9:51000

With port forwarding, the router rewrites the destination of packets arriving for the outside address and port (198.51.100.7:8080) to the configured inside address and port (192.168.1.20:80). The source is not rewritten, so to the web server the packets appear to come from 203.0.113.9:51000, and its access logs record the client's real address. The server's replies pass through this router, its default gateway, which looks up its translation table and rewrites the source back to 198.51.100.7:8080 before returning them to the client. Connections started from outside have no entry in the translation table under ordinary NAPT and never reach the inside, so this setting is needed to publish a server on the inside.

  • A. This is the destination as sent by the client, before the router rewrites it.
  • B. Correct. Only the destination is rewritten to the inside server's address and port.
  • C. The setting translates only the destination, so the source is not rewritten.
Practice this topic Back to topic

Related calculators

Books on Network Design and Operations Ad

As an Amazon Associate I earn from qualifying purchases.

More Network Design and Operations questions

  1. An ACL that checks incoming packets from the top is applied to a router interface. Rule 1 is "permit traffic to TCP port 443 on 10.0.0.10," rule 2 is "deny all traffic from source 192.168.1.0/24," and rule 3 is "permit traffic from source 192.168.0.0/16 to TCP port 80"; there are no other rules. Of the four packets (i) "from 192.168.1.5 to TCP port 443 on 10.0.0.10," (ii) "from 192.168.1.5 to TCP port 80 on 10.0.0.20," (iii) "from 192.168.2.5 to TCP port 80 on 10.0.0.20" and (iv) "from 192.168.2.5 to TCP port 22 on 10.0.0.20," which choice lists all the packets that are let through?
  2. In IPv6, which range holds link-local addresses, which are used only within the same link and are always configured automatically on every interface that uses IPv6?
  3. In IPv6 SLAAC (stateless address autoconfiguration), how does a host create a global unicast address?
  4. An interface with MAC address 00-1A-2B-3C-4D-5E creates an address with SLAAC from the prefix 2001:db8:1:1::/64 and an interface ID in the EUI-64 format. Which address results?
  5. Two sites that run only IPv6 are to be connected through a network that runs only IPv4, and the traffic between the sites should remain IPv6 packets. Which method is appropriate?

Comparisons in this topic