Iptables Open VNC Port To Allow Incoming VNC Connections

www.lautt‮iru‬.com
Iptables Open VNC Port To Allow Incoming VNC Connections

To open the VNC port (5900) to allow incoming VNC connections using the iptables firewall in Linux, you can use the following steps:

  1. Allow incoming traffic on port 5900 by running the following command:
iptables -A INPUT -p tcp --dport 5900 -j ACCEPT

This will allow incoming traffic on port 5900 using the TCP protocol.

  1. Save the iptables configuration by running the following command:
service iptables save

This will persist the changes across system reboots.

Note: The above steps assume that you have the necessary permissions to modify the iptables configuration. Make sure to test the changes before using them in a production environment.

Additionally, make sure that you have a VNC server installed and running on the machine. If you don't have a VNC server installed, you can install a VNC server such as TightVNC or VNC Connect and configure it to listen on port 5900.

To check if the VNC server is listening on port 5900, you can use the "netstat" command to list the open ports on the machine. Run the following command:

netstat -tulpn

This will list all the open ports and the process that is listening on each port. If you see "tcp" and "0.0.0.0:5900" in the output, it means that a process is listening on port 5900.

Created Time:2017-10-29 22:08:49  Author:lautturi