Limiting port access

Hi everybody,

I'm trying to limit port access as I have two public IPs on my node, so I'd like to leave port 80 and 22 open on 12.34.56.78 (public IP, primary server address), but deny everything else, and only allow 443, 943, and 1194 on 98.76.54.32 (public IP, secondary server address). Does this make sense? I don't want somebody using the primary server address to access our VPN, which is utilizing the secondary IP.

Thanks for your assistance.

-Tyler

1 Reply

That's very easy to do with iptables (-d or –destination option to specify the target IP address).

Not sure it gies you much of a "win" in terms of security, though. Why would you want to do this?

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct