Cisco IOS Security Hardening
CIS Benchmark and NSA/NIST-aligned security hardening checklist for Cisco IOS/IOS-XE. Covers AAA, SSH, login protection, management plane, and service hardening.
What is it?
Security hardening is the process of reducing a device's attack surface by disabling unnecessary services, enforcing strong authentication, and restricting management access. A factory-default Cisco IOS router has many insecure defaults: Telnet enabled, HTTP server running, CDP broadcasting hardware info, no brute-force protection. Hardening aligns the device with frameworks like CIS Benchmarks (Center for Internet Security) and NSA/NIST guidelines. The goal is that every management action is authenticated, logged, and restricted to authorized sources.
When to use
- ·Before deploying any network device to production — hardening is not optional
- ·After a security audit finds misconfigured or default settings
- ·For compliance with PCI-DSS (requirement 2: no vendor defaults), HIPAA, SOC 2, or ISO 27001
- ·When adding new devices to an existing network — match the security baseline
When NOT to use
- ·In a lab/test environment where rapid changes are needed — strict exec timeouts and login block-for can slow troubleshooting. Keep separate lab and production templates.
- ·Disabling CDP on all interfaces blindly — CDP is often needed for IP phone voice VLAN discovery. Be selective: 'no cdp enable' per interface rather than 'no cdp run' globally.
How it compares
Prerequisites
- →Active AAA server (TACACS+ or RADIUS) for centralized authentication, or local user database as fallback
- →Management ACL defined with your actual management source IPs — applying a management ACL with wrong IPs will lock you out
- →NTP configured before applying hardening — login logs need accurate timestamps
- →Test console access verified before applying VTY access restrictions
Config Generator
Verification commands
show ip sshVerify SSH version 2 is running and RSA key is generated
ExpectedSSH Enabled - version 2.0. Authentication timeout and retries should match policy.
show aaa sessionsShow active AAA sessions and authentication statistics
ExpectedLists active management sessions with username, IP, and time. Shows failed auth attempts.
show loginShow login block-for status and failed login tracking
ExpectedShows current block status, number of failed attempts, and quiet mode status
show running-config | include no ip|no service|no cdpVerify hardening commands are in the running config
ExpectedShould show all disabled services: no ip http server, no cdp run, no ip source-route, etc.
Debug commands
show tcp briefShow all open TCP connections to and from the router
Common mistakes & fixes
Further learning
Recommended books to go deeper on this topic.
Network Security Architectures
Sean Convery · Cisco Press · Defense-in-depth, CoPP, control plane hardening, AAA design
CCNP Enterprise Core ENCOR 350-401 Official Cert Guide
Brad Edgeworth et al. · Cisco Press · AAA, RADIUS, TACACS+, device hardening best practices