Tagged articles
14 articles
Page 1 of 1
Liangxu Linux
Liangxu Linux
Mar 19, 2023 · Operations

How to Add or Modify Docker Container Port Mappings After Creation

This guide explains step‑by‑step how to add, change, or remove port mappings for Docker containers by stopping the container, editing hostconfig.json (and optionally config.v2.json), and restarting the container, with commands for both Linux and Docker Desktop for Mac.

Container ConfigurationDevOpsDocker
0 likes · 6 min read
How to Add or Modify Docker Container Port Mappings After Creation
Open Source Linux
Open Source Linux
Jul 14, 2022 · Information Security

Why Mapping Docker Ports to 127.0.0.1 Isn’t Safe – Exploit and Fix

A recent Docker security issue shows that publishing container ports to 127.0.0.1 does not prevent external access, because Docker adds an iptables rule that forwards traffic to the container’s internal IP, allowing attackers on the same network to reach the service.

Vulnerabilityiptablesport mapping
0 likes · 7 min read
Why Mapping Docker Ports to 127.0.0.1 Isn’t Safe – Exploit and Fix
Liangxu Linux
Liangxu Linux
Jul 10, 2022 · Information Security

Why Docker’s 127.0.0.1 Port Mapping Still Exposes Services – Proof and Fix

A recent Hacker News discussion revealed that Docker’s iptables rule allows containers bound to 127.0.0.1 to be reachable from other hosts, and a step‑by‑step proof‑of‑concept demonstrates the issue while a revised iptables rule is proposed to enforce proper source‑address restrictions.

Container SecurityDockeriptables
0 likes · 7 min read
Why Docker’s 127.0.0.1 Port Mapping Still Exposes Services – Proof and Fix