NETWORKING · CCNA V1.1 · CHAPTER 10

Security services

The fastest network is worthless if it is not secure. Learn the vocabulary of risk, harden access to your devices, centralize authentication with AAA and shield layer 2 against the most common attacks.

55 min read · 3 sessionsDomain 5 · Security FundamentalsLevel: intermediateAGLE method · A, G, L, E
AGLE methodSelf-studyAll the chapter text, at your own pace.

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.

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 vocabulary of riskInformation security protects three properties: confidentiality, integrity and availability (the CIA triad). The exam also distinguishes four terms: a threat is a potential danger; a vulnerability, a weakness; an exploit, the way to take advantage of it; and mitigation, what you do to reduce risk.CONFIDENTIALITY · INTEGRITY · AVAILABILITYConfidentialityOnly the right people seedata (encryption, access control)IntegrityData is not altered (hashing,signatures)AvailabilityThe service is available (redundancy,anti-DoS)Term · What it is · ExampleThreatPotential dangerAn attackerVulnerabilityExploitable weaknessUnpatched softwareExploitHow it is usedMalware that uses the flawMitigationWhat reduces the riskPatch, firewall, ACL

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:

AAA: authentication, authorization and accountingAAA splits three questions: who are you? (authentication), what may you do? (authorization) and what did you do? (accounting). A central server (RADIUS or TACACS+) answers for every device, instead of storing users on each one.A CENTRAL SERVER DECIDES FOR THE WHOLE NETWORKUserNetwork deviceAAA serverEAPOL / loginRADIUS / TACACS+AuthenticationWho are you?AuthorizationWhat may you do?AccountingWhat did you do?RADIUS · TACACS+StandardOpen (IETF)CiscoTransportUDP 1812/1813TCP 49EncryptsOnly the passwordThe whole packetSplits AAANo (authn+authz joined)YesTypical useUser access (802.1X)Device administration

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:

RADIUSTACACS+
OriginOpen standard (IETF)Cisco proprietary
TransportUDP 1812/1813 (formerly 1645/1646)TCP 49
EncryptionOnly the passwordThe whole packet body
AAAJoins authentication and authorizationSeparates the three functions
Typical useUser network access (802.1X, Wi-Fi)Device administration and command control
Exam tip. Two shortcuts: TACACS+ is Cisco, uses TCP 49 and encrypts the whole packet, so it is ideal for device administration. RADIUS is open, uses UDP and encrypts only the password, so it is the usual choice for 802.1X and end-user access. The local method (users on the device itself) is the fallback if the AAA server does not answer.

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:

Hardening device accessThe exam asks you to protect access with local passwords and good practice. The console and VTY lines require a password; privileged mode uses enable secret (encrypted), never enable password. SSH replaces Telnet, and a strong password policy or a second factor reinforce everything.LOCAL PASSWORDS · SSH · STRONG POLICYConsoleline console 0 · password · loginVTY lines (SSH)transport input ssh · login localPrivileged modeenable secret (not enable password)Policy and alternativesLength and complexity · MFA · certificates · biometricsservice password-encryption scrambles the weak passwords in the configuration file

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 login only 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 secret passwords 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
  1. A hostname other than the factory one and a domain name: together they form the certificate name.
  2. At least one local user with secret (or AAA).
  3. Generate the RSA key; with 2048 bits or more, IOS enables SSH automatically.
  4. Force SSHv2, which fixes flaws of v1.
  5. On the VTY lines, transport input ssh to reject Telnet and login local.
Exam tip. If you are asked why 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.

VPN: site-to-site and remote accessA VPN builds an encrypted tunnel over a public network. The site-to-site VPN joins two networks with IPsec between their routers or firewalls, permanently and transparently to users. The remote-access VPN connects an individual user, usually with a TLS/SSL client, from anywhere.SITE-TO-SITE (IPSEC) · REMOTE ACCESS (TLS/SSL)InternetSite-to-siteSite ASite BPermanent IPsec tunnelRemote accessRemote userHeadquartersClient TLS/SSL tunnel

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.

Port Security: violation modesPort Security limits which MAC addresses can use an access port of the switch. The MAC is learned statically, dynamically or sticky (which saves it in the configuration). If a disallowed MAC arrives or the maximum is exceeded, the port reacts according to the violation mode.ACCESS PORTS ONLY · THREE VIOLATION MODESModeDropsLogsCounterPort stateprotectYesNoNoUprestrictYesYesYesUpshutdown (default)YesYesYeserr-disabled (down)sticky learns the MAC and writes it into the configuration; maximum sets how many are allowed; err-disabled recovers with shutdown then no shutdown

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: protect drops silently; restrict drops, logs and counts; shutdown (the default) leaves the port in err-disabled.
  • An err-disabled port recovers manually with shutdown and no shutdown, or with errdisable 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:

DHCP Snooping: trusted portsDHCP Snooping protects against rogue DHCP servers. Ports toward legitimate DHCP servers and toward the network are marked trusted; the rest, untrusted. On an untrusted port the switch drops server messages (OFFER, ACK) and builds a table of IP-MAC-port bindings.A ROGUE DHCP ONLY FOOLS FROM AN UNTRUSTED PORTSwitch with DHCP SnoopingDHCP serverTrustedClientUntrustedRogue DHCPDrops the rogue OFFER/ACKDHCP binding table (IP · MAC · port · VLAN)

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: dynamic ARP inspectionDAI uses the DHCP Snooping binding table to validate ARP messages. On an untrusted port the switch compares each ARP with the table: if the IP-MAC pair matches, it lets it through; if not, it drops it. This stops ARP poisoning and man-in-the-middle attacks.DAI NEEDS THE DHCP SNOOPING TABLESwitch with DAIClientValid ARP: IP-MAC is in the table → passesAttacker (fake ARP)Fake ARP: no match → droppedDHCP binding tableIP · MAC · puerto

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

SymptomLikely causeWhat to check
Port Security will not enableThe port negotiates or is a trunkswitchport mode access is missing
The port went down (err-disabled)A violation in shutdown modeshutdown / no shutdown or errdisable recovery
A new device will not connect on a secure portIts MAC is not allowed or the maximum is exceededshow port-security interface; clear the old MAC
Clients get no IP after enabling snoopingThe port to the DHCP server was left untrustedip dhcp snooping trust is missing on that port
DAI drops ARP from static-IP devicesNo binding in the DHCP Snooping tableUse an ARP ACL or mark the port as trust
crypto key generate rsa failsHostname or domain is missinghostname and ip domain-name
Remote access still accepts TelnetThe VTY lines allow all transportstransport 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).

AGLE methodInstructor-guidedThe class slides and videos.

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.

When you play a video, it loads from YouTube (no cookies until you open it). See the full playlist on YouTube.

AGLE methodLabsHands-on practice in Packet Tracer.

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.

AGLE methodContinuous assessmentExam-style questions to measure your progress.

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

Exam and certification

Reference documentation

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.

Navigate