Block port on certain IP
Posted: 03 Jun 2014, 20:48
I've got a server with multiple public-facing IPs, and I'd like certain services to only be bound on certain IPs. Services like SSH and FTP can simply be configured to only bind to a single interface, but I've got a couple stubborn ones that insist on binding to them all.
What I'm basically looking for is something like the TCP_IN option, but address-specific. For example, connections to 1.2.3.4:9000 are allowed, but connections to port 5.6.7.8:9000 are not.
What's the best way to do something like this? I can manage with either a black- or whitelisting solution.
What I'm basically looking for is something like the TCP_IN option, but address-specific. For example, connections to 1.2.3.4:9000 are allowed, but connections to port 5.6.7.8:9000 are not.
What's the best way to do something like this? I can manage with either a black- or whitelisting solution.