When managing firewalls with Panorama, understanding the precise order in which different types of policy rules are evaluated is absolutely critical for ensuring correct traffic handling and security enforcement. A firewall managed by Panorama effectively combines rules from multiple sources:
Panorama provides structure through Pre-rules and Post-rules within Device Groups and Shared scope to control precedence. This guide differentiates the use cases for each rule type within this evaluation hierarchy.
When a packet requiring a policy decision hits a Panorama-managed firewall, the rules are checked in this strict order across *all applicable policy types* (Security, NAT, Decryption, QoS, PBF, etc., although Default rules are specific to Security Policy):
graph TD Start[Packet Arrives] --> SharedPre(Shared Pre-Rules); SharedPre --> ParentPre(Parent DG Pre-RulesFirewall Policy Evaluation Order (Simplified). The first rule matched determines the action.
Top-down in Hierarchy); ParentPre --> ChildPre(Child DG Pre-Rules); ChildPre --> LocalFW(Local Firewall Rules); LocalFW --> ChildPost(Child DG Post-Rules); ChildPost --> ParentPost(Parent DG Post-Rules
Bottom-up in Hierarchy); ParentPost --> SharedPost(Shared Post-Rules); SharedPost --> DefaultSec(Default Security Rules
Intra/Interzone - For Security Policy ONLY); DefaultSec --> FinalAction[Final Action Determined]; LocalFW -- First Match --> FinalAction; ChildPre -- First Match --> FinalAction; ParentPre -- First Match --> FinalAction; SharedPre -- First Match --> FinalAction; ChildPost -- First Match --> FinalAction; ParentPost -- First Match --> FinalAction; SharedPost -- First Match --> FinalAction; style Start fill:#e9ecef,stroke:#adb5bd style FinalAction fill:#e9ecef,stroke:#adb5bd style LocalFW fill:#fdebd0,stroke:#f5b041,stroke-width:2px style DefaultSec fill:#eaf2f8,stroke:#aed6f1,stroke-width:2px
The first rule in this sequence that matches the traffic determines the action taken. No further rules *in that specific policy type* (e.g., Security) are evaluated for that session.
Rules configured in the "Pre Rules" section within Panorama's Shared scope or any Device Group.
FIRST - Before any Local Firewall rules and before any Post-rules.
Policy rules configured directly on the individual firewall's GUI or CLI, *not* pushed from Panorama Templates or Device Groups.
MIDDLE - After ALL Pre-rules (from Shared down to the Child DG) have been evaluated, but before ANY Post-rules are evaluated.
Two implicit, non-configurable rules that exist at the very bottom of the Security Policy rulebase only.
ABSOLUTE LAST (for Security Policy) - Only evaluated if NO other Security Policy rule (Shared Pre, DG Pre, Local, Child DG Post, Parent DG Post, Shared Post) matches the traffic.
intrazone-default
: Matches traffic where the source and destination zones are the
same
. Action:
Allow
.
interzone-default
: Matches traffic where the source and destination zones are
different
. Action:
Deny
.
Rules configured in the "Post Rules" section within Panorama's Shared scope or any Device Group.
LATE - After all Pre-rules and Local Firewall rules, but before the Default Security rules.
Rule Type | Evaluation Point | Primary Use Case | Managed Via |
---|---|---|---|
Pre-Rule (DG/Shared) | Early (Before Local) | Global blocks, universal infrastructure allows, high-precedence enforcement | Panorama |
Local Rule | Middle (After Pre, Before Post) | Device-specific exceptions, troubleshooting (use with caution) | Firewall GUI/CLI |
Post-Rule (DG/Shared) | Late (After Local, Before Default) | Cleanup rules (explicit deny all w/ logging), broad/fallback allow rules | Panorama |
Default Rule (Security Only) | Absolute Last | Implicit allow within zone, implicit deny between zones (if no other rule matches) | Built-in (Not Configurable) |
For the PCNSE exam, make sure you can:
1. In a Panorama-managed firewall, which set of rules is evaluated FIRST for a new session?
2. What is the primary purpose of configuring rules in the Post-rule section of a Device Group?
3. What is the action of the implicit `interzone-default` Security Policy rule?
4. If a specific "Allow" rule exists in the Local Firewall configuration, can it be blocked by a "Deny" rule configured in the Post-rules section of its Device Group?
5. Which rule type is typically used to implement a universal block for known malicious domains using an EDL across all managed firewalls?
6. What is the action of the implicit `intrazone-default` Security Policy rule?
7. An administrator adds a rule directly to a firewall managed by Panorama for temporary troubleshooting. Where does this rule fit in the evaluation order?
8. Why is enabling logging on an explicit "deny any any" rule in the Post-rules section considered a best practice?
9. A Security Policy rule allowing 'web-browsing' is placed in the Post-rules section of a Device Group. When will this rule apply?
10. Do the Default Security rules (`intrazone-default`, `interzone-default`) apply to NAT Policy evaluation?