Display the Natted / Routed Connections on a Linux Iptable Firewall

w‮ual.ww‬tturi.com
Display the Natted / Routed Connections on a Linux Iptable Firewall

To display the NATted (Network Address Translation) connections on a Linux firewall that uses iptables, you can use the iptables command with the -t nat option and the -L flag. This will show the NAT rules that are currently configured in the firewall. For example:

iptables -t nat -L

This will show a list of the NAT rules that are currently configured on the firewall. The output will include the chain name, the rule number, the target of the rule, the protocol, and the source and destination addresses and ports.

If you want to see the routed connections on the firewall, you can use the ip route command. This command will show the routing table for the system, which lists the routes that are currently configured. For example:

ip route

This will show a list of the routes that are currently configured on the system. The output will include the destination address, the gateway address, and the interface through which the traffic will be sent.

Keep in mind that these commands will only show the NATted and routed connections that are currently active on the firewall. If you want to see NATted or routed connections that were active in the past, you will need to use a different method.

Created Time:2017-10-28 14:02:28  Author:lautturi