一,

二,MAC地址绑定

3550-1#conf t
3550-1(config)#int f0/1
3550-1(config-if)#switchport mode access /指定端口模式。
3550-1(config-if)#switchport port-security mac-address 0090.F510.79C1 /配置MAC地址。
3550-1(config-if)#switchport port-security maximum 1 /限制此端口允许通过的MAC地址数为1。
3550-1(config-if)#switchport port-security violation shutdown(protect(不转发不报警)/restrict(不转发报警)) /当发现与上述配置不符时,端口down或者拒绝收发。

三.MAC地址过滤

3550-1(config)#mac-address-table static 0090.F510.79C1 vlan 2 drop /在相应的Vlan丢弃流量。

3550-1(config)#mac-address-table static 0090.F510.79C1 vlan 2 int f0/1 /在相应的接口丢弃流量。


四.清除安全的MAC地址

Switch(config-if)#switchport port-security maximum 1

Maximum is less than number of currently secured mac-addresses.//报错

可以清除

Switch#clear port-security ?

all Clear all secure MAC addresses

configured Clear all configured secure MAC addresses

dynamic Clear all secure MAC address auto-learned by hardware

sticky Clear all secure MAC address either auto-learned or configured

清除mac-address-table

clear mac-address-table dynamic

Switch#show mac-address-table

Mac Address Table

-------------------------------------------

Vlan Mac Address Type Ports

---- ----------- -------- -----

1 0001.42dd.8aee DYNAMIC Fa0/3

1 0050.0f99.ce16 DYNAMIC Fa0/2

1 0060.3e47.29da STATIC Fa0/1

五.查看安全保护的MAC地址

Switch#show port-security int f0/1

Port Security : Enabled

Port Status : Secure-up

Violation Mode : Protect

Aging Time : 0 mins  (0表示禁止老化)

Aging Type : Absolute(absolute:从上一次学习到算起,inactivity:从上一次收到来自该mac地址的包算起)

SecureStatic Address Aging : Disabled

Maximum MAC Addresses : 1

Total MAC Addresses : 1

Configured MAC Addresses : 0

Sticky MAC Addresses : 1

Last Source Address:Vlan : 00D0.BAD0.4703:1

Security Violation Count : 0

Switch# show port-security address

Secure Mac Address Table

-------------------------------------------------------------------------------

Vlan Mac Address Type Ports Remaining Age

(mins)

---- ----------- ---- ----- -------------

1 0060.3E47.29DA SecureSticky FastEthernet0/1 -

------------------------------------------------------------------------------

Total Addresses in System (excluding one mac per port) : 0

Max Addresses limit in System (excluding one mac per port) : 102

CCNA实验1.port-security的更多相关文章

  1. Packet Tracer 5.0 构建CCNA实验(2)—— 配置VLAN

    Packet Tracer 5.0 构建CCNA实验(2)—— 配置VLAN Vlan(Virtual Local Area Network) 即虚拟局域网.VLAN可以把同一个物理网络划分为多个逻辑 ...

  2. CCNA实验4:HDLC和PPP

    一.HDLC封装 router9和11上分别配置s0/0如下 conf t int s0/0 encapsulation hdlc do show int s0/0 ip address x.x.x. ...

  3. CCNA实验2.VLAN

    一. 二.配置主VTP上的信息 sw2上配置为domain server,sw1上配置为domain client,sw2上增加vlan并命名和添加描述 conf t vtp domain corp ...

  4. CCNA实验(1) -- 基本配置

    Ctrl+A: 到行首(Ahead)Ctrl+E: 到行尾(End)Esc+B: 回退一个单词(Back)Esc+F: 前进一个单词(Forward) 1.三种配置模式2.时间时区配置3.设置超时时间 ...

  5. CCNA实验(2) -- Static Route

    1.静态路由R1:ip route 22.1.1.0 255.255.255.0 12.1.1.2 2.静态汇总路由R1:ip route 22.1.0.0 255.255.0.0 12.1.1.2 ...

  6. CCNA实验(5) -- OSPF

    enableconf tno ip do loenable pass ciscoline con 0logg syncexec-t 0 0line vty 0 4pass ciscologg sync ...

  7. CCNA实验(4) -- EIGRP

    enableconf tno ip do loenable pass ciscoline con 0logg syncexec-t 0 0line vty 0 4pass ciscologg sync ...

  8. CCNA实验(3) -- RIP

    RIP协议分为版本1和版本2,均具备以下特征:1.是距离向量路由协议2.使用跳数(Hop Count)作为度量值3.默认路由更新周期为30秒4.管理距离(AD)为1205.支持触发更新6.最大跳数为1 ...

  9. CCNA实验(10) -- Access List

    使用包过滤技术在路由器上读取三层及四层报头的信息如源地址.目的地址.源端口.目的端口根据预先定义好的规则对包进行过滤 三种类型:1.标准ACL:表号范围1-99或1300-1999.仅对源IP地址进行 ...

随机推荐

  1. pushlet实现服务器端向客户端推送信息

    使用Pushlet来实现服务器端向客户端推送信息 1.   实现方式: 有两种实现方式: 1.         通过配置文件来实现定时的从服务器端向客户端推送信息 2.         通过API主动 ...

  2. <input type="file" />浏览时只显示指定文件类型

    <input type="file" />浏览时只显示指定文件类型 <input type="file" accept="appli ...

  3. C# 特殊处理使用方法

    1.时间处理 Model.PiDaiTime.ToString("yyyyMMdd") == "00010101" ? DateTime.Now.ToStrin ...

  4. js学习-DOM之动态创建元素的三种方式、插入元素、onkeydown与onkeyup两个事件整理

    动态创建元素的三种方式: 第一种: Document.write(); <body> <input type="button" id="btn" ...

  5. 01:Geoserver发布shapfile,中文字段乱码问题

    软件环境:Geoserver 2.1.0 UDig 1.2.1 shapfile文件结构:FID                  地物名称      变化图斑                     ...

  6. 让HTML5语义化标签兼容IE浏览器

    解决方案:IE9以下旧版本浏览器不支持新的语义化标签.其中一种解决方案就是用js将HTML5增加的标签创建出来,就像下面这样.(放在header部位) <script> var html5 ...

  7. Ubuntu14.04-PXE装机笔记

    什么是PXE? PXE(Pre-boot Execution Environment,预启动执行环境)是由Intel公司开发的最新技术,工作于Client/Server的网络模式,支持工作站通过网络从 ...

  8. 【DLL测试】为DLL项目建立测试

    本文将创建一个简单的动态链接库,并编写一个控制台应用程序使用该动态链接库,该动态链接库为“JAVA调用动态链接库DLL之JNative学习”中使用的DLL, 只是项目及文件名称不同. 创建动态链接库项 ...

  9. java基础-jdbc——三种方式加载驱动建立连接

    String url = "jdbc:mysql://localhost:3306/student?Unicode=true&characterEncoding=utf-8" ...

  10. elixir 高可用系列(五) Supervisor

    概述 OTP 平台的容错性高,是因为它提供了机制来监控所有 processes 的状态,如果有进程出现异常, 不仅可以及时检测到错误,还可以对 processes 进行重启等操作. 有了 superv ...