From point A to point B
Point A: you can connect devices and route traffic, but your switches accept any MAC on any port, anyone can stand up a rogue DHCP server, your routers use Telnet with a weak password, and you could not explain what an IPsec VPN is in an interview. Point B: by the end you will speak the language of security (threat, vulnerability, exploit, mitigation), harden device access with passwords and SSH, centralize authentication with AAA, tell RADIUS from TACACS+, describe IPsec VPNs and configure the three layer 2 defenses the exam asks for: Port Security, DHCP Snooping and DAI.
This chapter covers seven topics of the Security Fundamentals domain (15% of the v1.1 exam): 5.1 (concepts), 5.2 (security program), 5.3 (local passwords), 5.4 (password policies), 5.5 (VPNs), 5.7 (layer 2 security) and 5.8 (AAA). ACLs (topic 5.6) were in chapter 9 and wireless security (5.9 and 5.10) in chapter 8.
- Concepts and the security program
- AAA, local passwords and SSH
- Password policies and IPsec VPNs
- Port Security, DHCP Snooping and DAI
- Verification and troubleshooting
Security concepts
All information security protects three properties, the CIA triad: confidentiality (only the right people see the data), integrity (no one alters it undetected) and availability (the service is there when needed). An attack tries to break at least one of the three.
The CIA triad and the four risk terms. Diagram: The House of Routing.
The exam carefully distinguishes four words people mix up:
- Threat: a potential danger to an asset; for example, an attacker or malware.
- Vulnerability: a weakness that danger could exploit; for example, unpatched software or a default password.
- Exploit: the concrete mechanism that takes advantage of the vulnerability.
- Mitigation: the countermeasure that reduces the risk; a patch, a firewall, an ACL, encryption.
The attacks most named in the CCNA: denial of service (DoS and DDoS, which target availability), spoofing (faking an IP, a MAC or a DHCP server), reconnaissance (prior scanning), man-in-the-middle (intercepting traffic, as in ARP poisoning) and social engineering (phishing, pretexting), which targets people, not machines.
The security program
Topic 5.2 reminds you that technology is not enough: most breaches start with a person. A security program has three elements the exam names explicitly:
- User awareness: short campaigns that keep the topic present; for example, simulated phishing emails so people learn to recognize them.
- Training: formal, assessed instruction, deeper than awareness, for those with specific responsibilities.
- Physical access control: badge doors, equipment cages, cameras and logs. The best firewall is useless if someone can walk off with a switch or plug a laptop into the rack.
Add the long-standing best practices: least privilege (everyone gets only what they need), defense in depth (several layers, not one) and having an incident response plan before anything happens.
AAA: RADIUS and TACACS+
Storing users and passwords on every device does not scale: a hundred admins means a hundred changes for one password. AAA centralizes three functions on a server:
The three A’s and the RADIUS / TACACS+ comparison. Diagram: The House of Routing.
- Authentication: who are you? It verifies the credentials.
- Authorization: what may you do? It decides which commands or resources you can reach.
- Accounting: what did you do? It logs actions for audit.
The network device (the NAS, network access server) does not decide: it forwards the request to the AAA server and acts on its reply. There are two protocols:
| RADIUS | TACACS+ | |
|---|---|---|
| Origin | Open standard (IETF) | Cisco proprietary |
| Transport | UDP 1812/1813 (formerly 1645/1646) | TCP 49 |
| Encryption | Only the password | The whole packet body |
| AAA | Joins authentication and authorization | Separates the three functions |
| Typical use | User network access (802.1X, Wi-Fi) | Device administration and command control |
Access with local passwords
Topic 5.3 asks you to configure and verify device access with local passwords. There are four entry points to protect:
The four access points and how to protect them. Diagram: The House of Routing.
! Name, local user and privileged-mode password
R1(config)# hostname R1
R1(config)# username admin privilege 15 secret S3cur3.2026
R1(config)# enable secret Enab1e.S3cr3t
! Console
R1(config)# line console 0
R1(config-line)# password C0ns0le.2026
R1(config-line)# login
R1(config-line)# exec-timeout 5 0
! VTY lines (remote access)
R1(config)# line vty 0 4
R1(config-line)# login local
R1(config-line)# exec-timeout 5 0
! Scramble the weak passwords in the file
R1(config)# service password-encryption
R1(config)# banner motd #Authorized access only#
- enable secret stores the privileged-mode password with a strong hash. Never use
enable password, which leaves it in clear text. - login local on the VTY lines requires the device’s username and password; plain
loginonly asks for the line password. - service password-encryption scrambles the weak (type 7) passwords in the configuration file. It is reversible and easy to break: it helps against a shoulder-surfer, not a real attacker. The
secretpasswords are already hashed and do not rely on this command. - exec-timeout closes idle sessions and the banner legally warns whoever connects.
Replacing Telnet with SSH
Telnet sends everything, passwords included, in clear text. SSH encrypts the session and is the only acceptable way to manage a device over the network. Configuring it has five requirements:
R1(config)# hostname R1
R1(config)# ip domain-name thor.local
R1(config)# username admin secret S3cur3.2026
R1(config)# crypto key generate rsa modulus 2048
R1(config)# ip ssh version 2
R1(config)# line vty 0 4
R1(config-line)# transport input ssh
R1(config-line)# login local
- A hostname other than the factory one and a domain name: together they form the certificate name.
- At least one local user with
secret(or AAA). - Generate the RSA key; with 2048 bits or more, IOS enables SSH automatically.
- Force SSHv2, which fixes flaws of v1.
- On the VTY lines, transport input ssh to reject Telnet and login local.
crypto key generate rsa will not accept the key, it is almost always because the hostname or the ip domain-name is missing: the device is still called “Router” and cannot name the certificate.Password policies and alternatives
Topic 5.4 asks not for commands but for the elements of a good password policy and its alternatives:
- Management: change them after an incident, do not reuse them across systems, keep them in a manager and never in clear text.
- Complexity and length: mix uppercase, lowercase, numbers and symbols, and above all make them long; length matters more than symbols.
- Multifactor authentication (MFA): combine something you know (a password), something you have (a token or the phone) and something you are (biometrics). Even if the password is stolen, the second factor is missing.
- Certificates: instead of a password, the device proves its identity with a digital certificate (the basis of EAP-TLS and of VPNs).
- Biometrics: fingerprint, face or iris as the “something you are” factor.
IPsec VPNs
Topic 5.5 asks you to describe remote-access and site-to-site IPsec VPNs. A VPN (virtual private network) builds an encrypted tunnel over a public network like the Internet, so that two endpoints communicate as if they were on the same private network.
Site-to-site versus remote access. Diagram: The House of Routing.
- Site-to-site VPN: joins two whole networks, for example two offices. The tunnel runs between the routers or firewalls of each site, is permanent and transparent: users install nothing. It almost always uses IPsec.
- Remote-access VPN: connects an individual user (teleworking) to the company network from anywhere. It usually uses a TLS/SSL client (such as Cisco AnyConnect) or IPsec; the tunnel comes up when the user connects.
IPsec is a suite of layer 3 protocols that gives the three guarantees: confidentiality (encrypts with AES), integrity and origin authentication (with an HMAC hash) and a secure key exchange (IKE, over UDP 500). It works in tunnel mode, encapsulating the original IP packet inside a new one.
Layer 2 security
An attacker rarely comes in through the edge router: they come in through a switch port on the floor. Because layer 2 lacks the defenses of layer 3, topic 5.7 asks for three mechanisms configured on the access switch that are best seen together, because they complement each other:
- Port Security controls which MACs can use each port.
- DHCP Snooping stops a rogue DHCP server and builds an IP-MAC-port table.
- DAI uses that table to stop ARP poisoning.
The next three sections take them one by one. The underlying idea is trust: you define which ports are trusted (those going to legitimate servers and to other switches) and treat everything coming in on a user port with suspicion.
Port Security
Port Security limits how many and which MAC addresses can use an access port. If a disallowed MAC arrives or the maximum is exceeded, the port reacts according to the violation mode.
The three violation modes. Diagram: The House of Routing.
SW1(config)# interface fastethernet 0/1
SW1(config-if)# switchport mode access
SW1(config-if)# switchport port-security
SW1(config-if)# switchport port-security maximum 2
SW1(config-if)# switchport port-security mac-address sticky
SW1(config-if)# switchport port-security violation restrict
SW1(config-if)# switchport port-security aging time 10
- The port must be in fixed access mode (
switchport mode access); Port Security does not work on a negotiating port or a trunk. - maximum sets how many MACs are allowed (default 1).
- mac-address sticky learns the MACs that connect and writes them into the configuration; you can also pin a static one with
mac-address H.H.H. - violation:
protectdrops silently;restrictdrops, logs and counts;shutdown(the default) leaves the port in err-disabled. - An err-disabled port recovers manually with
shutdownandno shutdown, or witherrdisable recovery cause psecure-violation.
DHCP Snooping
A rogue DHCP server can hand clients a default gateway that is the attacker’s device, and so intercept all traffic. DHCP Snooping stops it by classifying the ports:
Trusted and untrusted ports. Diagram: The House of Routing.
SW1(config)# ip dhcp snooping
SW1(config)# ip dhcp snooping vlan 10
! Port toward the legitimate DHCP server or another switch
SW1(config)# interface gigabitethernet0/1
SW1(config-if)# ip dhcp snooping trust
! User port: untrusted, with a request-rate limit
SW1(config)# interface fastethernet0/1
SW1(config-if)# ip dhcp snooping limit rate 10
- Ports start untrusted. You only mark as trust the ones leading to a legitimate DHCP server or to another switch.
- On an untrusted port, the switch drops server messages (DHCPOFFER, DHCPACK): a rogue DHCP on a user port is neutralized.
- The switch builds the DHCP Snooping binding table with, for each client, its IP, its MAC, the port and the VLAN. That table is the basis of DAI.
- limit rate on untrusted ports stops an exhaustion attack (many DHCP requests in a row).
Dynamic ARP Inspection (DAI)
ARP has no authentication: anyone can reply “that IP is me” and divert the traffic (ARP poisoning, the basis of a man-in-the-middle attack). DAI stops it by leaning on the DHCP Snooping table:
DAI validates each ARP against the binding table. Diagram: The House of Routing.
SW1(config)# ip dhcp snooping
SW1(config)# ip dhcp snooping vlan 10
SW1(config)# ip arp inspection vlan 10
! Ports toward switches and routers are trusted
SW1(config)# interface gigabitethernet0/1
SW1(config-if)# ip arp inspection trust
! Optional stricter validations
SW1(config)# ip arp inspection validate src-mac dst-mac ip
- On an untrusted port, DAI compares each ARP message with the binding table: if the IP-MAC pair matches, it lets it through; if not, it drops and logs it.
- That is why DAI needs DHCP Snooping active: without that table it has nothing to validate against. For devices with a static IP, ARP ACLs are used.
- Ports toward other switches and routers are marked trust, just as in DHCP Snooping.
Verification
SW1# show port-security
SW1# show port-security interface fastethernet 0/1
SW1# show port-security address
SW1# show ip dhcp snooping
SW1# show ip dhcp snooping binding
SW1# show ip arp inspection
SW1# show ip arp inspection interfaces
R1# show ip ssh
R1# show running-config | include enable secret
show port-security interface: the violation mode, the maximum, the learned MACs and the violation counter. If the port is Secure-shutdown, there was a violation in shutdown mode.show ip dhcp snooping binding: the IP-MAC-port-VLAN table; it is the one DAI uses.show ip arp inspection: the ARP packets forwarded and dropped per VLAN.show ip ssh: the active SSH version and the key status.
Troubleshooting
| Symptom | Likely cause | What to check |
|---|---|---|
| Port Security will not enable | The port negotiates or is a trunk | switchport mode access is missing |
| The port went down (err-disabled) | A violation in shutdown mode | shutdown / no shutdown or errdisable recovery |
| A new device will not connect on a secure port | Its MAC is not allowed or the maximum is exceeded | show port-security interface; clear the old MAC |
| Clients get no IP after enabling snooping | The port to the DHCP server was left untrusted | ip dhcp snooping trust is missing on that port |
| DAI drops ARP from static-IP devices | No binding in the DHCP Snooping table | Use an ARP ACL or mark the port as trust |
| crypto key generate rsa fails | Hostname or domain is missing | hostname and ip domain-name |
| Remote access still accepts Telnet | The VTY lines allow all transports | transport input ssh on the VTY lines |
For your notes. Lab 1 is a blank switch so you configure Port Security yourself; lab 2 comes with DHCP Snooping and DAI already applied, so you read the configuration and verify with the show commands. The password of the lab 2 switches is gj123.
What you take away
- CIA triad: confidentiality, integrity, availability. Threat (danger), vulnerability (weakness), exploit (how) and mitigation (countermeasure).
- The security program adds user awareness, training and physical access control to technology.
- AAA: authentication (who), authorization (what) and accounting (what you did), with a central server.
- RADIUS: open, UDP 1812/1813, encrypts only the password, for users. TACACS+: Cisco, TCP 49, encrypts everything, for device administration.
- enable secret (hashed), never enable password; login local on the VTY lines; service password-encryption only hides weak passwords.
- SSH needs hostname, ip domain-name, a user, an RSA key and SSHv2; transport input ssh disables Telnet.
- Policies: length and complexity; alternatives: MFA, certificates and biometrics.
- Site-to-site VPN (router to router, IPsec, permanent) versus remote access (user, TLS/SSL client). IPsec encrypts, provides integrity and uses IKE (UDP 500).
- Port Security: access ports only; sticky, maximum and the modes protect, restrict and shutdown (default, err-disabled).
- DHCP Snooping marks trusted ports, blocks rogue servers and builds the binding table; DAI uses that table to validate ARP.
In the next chapter you move on to IP services: NAT, NTP, DHCP, DNS, SNMP, syslog, QoS, SSH, TFTP/FTP and the first-hop redundancy protocols (FHRP).
Slides
These slides support the guided class: view them here, full screen, or download the PDF for your notes. Part 1 goes with videos 1 to 3 (concepts and secure access); Part 2, videos 4 to 6 (Port Security); Part 3, videos 7 to 11 (DHCP, DNS and DAI), and Part 4, the guided lab in video 12.
Class videos
The videos are in Spanish. The translation of the videos is in development.
Each part of the chapter has its own video. Tap a card and the video opens right here, over the page; use the Close button or the Esc key to go back to where you were. Use them alongside the slides of the same part.
- Chapter 10 · Part 1Security architecture fundamentalsWatch video
- Chapter 10 · Part 2Secure access fundamentals (AAA)Watch video
- Chapter 10 · Part 3Secure access configurationWatch video
- Chapter 10 · Part 4Port Security fundamentalsWatch video
- Chapter 10 · Part 5Configuring Port Security IWatch video
- Chapter 10 · Part 6Configuring Port Security IIWatch video
- Chapter 10 · Part 7DHCP and DNS IWatch video
- Chapter 10 · Part 8DHCP and DNS IIWatch video
- Chapter 10 · Part 9Configuring DHCP and DNS IWatch video
- Chapter 10 · Part 10Configuring DHCP and DNS IIWatch video
- Chapter 10 · Part 11DAI fundamentalsWatch video
- Chapter 10 · Part 12Lab: DAI configurationWatch video
When you play a video, it loads from YouTube (no cookies until you open it). See the full playlist on YouTube.
Packet Tracer labs
The labs are in Spanish. The translation of the labs is in development.
Download each lab's files and open them with Cisco Packet Tracer. Tap the name to see the two downloads.
Lab 1Configuring Port Security on a switch
A small network (192.168.1.0/24) with three switches, a router, several PCs and a server. The PC MACs are given. You configure Port Security on the access ports: put the port in access mode, enable port-security, set the maximum, learn the MAC with sticky and choose the violation mode. Then you check with show port-security interface what happens when you connect a device with a different MAC. The topology carries no personal data and uses generic example MACs.
Lab 2DHCP Snooping and DAI on layer 2
A switch (SW-IPDS-01) with three PCs, a DHCP server and VLANs 10, 100 and 200. It already has DHCP Snooping and DAI applied on VLAN 10, with the ports to the server and the trunks marked trusted, Port Security with sticky on the access ports and SSH for management. Your task is to read the configuration, understand why each port is or is not trusted and verify with show ip dhcp snooping binding and show ip arp inspection. Console and enable password: gj123.
Chapter assessment
There are 100 single-choice questions, split into 10 tabs of 10. Each tab mixes every topic in the chapter and rises in level: questions 1 to 3 are low difficulty, 4 to 8 are medium and 9 to 10 are high.
We do not save your answers. They run in your browser and, if you close or reload the page, you start from zero. Getting it wrong here is the cheapest way to learn.
Additional resources
These links take you to official sites outside this portal. Use them to practice, go further and confirm what you learned.
To study and practice
- Cisco U.: Implementing and Administering Cisco Solutions (CCNA) pathu.cisco.com
- Cisco Learning Network: community, forums and study resourceslearningnetwork.cisco.com
- Cisco Packet Tracer at Networking Academynetacad.com
Exam and certification
- Official CCNA 200-301 v1.1 exam topics (PDF)learningcontent.cisco.com
- Official CCNA certification pagecisco.com
Reference documentation
- Cisco: configuring Port Security on Catalystcisco.com
- Cisco: DHCP Snooping and DAIcisco.com
- RFC 2865: RADIUSrfc-editor.org
Source and credits. Chapter built from the security slide decks and mentoring sessions (security fundamentals, secure access and AAA, Port Security, DHCP Snooping and DAI) and the Port Security theory of Jesús Espinoza’s CCNA 200-301 course, paraphrased, updated and aligned with the official CCNA 200-301 v1.1 exam topics. Text written with AI assistance; original diagrams by The House of Routing. Technical data was checked against official Cisco documentation and the RADIUS (2865), TACACS+ (8907) and IPsec RFCs.
