ASA Inspect Everything – Cisco ASA Configuration Guide

cisco-asa

As you know, packets flow from higher security level interfaces to lower ones by default. If you want to have an operational connection between two interfaces, your ASA must inspect the traffic so that it won't drop the connections initiated from inside.

For example, if I want ping to work I must inspect ICMP.

Here is the question: What if I have a computer outside listening on an arbitrary port, and I want to connect to that computer from inside (obviously from a randomly generated port by OS)?

Packets can get from inside to outside because of security levels, but since ASA doesn't inspect the traffic will it drop the return packets from outside to inside?

Best Answer

It won't drop the packets, because the ASA is a Stateful device.

First, you have to understand what I mean when I say the ASA is a stateful device. This means if the firewall allowed traffic in the direction outbound, it automatically allows the correlating return traffic back inbound -- even if the inbound ACL or Security-Level would have prevented all traffic inbound.

As for ICMP, by default, ICMP is not stateful. Which is to say, if you want to allow ICMP packets to leave your network, you must explicitly allow it (via ACL or Security-Level). And if you intend for ICMP packets to come back into your network, you must also explicitly allow it.

However, you can override that default behavior by enabling ICMP inspection. On the ASA inspecting ICMP makes the ASA consider ICMP stateful. Which means, if it allows an ICMP Echo Request leave your network, it will automatically allow the ICMP Echo Response come back into your network.