Pcornel
Browse topics
Options
Recent
Favorites
Networking · Technical reference

Layer 2 Encryption

Direct answer

MACsec (IEEE 802.1AE) encrypts Ethernet frames hop by hop on a link, using AES-GCM with keys negotiated by MKA, so traffic on the wire cannot be read.

When to use this

Use it when links between switches or to hosts must be encrypted at Layer 2.

First 30 seconds

1. MACsec encrypts at Layer 2 with GCM-AES.

2. Each hop decrypts and re-encrypts.

3. Protects against taps.

4. Choose cipher suite.

5. Check both ends match.

Operational verification

frame → GCM-AES encrypt → link → decrypt

Context & applicabilityCommon mistakes · platform/version boundaries
Common mistakes
MACsec pitfalls
  • Mismatched cipher suites or CAK/CKN between peers (MKA never secures).
  • MTU not increased for the 32-byte overhead.
  • Intermediate devices (media converters, some optical transport) that do not pass EAPoL/MACsec frames.
  • macsec configured but should-secure fallback silently allowing clear traffic — use must-secure where policy requires.
Platform / version applicability
Cisco IOS / IOS XE
applies
Structured applicability is explicit Topic metadata; it does not infer compatibility beyond the stored rows.
At a glance

Operational reference

Fast context before you go deeper.

PlatformCisco IOS / IOS XE
Scope / prerequisiteUse it when links between switches or to hosts must be encrypted at Layer 2.
What next?3 suggested next steps
Evidence1
On this pageJump to a specific section
Operational workflow

Verification & Troubleshooting

Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.

1 steps Observe → verify → isolate → change minimally → repeat the original test.
ObservedRecord what the original test actually shows

Capture the concrete output, symptom, packet, log or counter before changing anything.

Step 1 Verification & troubleshooting Narrow the fault

1. Verify link and peer identity/key policy.

2. Inspect MKA session and live peers.

3. Inspect secure channel/association state.

4. Compare encrypted, validated and dropped counters.

5. Test rekey, failover, MTU and application traffic.

Evidence references

Evidence · 1 on this Topic

Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.

observation · 1
Command lookup Jump straight to Cisco syntax
Key points
  • Each hop/link is protected separately; MACsec is not end-to-end across ordinary transit devices
  • MKA establishes secure channels and associations
  • Cipher suite, policy, key/identity and replay settings must agree
  • Overhead affects effective frame size and platform capacity.
Key checks
  • show macsec interface <interface> — cipher (GCM-AES-128/256)
  • show mka sessions detail — keys
ReferenceWhy it matters1 section · depth on demand

When to use it

Use it to protect frames on a supported point-to-point link while keeping routing and higher-layer policy independent.

ReferenceImportant terms & boundaries2 sections · depth on demand

How it works

MACsec (802.1AE) encrypts and authenticates Ethernet frames hop by hop between two directly connected ports, using AES-GCM. Keys come from MKA (MACsec Key Agreement) with a pre-shared CAK or from 802.1X. It protects links against tapping, including between switches and from switch to host.

In depth

Switch-to-switch MKA with a pre-shared key (Catalyst 9000)

key chain MKA-KC macsec
 key 01
  cryptographic-algorithm aes-256-cmac
  key-string <64 hex characters>
  lifetime local 00:00:00 Jan 1 2026 infinite
!
mka policy MKA-POL
 key-server priority 200
 macsec-cipher-suite gcm-aes-256
 confidentiality-offset 0
!
interface TenGigabitEthernet1/1/1
 macsec network-link
 mka policy MKA-POL
 mka pre-shared-key key-chain MKA-KC

The key name (CKN, here 01) and the key string (CAK) must match on both ends. Key-chain lifetimes depend on the clock, so NTP must be correct before relying on scheduled key rollover.

Reading the session

Switch# show mka sessions interface TenGigabitEthernet1/1/1
Interface      Local-TxSCI         Policy-Name      Inherited         Key-Server
Port-ID        Peer-RxSCI          MACsec-Peers     Status            CKN
Te1/1/1        00a3.d1c0.ff81/0012 MKA-POL          NO                YES
18             00a3.d1c0.ee81/0012 1                Secured           01
StatusMeaning
SecuredSAKs installed, traffic encrypted
Init / PendingMKA running but no agreement — CKN/CAK or cipher mismatch, or platform key-padding differences
No sessionMKA not enabled or EAPOL not reaching the peer

show macsec interface Te1/1/1 shows the cipher, secure channels and encrypted/validated packet counters; show mka sessions ... detail shows live and potential peers.

MTU and transport

The MACsec header adds up to 32 bytes (SecTAG plus ICV). Raise the MTU on the link and on any switch in a path that carries MACsec-protected jumbo traffic. Devices in between that are not MACsec-aware must pass EAPOL (EtherType 0x888E) untouched — some media converters and carrier services drop it, and MKA then never comes up.

Operational choices

  • Prefer MKA over Cisco SAP on modern links; the Cisco guide notes SAP limits at higher speeds.
  • Use should-secure style policies only during migration; must-secure behaviour is the real protection.
  • Monitor for Secured state in telemetry — an unencrypted fallback is silent otherwise.

Documented example, not captured output.

Source basisSource attribution states what this section is based on; it is not independent proof that the current environment matches it.
ReferenceConfiguration & state1 section · depth on demand

Configuration (switch-to-switch, MKA)

key chain MKA-KC macsec
 key 01
  cryptographic-algorithm aes-256-cmac
  key-string <64-hex-chars>
mka policy MKA-POL
 macsec-cipher-suite gcm-aes-256
interface TenGigabitEthernet1/1/1
 macsec network-link
 mka policy MKA-POL
 mka pre-shared-key key-chain MKA-KC

Documented example, not captured output. Check with show mka sessions (Secured) and show macsec summary.

Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Technical verification history

Verification history & basis

When and against what this Topic was checked. Later text edits do not count as a new check.

2026-09-14 · vendor docCisco IOS / IOS XE Current documentation reviewed 2026-09-14

Authoritative/upstream documentation reviewed for bounded claims in Security → MACsec → Layer 2 Encryption. Documentation verification only; this is not observed lab or production Evidence.

Basis: https://www.cisco.com/c/en/us/support/ios-nx-os-software/ios-xe-17/series.html · confidence 94%
Confirmation

Confirm action

Continue?