VTY ACL
Cheat sheet · https://pcornel.dk/topic.php?topic=763
Answer
A VTY ACL restricts who may open SSH or Telnet sessions to the device: a standard ACL applied with access-class <name> in under line vty.
Remember
Apply it to all VTY lines (line vty 0 15 on most switches, 0 4 on older routers) or some lines stay open. Add the management host before applying, or you lock yourself out. access-class filters on source address; ip access-group would not work on a line.
First checks
show line vty 0 15 | include Access— inbound ACL per line.show access-lists <name>— permit and deny counters.show running-config | section line vty— access-class on every line range.show users— current sessions and where they come from.
Commands
access-class <acl> in- Apply an ACL to VTY lines to restrict which source addresses may open management sessions.
ip http access-classshow access-lists 10
Verify in this order
ACL applied on the right interface and direction → packet compared top-down → first matching entry decides → no match = implicit deny → counter increments on the matching entry
Where it usually breaks
local configuration → reachability/transport → request/negotiation → server or policy decision → response/state installation → client-visible result
VTY ACL · technical reference
| Layer | VTY management role |
|---|---|
| Access-class | Source-address restriction |
| Transport input | SSH/Telnet protocol choice |
| AAA | Identity and privilege |
| Routing/VRF | Reachability to management plane |
Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=763