[DiscordArchive] Did you move your docker host to a DMZ or something?
[DiscordArchive] Did you move your docker host to a DMZ or something?
Archived author: Foe • Posted: 2023-01-17T21:49:49.686000+00:00
Original source
iptables -A INPUT -p tcp --dport 3306 -j DROP
Archived author: Foe • Posted: 2023-01-17T21:50:08.284000+00:00
Original source
that will allow it on localhost level but drop it from any external connection
Archived author: notsure • Posted: 2023-01-17T21:51:40.013000+00:00
Original source
Sounds good - I didn’t realize the firewall was that open by default
Archived author: Foe • Posted: 2023-01-17T21:52:31.898000+00:00
Original source
iptables comes completely bare, you'll have to build the rules yourself
Archived author: Foe • Posted: 2023-01-17T21:53:29.799000+00:00
Original source
Do you have local access to the server?
Archived author: Foe • Posted: 2023-01-17T21:54:31.195000+00:00
Original source
Or physical/console level, I should say
Archived author: notsure • Posted: 2023-01-17T21:54:31.489000+00:00
Original source
I can, if necessary. Right now it’s remote.
Archived author: Foe • Posted: 2023-01-17T21:54:43.815000+00:00
Original source
```# Set default chain policies
iptables -P INPUT DROP
iptables -P FORWARD DROP
iptables -P OUTPUT ACCEPT
# Accept on localhost
iptables -A INPUT -i lo -j ACCEPT
iptables -A OUTPUT -o lo -j ACCEPT
# Allow established sessions to receive traffic
iptables -A INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT```
Archived author: Foe • Posted: 2023-01-17T21:54:54.960000+00:00
Original source
Be careful with that
Archived author: notsure • Posted: 2023-01-17T21:55:13.004000+00:00
Original source
Added the rules, but can still hit the database remotely