PAN-OS operational standards
Rules that check a firewall matches your standard, not a security benchmark. They catch drift: a firewall someone set up by hand with the wrong NTP server or hostname. They come from the panos-operational-standards policy template.
Every example on this page was checked with rConfig Pro's policy engine on Each of the 16 configs below was run through rConfig Pro’s evaluator with the rule above it, and gave the result shown. The configs are sanitised excerpts of the sample configs that come with the template. A card marked changed has one line edited to show a failure.
All the rules come from panos-operational-standards.policy in the policy templates (v1.5.0). Import the whole file with Import Templates (see importing a policy template), or copy one rule into your own definition. The Palo Alto PAN-OS templates page lists the file’s known limitations. Run the rules against show config running (brace format).
| Rule | Method | Since |
|---|---|---|
| NTP servers | evaluate_block |
8.3.0 |
| Syslog servers | evaluate_block |
8.3.0 |
| DNS servers | evaluate_block |
8.3.0 |
| Login banner | must_match_regex |
8.0.0 |
| Every ethernet interface has a comment or is down | evaluate_block |
8.3.0 |
| Hostname pattern | evaluate_block |
8.3.0 |
| SNMP location | evaluate_block |
8.3.0 |
NTP servers
Both NTP server slots must hold your standard servers. The example values are 192.0.2.10 and 192.0.2.11. PAN-OS has two slots, a primary and a secondary, so the rule checks both.
// NTP servers are set to your standard (replace 192.0.2.10 and 192.0.2.11)#[evaluate_block]all: - regex: '/(^|[{;])\s*ntp-server-address 192\.0\.2\.10;/m' - regex: '/(^|[{;])\s*ntp-server-address 192\.0\.2\.11;/m'ntp-servers { primary-ntp-server { ntp-server-address 192.0.2.10; authentication-type { none; } } secondary-ntp-server { ntp-server-address 192.0.2.11; authentication-type { none; } }}Why: Both standard NTP servers are set.
ntp-servers { primary-ntp-server { ntp-server-address 192.0.2.1; authentication-type { none; } } secondary-ntp-server { ntp-server-address 192.0.2.2; authentication-type { none; } }}Why: The NTP servers are not the standard ones.
Expected result in rConfig, with this rule as the only rule in a definition:
| Config | Rule result | Overall result |
|---|---|---|
| Passing config | pass | PASS |
| Failing config | fail | FAIL |
Framework mapping. The rule provides evidence towards these controls. It does not certify anything.
| Framework | Reference |
|---|---|
| None recorded | See Compliance frameworks |
Tested with: sample excerpts from PAN-OS 11.1.4 (synthetic). Minimum rConfig 8.3.0 (evaluate_block). Editions: Pro, Vector, Enterprise.
Syslog servers
A syslog server profile must list both your standard servers. The example values are 192.0.2.20 and 192.0.2.21. If the config has no syslog block, the rule fails.
// Syslog servers are set to your standard (replace 192.0.2.20 and 192.0.2.21)#[evaluate_block]scope: ^syslog \{all: - regex: '/(^|[{;])\s*server 192\.0\.2\.20;/m' - regex: '/(^|[{;])\s*server 192\.0\.2\.21;/m'syslog { CORP-SYSLOG { server { SYSLOG01 { server 192.0.2.20; transport UDP; port 514; } SYSLOG02 { server 192.0.2.21; transport UDP; port 514; } } }}Why: Both standard syslog servers are listed.
syslog { CORP-SYSLOG { server { SYSLOG01 { server 192.0.2.20; transport UDP; port 514; } SYSLOG02 { server 192.0.2.50; transport UDP; port 514; } } }}Why: The second server is not one of the standard ones.
Expected result in rConfig, with this rule as the only rule in a definition:
| Config | Rule result | Overall result |
|---|---|---|
| Passing config | pass | PASS |
| Failing config | fail | FAIL |
Framework mapping. The rule provides evidence towards these controls. It does not certify anything.
| Framework | Reference |
|---|---|
| None recorded | See Compliance frameworks |
Tested with: sample excerpts from PAN-OS 11.1.4 (synthetic). Minimum rConfig 8.3.0 (evaluate_block). Editions: Pro, Vector, Enterprise.
DNS servers
The dns-setting block must set your standard primary and secondary DNS servers. The example values are 192.0.2.30 and 192.0.2.31.
// DNS servers are set to your standard (replace 192.0.2.30 and 192.0.2.31)#[evaluate_block]scope: ^dns-setting \{all: - regex: '/(^|[{;])\s*primary 192\.0\.2\.30;/m' - regex: '/(^|[{;])\s*secondary 192\.0\.2\.31;/m'dns-setting { servers { primary 192.0.2.30; secondary 192.0.2.31; }}Why: Both standard DNS servers are set.
dns-setting { servers { primary 192.0.2.53; secondary 192.0.2.54; }}Why: The DNS servers are not the standard ones.
Expected result in rConfig, with this rule as the only rule in a definition:
| Config | Rule result | Overall result |
|---|---|---|
| Passing config | pass | PASS |
| Failing config | fail | FAIL |
Framework mapping. The rule provides evidence towards these controls. It does not certify anything.
| Framework | Reference |
|---|---|
| None recorded | See Compliance frameworks |
Tested with: sample excerpts from PAN-OS 11.1.4 (synthetic). Minimum rConfig 8.3.0 (evaluate_block). Editions: Pro, Vector, Enterprise.
Login banner
A login banner must be set. Any text passes, so there is nothing to replace. This is the same check as the management access banner rule.
// A login banner is set (login-banner, any text; nothing to replace)#[must_match_regex]/(^|[{;])\s*login-banner \S/mdeviceconfig { system { hostname dub-fw01; login-banner "Authorised use only. All activity is monitored and recorded."; }}Why: A login banner is set.
deviceconfig { system { hostname dub-hq-fw02; domain example.com; }}Why: There is no login-banner line.
Expected result in rConfig, with this rule as the only rule in a definition:
| Config | Rule result | Overall result |
|---|---|---|
| Passing config | pass | PASS |
| Failing config | fail | FAIL |
Framework mapping. The rule provides evidence towards these controls. It does not certify anything.
| Framework | Reference |
|---|---|
| None recorded | See Compliance frameworks |
Tested with: sample excerpts from PAN-OS 11.1.4 (synthetic). Minimum rConfig 8.0.0 (must_match_regex). Editions: Pro, Vector, Enterprise.
Every ethernet interface has a comment or is down
A comment says what a port is for. This rule checks each ethernetN/N block for a comment or link-state down;. Subinterfaces sit inside their parent’s block, so a comment on a subinterface counts for the parent. Aggregate and VLAN interfaces are not checked.
// Every ethernet interface has a comment or is set to link-state down (nothing to replace)#[evaluate_block]scope: ^ethernet\d+/\d+ \{any: - regex: '/\bcomment "?[^"\s;]/m' - regex: '/\blink-state down;/m'ethernet { ethernet1/1 { layer3 { ip { 203.0.113.10/29; } interface-management-profile ALLOW-PING; } comment "Internet uplink"; } ethernet1/4 { layer3 { ip { 198.51.100.97/27; } } comment "PCI cardholder data environment"; }}Why: Both interfaces have a comment.
ethernet { ethernet1/1 { layer3 { ip { 203.0.113.10/29; } interface-management-profile ALLOW-PING; } comment "Internet uplink"; } ethernet1/4 { layer3 { ip { 198.51.100.97/27; } } comment "PCI cardholder data environment"; }}Why: The same interfaces printed on one line give the same result.
ethernet { ethernet1/3 { layer3 { ip { 198.51.100.65/27; } interface-management-profile ALLOW-PING; } comment "DMZ"; } ethernet1/4 { layer3 { ip { 198.51.100.97/27; } } }}Why: ethernet1/4 has no comment and is not down.
Expected result in rConfig, with this rule as the only rule in a definition:
| Config | Rule result | Overall result |
|---|---|---|
| Passing config 1 | pass | PASS |
| Passing config 2 | pass | PASS |
| Failing config | fail | FAIL |
Framework mapping. The rule provides evidence towards these controls. It does not certify anything.
| Framework | Reference |
|---|---|
| None recorded | See Compliance frameworks |
Tested with: sample excerpts from PAN-OS 11.1.4 (synthetic). Minimum rConfig 8.3.0 (evaluate_block). Editions: Pro, Vector, Enterprise.
Hostname pattern
Hostnames must follow your naming pattern. The example pattern is three letters, -fw and two digits, for example dub-fw01. The rule checks the deviceconfig block.
// The hostname follows your naming pattern (replace the example pattern [a-z]{3}-fw[0-9]{2}, for example dub-fw01)#[evaluate_block]scope: ^deviceconfig \{$all: - regex: '/(^|[{;])\s*hostname [a-z]{3}-fw[0-9]{2};/m'deviceconfig { system { hostname dub-fw01; ip-address 192.0.2.5; netmask 255.255.255.0; default-gateway 192.0.2.1; }}Why: dub-fw01 matches the pattern.
deviceconfig { system { hostname dub-hq-fw02; ip-address 192.0.2.6; netmask 255.255.255.0; default-gateway 192.0.2.1; }}Why: dub-hq-fw02 does not match the pattern.
Expected result in rConfig, with this rule as the only rule in a definition:
| Config | Rule result | Overall result |
|---|---|---|
| Passing config | pass | PASS |
| Failing config | fail | FAIL |
Framework mapping. The rule provides evidence towards these controls. It does not certify anything.
| Framework | Reference |
|---|---|
| None recorded | See Compliance frameworks |
Tested with: sample excerpts from PAN-OS 11.1.4 (synthetic). Minimum rConfig 8.3.0 (evaluate_block). Editions: Pro, Vector, Enterprise.
SNMP location
The snmp-system block must have a location line. Any text passes, so there is nothing to replace. If there is no snmp-system block, the rule fails.
// An SNMP location is set (snmp-setting snmp-system location, any text; nothing to replace)#[evaluate_block]scope: ^snmp-system \{all: - regex: '/(^|[{;])\s*location \S/m'snmp-setting { snmp-system { location "Dublin HQ, comms room 1"; contact noc@example.com; }}Why: A location is set.
snmp-setting { snmp-system { location "Dublin HQ, comms room 1"; contact noc@example.com; }}Why: The same block printed on one line gives the same result.
snmp-setting { access-setting { version { v2c { snmp-community-string hq-ro; } } }}Why: There is no snmp-system block, so there is no location.
Expected result in rConfig, with this rule as the only rule in a definition:
| Config | Rule result | Overall result |
|---|---|---|
| Passing config 1 | pass | PASS |
| Passing config 2 | pass | PASS |
| Failing config | fail | FAIL |
Framework mapping. The rule provides evidence towards these controls. It does not certify anything.
| Framework | Reference |
|---|---|
| None recorded | See Compliance frameworks |
Tested with: sample excerpts from PAN-OS 11.1.4 (synthetic). Minimum rConfig 8.3.0 (evaluate_block). Editions: Pro, Vector, Enterprise.
Related reference
- Palo Alto PAN-OS policy templates: every rule in
panos-operational-standards.policy, its references and known limitations. - Policy Definitions: the definition file format and every method.
- Policy Assignments: run a definition against your devices.
- Policy Compliance Results: read the pass and fail results.