DKER-EE-002160 - Docker Enterprise incoming container traffic must be bound to a specific host interface.


By default, Docker containers can make connections to the outside world, but the outside world cannot connect to containers. Each outgoing connection will appear to originate from one of the host machine's own IP addresses. Only allow container services to be contacted through a specific external interface on the host machine.

If there are multiple network interfaces on the host machine, the container can accept connections on the exposed ports on any network interface. This might not be desired and may not be secured. Many times, a particular interface is exposed externally and services such as intrusion detection, intrusion prevention, firewall, load balancing, etc. are run on those interfaces to screen incoming public traffic. Hence, do not accept incoming connections on any interface. Only allow incoming connections from a particular external interface.

By default, Docker exposes the container ports on, the wildcard IP address that will match any possible incoming network interface on the host machine.


Bind the container port to a specific host interface on the desired host port.

docker run --detach --publish nginx

In the example above, the container port 80 is bound to the host port on 49153 and would accept incoming connection only from external interface.

See Also

Item Details


References: 800-53|CM-7b., CAT|II, CCI|CCI-000382, Rule-ID|SV-235820r627587_rule, STIG-ID|DKER-EE-002160, STIG-Legacy|SV-104813, STIG-Legacy|V-95675, Vuln-ID|V-235820

Plugin: Unix

Control ID: caf45e48f53bf7a7d4bc4000b57bf4f015d3f6928db6fba452df117edb514801