IOS-XE services
Rules that turn off services a router or switch does not need. Every service that is on is something that can be attacked. They come from the ios-services policy template.
Every example on this page was checked with rConfig Pro's policy engine on Each of the 22 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 ios-services.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 Cisco IOS templates page lists the file’s known limitations. Run the rules against show running-config.
| Rule | Method | Since |
|---|---|---|
| HTTP server off | must_not_match_single_string |
8.0.0 |
| HTTPS server off | must_not_match_single_string |
8.0.0 |
| Finger off | must_not_match_regex |
8.0.2 |
| BOOTP server disabled | must_match_single_string |
8.0.0 |
| TCP small servers off | must_not_match_single_string |
8.0.0 |
| UDP small servers off | must_not_match_single_string |
8.0.0 |
| PAD disabled | must_match_single_string |
8.0.0 |
| Source routing disabled | must_match_single_string |
8.0.0 |
| identd off | must_not_match_single_string |
8.0.0 |
| CDP disabled | must_match_single_string |
8.0.0 |
| No directed broadcast | must_not_match_regex |
8.0.2 |
HTTP server off
The web server is an extra way in, and plain HTTP sends logins in clear text. This rule fails on the exact line ip http server. no ip http server is a different line, so it passes.
// The HTTP server is not enabled (line ip http server is absent)#[must_not_match_single_string]ip http serverno ip http serverip http authentication localno ip http secure-serverWhy: The HTTP server is off.
ip http serverip http authentication localno ip http secure-serverWhy: The HTTP server is on.
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 |
|---|---|
| NIST SP 800-53 | CM-7 |
| ISO/IEC 27001:2022 Annex A | A.8.9 |
Tested with: sample excerpts from IOS-XE 17.9 (synthetic). Minimum rConfig 8.0.0 (must_not_match_single_string). Editions: Pro, Vector, Enterprise.
HTTPS server off
HTTPS is safer than HTTP, but if you manage devices over SSH and rConfig, the web server is still an extra service to patch. This rule fails on the exact line ip http secure-server.
// The HTTPS server is not enabled (line ip http secure-server is absent)#[must_not_match_single_string]ip http secure-serverno ip http serverip http authentication localno ip http secure-serverWhy: The HTTPS server is off.
no ip http serverip http authentication localip http secure-serverip http secure-client-authWhy: The HTTPS server is on.
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 |
|---|---|
| NIST SP 800-53 | CM-7 |
| ISO/IEC 27001:2022 Annex A | A.8.9 |
Tested with: sample excerpts from IOS 15.7 (lab) and IOS-XE 17.9 (synthetic). Minimum rConfig 8.0.0 (must_not_match_single_string). Editions: Pro, Vector, Enterprise.
Finger off
Finger tells anyone who asks who is logged in. This rule fails on service finger or ip finger, the old and new forms of the command.
// The finger service is not enabled (fails on a service finger or ip finger line)#[must_not_match_regex]/^\s*(service|ip) finger\b/mno service padservice timestamps log datetime msecservice password-encryptionWhy: There is no finger line.
no service padservice timestamps log datetime msecservice password-encryptionip fingerWhy: Finger is on.
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 |
|---|---|
| NIST SP 800-53 | CM-7 |
| HIPAA (45 CFR) | 164.312(c)(1) |
| ISO/IEC 27001:2022 Annex A | A.8.9 |
Tested with: sample excerpts from IOS-XE 17.9 (synthetic). Minimum rConfig 8.0.2 (must_not_match_regex). Editions: Pro, Vector, Enterprise.
BOOTP server disabled
The BOOTP server can hand out boot images and addresses to anything on the segment. It is on by default, so the rule looks for no ip bootp server.
// The BOOTP server is disabled (no ip bootp server)#[must_match_single_string]no ip bootp serverno ip bootp serverno ip http serverno ip http secure-serverWhy: BOOTP is turned off.
ip forward-protocol nd!no ip http serverip http authentication localWhy: There is no no ip bootp server line, so BOOTP is on by default.
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 |
|---|---|
| NIST SP 800-53 | CM-7 |
| HIPAA (45 CFR) | 164.312(c)(1) |
| ISO/IEC 27001:2022 Annex A | A.8.9 |
Tested with: sample excerpts from IOS 15.7 (lab) and IOS-XE 17.9 (synthetic). Minimum rConfig 8.0.0 (must_match_single_string). Editions: Pro, Vector, Enterprise.
TCP small servers off
TCP small servers (echo, discard, daytime and chargen) are test services that can be abused for denial of service. This rule fails on the exact line service tcp-small-servers.
// TCP small servers are not enabled (line service tcp-small-servers is absent)#[must_not_match_single_string]service tcp-small-serversno service padservice timestamps log datetime msecservice password-encryptionWhy: There is no service tcp-small-servers line.
no service padservice tcp-small-serversservice timestamps log datetime msecservice password-encryptionWhy: TCP small servers are on.
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 |
|---|---|
| NIST SP 800-53 | CM-7 |
| HIPAA (45 CFR) | 164.312(c)(1) |
| ISO/IEC 27001:2022 Annex A | A.8.9 |
Tested with: sample excerpts from IOS-XE 17.9 (synthetic). Minimum rConfig 8.0.0 (must_not_match_single_string). Editions: Pro, Vector, Enterprise.
UDP small servers off
The UDP versions of the same test services. Spoofed UDP packets to them can be used to flood another host. This rule fails on the exact line service udp-small-servers.
// UDP small servers are not enabled (line service udp-small-servers is absent)#[must_not_match_single_string]service udp-small-serversno service padservice timestamps log datetime msecservice password-encryptionWhy: There is no service udp-small-servers line.
no service padservice udp-small-serversservice timestamps log datetime msecservice password-encryptionWhy: UDP small servers are on.
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 |
|---|---|
| NIST SP 800-53 | CM-7 |
| ISO/IEC 27001:2022 Annex A | A.8.9 |
Tested with: sample excerpts from IOS-XE 17.9 (synthetic). Minimum rConfig 8.0.0 (must_not_match_single_string). Editions: Pro, Vector, Enterprise.
PAD disabled
PAD is for X.25 networks, which almost nobody runs now. It is on by default, so the rule looks for no service pad.
// The PAD service is disabled (no service pad)#[must_match_single_string]no service padno service padservice timestamps debug datetime msec localtime show-timezoneservice timestamps log datetime msecWhy: PAD is turned off.
service timestamps debug datetime msecservice timestamps log datetime msecno service password-encryptionno service dhcpWhy: There is no no service pad line, so PAD is on by default.
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 |
|---|---|
| ISO/IEC 27001:2022 Annex A | A.8.9 |
Tested with: sample excerpts from IOS 15.7 (lab) and IOS-XE 17.9 (synthetic). Minimum rConfig 8.0.0 (must_match_single_string). Editions: Pro, Vector, Enterprise.
Source routing disabled
With source routing, the sender of a packet picks its path, which can be used to get round your filters. It is on by default, so the rule looks for no ip source-route.
// IP source routing is disabled (no ip source-route)#[must_match_single_string]no ip source-routeno ip source-route!ip domain name example.comWhy: Source routing is turned off.
no ip subnet-zero!no ip domain lookupip domain name example.comWhy: There is no no ip source-route line, so source routing is on by default.
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 |
|---|---|
| NIST SP 800-53 | SC-5 |
| ISO/IEC 27001:2022 Annex A | A.8.20 |
Tested with: sample excerpts from IOS 15.7 (lab) and IOS-XE 17.9 (synthetic). Minimum rConfig 8.0.0 (must_match_single_string). Editions: Pro, Vector, Enterprise.
identd off
identd answers questions about which user owns a TCP connection, which leaks information. This rule fails on the exact line ip identd.
// The identd service is not enabled (line ip identd is absent)#[must_not_match_single_string]ip identdno ip source-route!ip domain name example.comWhy: There is no ip identd line.
no ip source-routeip identd!ip domain name example.comWhy: identd is on.
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 |
|---|---|
| ISO/IEC 27001:2022 Annex A | A.8.9 |
Tested with: sample excerpts from IOS-XE 17.9 (synthetic). Minimum rConfig 8.0.0 (must_not_match_single_string). Editions: Pro, Vector, Enterprise.
CDP disabled
CDP tells neighbours the device’s model, software version and addresses. That is useful on the inside, and useful to an attacker too. It is on by default, so the rule looks for no cdp run. If you rely on CDP, leave this rule out.
// CDP is disabled globally (no cdp run)#[must_match_single_string]no cdp runno cdp runWhy: CDP is turned off.
ip forward-protocol nd!no ip http serverip http secure-serverWhy: There is no no cdp run line, so CDP is on by default.
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 |
|---|---|
| NIST SP 800-53 | CM-7 |
| ISO/IEC 27001:2022 Annex A | A.8.9 |
Tested with: sample excerpts from IOS 15.7 (lab) and IOS-XE 17.9 (synthetic). Minimum rConfig 8.0.0 (must_match_single_string). Editions: Pro, Vector, Enterprise.
No directed broadcast
Directed broadcast lets a remote host send a broadcast to a whole subnet. It was the basis of smurf attacks. It is off by default, so this rule fails only when an interface has ip directed-broadcast.
// Directed broadcast is not enabled on any interface (fails on any ip directed-broadcast line)#[must_not_match_regex]/^\s*ip directed-broadcast\b/minterface Vlan99 description Management ip address 192.0.2.12 255.255.255.0 no ip proxy-arp!Why: There is no ip directed-broadcast line.
interface Vlan99 description Management ip address 192.0.2.12 255.255.255.0 ip directed-broadcast no ip proxy-arp!Why: Directed broadcast is on for Vlan99.
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 |
|---|---|
| NIST SP 800-53 | SC-7 |
| ISO/IEC 27001:2022 Annex A | A.8.20 |
Tested with: sample excerpts from IOS-XE 17.9 (synthetic). Minimum rConfig 8.0.2 (must_not_match_regex). Editions: Pro, Vector, Enterprise.
Related reference
- Cisco IOS policy templates: every rule in
ios-services.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.