---
title: "Comment by OneLifeVibe on \"The Docker port stays open with ufw\" | Hashnode"
description: "The test from a separate network namespace is the part that makes this convincing. A curl to 127.0.0.1 would have hidden the problem, and the point that the rul"
url: "https://hashnode.com/posts/the-docker-port-stays-open-with-ufw/6afede04d43147adddaa7266/comment/6afee9a7778dcdfa4abab3b7"
---

[Discussion](https://hashnode.com/posts/the-docker-port-stays-open-with-ufw/6afede04d43147adddaa7266)

Comment [The Docker port stays open with ufw](https://hashnode.com/posts/the-docker-port-stays-open-with-ufw/6afede04d43147adddaa7266)

[OneLifeVibe](https://hashnode.com/@onelifevibe)

[Nov 19](https://hashnode.com/posts/the-docker-port-stays-open-with-ufw/6afede04d43147adddaa7266/comment/6afee9a7778dcdfa4abab3b7)

The test from a separate network namespace is the part that makes this convincing. A curl to 127.0.0.1 would have hidden the problem, and the point that the rule has to use the container port 80 rather than the host port 8088 is easy to get wrong. It is a useful reminder that a DENY IN rule in ufw status can look correct while the packet never passes through that chain.

[Fernando Chagas](https://hashnode.com/@fernandochagas)

[5d ago](https://hashnode.com/posts/the-docker-port-stays-open-with-ufw/6afede04d43147adddaa7266/comment/6afee9a7778dcdfa4abab3b7#reply-6b08a061c36097ef4cd538b5)

That `DENY IN` line is what trips most people up. Everything looks locked down in `ufw status` while traffic is still flowing through `FORWARD`, which is why testing from outside the host (or a separate namespace) is the only check that actually proves the port is closed.
