Hi, so I'll try to be short.
I've been using google cloud for a while now. I have Ubuntu and I'm using VNC to access and host some online game rooms for my friends and I.
I often get locked out of VNC (can't connect due to too many failed authentications). Later I found out there have been brute force attacks every 2 or so hours mostly from Ukraine.
I had the iptables set so the port 5901 which I use will only let my IP connect, so how is it locking me out?
Later I tried setting the google cloud firewall for my account and that did work, but I just want to know if iptables are actually not preventing this issue.
Also, is there a way to reset failed authentications, so I don't have to close the instance and open it again to access it (I would have to rehost all the rooms again if I did that)?
Edit : this is what i've been using so far :
sudo iptables -S
sudo iptables -F INPUT
sudo iptables -I INPUT -p tcp -s myip --dport 5901 -j ACCEPT
sudo iptables -A INPUT -p tcp -s myip --dport 5901 -j DROP
sudo iptables -S
[link] [comments]