| 场景 | 接入端口防 VLAN 跳跃 |
|---|---|
| 适用 | 三厂(思科 DTP 是主要风险点) |
| 要点 | 固定 access 模式、关闭 DTP、Trunk 口限制允许 VLAN、原生 VLAN 不承载业务 |
思科 IOS
思科 IOS
interface GigabitEthernet0/1
switchport mode access
switchport nonegotiate # 关闭 DTP 协商
switchport access vlan 10
!
interface GigabitEthernet0/24
switchport trunk native vlan 999 # 原生 VLAN 不用业务 VLAN华为 VRP
华为 VRP
interface GigabitEthernet0/0/1
port link-type access
port default vlan 10
display port vlanH3C Comware
H3C Comware
interface GigabitEthernet1/0/1
port link-type access
port access vlan 10
display vlan差异:华为 VRP 与 H3C Comware 不支持 DTP 自动协商,端口类型必须显式指定,天然免疫 DTP 方向的风险;思科务必配 switchport nonegotiate 并用 switchport trunk allowed vlan 限定 Trunk。