Concepts / Network attacks

Network attacks

VLAN hopping

Also called double tagging, 802.1Q double-tagging, vlan jumping

Escaping the VLAN your port is assigned to and reaching another one — classically by wrapping a frame in two 802.1Q tags so the first switch strips the outer and forwards the inner into a VLAN you were never meant to touch.

Two tags, one stripped by each switch
Two tags, one stripped by each switch

The first switch removes the outer tag because the native VLAN crosses the trunk untagged. The second switch then obeys the inner tag. Nothing can come back the same way.

VLAN hopping is sending frames into a [[vlan|VLAN]] your port is not in. In double tagging, an attacker on a [[trunk|trunk]]'s native VLAN sends a frame with two 802.1Q tags. The first switch removes the outer tag, because the native VLAN crosses the trunk untagged; the second switch reads the inner tag and delivers it into the target VLAN. It is one-way: no reply returns. Fix: an unused native VLAN.

See it on real machines

Read next

Learn it on real machines.

Every lab is a small network of real Linux machines in your browser. Sign in with Google or email to start.

Start this lab