Port 520: RIP

Port 520 (UDP) is used by RIP. Routing Information Protocol, an early distance-vector routing protocol.

520Port
UDPProtocol
routerIANA service name
Network infrastructureCategory

Port range

520 is a well-known (system) port (range 0–1023). On Linux and macOS, binding to it traditionally needs root or the CAP_NET_BIND_SERVICE capability.

Security

Only open port 520 to the hosts that need it. Prefer the encrypted variant of the protocol where one exists.

Open port 520 in a firewall

ufw         sudo ufw allow 520/udp
iptables    sudo iptables -A INPUT -p udp --dport 520 -j ACCEPT
firewalld   sudo firewall-cmd --permanent --add-port=520/udp
Windows     New-NetFirewallRule -DisplayName "RIP 520" -Direction Inbound -Protocol UDP -LocalPort 520 -Action Allow

Check if port 520 is open

nc -vzu example.com 520   # UDP checks are unreliable: no reply ≠ closed
sudo ss -tulpn | grep ':520 '   # what is listening locally (Linux)

Other network infrastructure ports

Frequently asked questions

What is port 520 used for?
RIP. Routing Information Protocol, an early distance-vector routing protocol.
Is port 520 TCP or UDP?
UDP.