How can I configure UFW to allow VNC access to my computer from a specific IP address?


I am connecting from another local device to my laptop. How can I configure the UFW to let my specific device through?


Ubuntu 15.04


From https://www.digitalocean.com/community/tutorials/ufw-essentials-common-firewall-rules-and-commands

This would be
sudo ufw allow from to any port 5900

  • 1
    Yes, just found the same solution. I had been making a simple mistake in my previous inputs. Thanks, correct answer. – Vesa Aug 9 '17 at 13:37
  • Depending on your use case, note that "from any to any" covers all incoming addresses and "from to any" allows a specific subnet. – VoteCoffee Jan 18 at 11:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.