本文档讨论使用IPS Manager Express(IME)配置入侵防御系统(IPS)阻止。IME和IPS传感器用于管理Cisco路由器以阻止。考虑此配置时,请记住以下项目:
安装传感器并确保传感器工作正常。
使嗅探接口跨度到接口外部的路由器。
本文档没有任何特定的要求。
本文档中的信息基于以下软件和硬件版本:
思科IPS管理器Express 7.0
思科IPS传感器7.0(0.88)E3
带Cisco IOS软件版本12.4的Cisco IOS®路由器
本文档中的信息都是基于特定实验室环境中的设备编写的。本文档中使用的所有设备最初均采用原始(默认)配置。如果您使用的是真实网络,请确保您已经了解所有命令的潜在影响。
有关文档约定的更多信息,请参考 Cisco 技术提示约定。
本文档使用此网络设置。
本文档使用以下配置。
路由器灯 |
---|
Current configuration : 906 bytes ! version 12.4 service timestamps debug uptime service timestamps log uptime no service password-encryption ! hostname light ! enable password cisco ! username cisco password 0 cisco ip subnet-zero ! ! ! ip ssh time-out 120 ip ssh authentication-retries 3 ! call rsvp-sync ! ! ! fax interface-type modem mta receive maximum-recipients 0 ! controller E1 2/0 ! ! ! interface FastEthernet0/0 ip address 10.100.100.2 255.255.255.0 duplex auto speed auto ! interface FastEthernet0/1 ip address 1.1.1.1 255.255.255.0 duplex auto speed auto ! interface BRI4/0 no ip address shutdown interface BRI4/1 no ip address shutdown ! interface BRI4/2 no ip address shutdown ! interface BRI4/3 no ip address shutdown ! ip classless ip route 0.0.0.0 0.0.0.0 10.100.100.1 ip http server ip pim bidir-enable ! ! dial-peer cor custom ! ! line con 0 line 97 108 line aux 0 line vty 0 4 login ! end |
路由器 House |
---|
Current configuration : 939 bytes ! version 12.4 service timestamps debug uptime service timestamps log uptime no service password-encryption ! hostname house ! logging queue-limit 100 enable password cisco ! ip subnet-zero ! ! no ip cef no ip domain lookup ! ip audit notify log ip audit po max-events 100 ! ! no voice hpi capture buffer no voice hpi capture destination ! ! ! ! interface FastEthernet0/0 ip address 10.66.79.210 255.255.255.224 duplex auto speed auto ! interface FastEthernet0/1 ip address 10.100.100.1 255.255.255.0 ip access-group IDS_FastEthernet0/1_in_0 in !--- After you configure blocking, !--- IDS Sensor inserts this line. duplex auto speed auto ! interface ATM1/0 no ip address shutdown no atm ilmi-keepalive ! ip classless ip route 0.0.0.0 0.0.0.0 10.66.79.193 ip route 1.1.1.0 255.255.255.0 10.100.100.2 no ip http server no ip http secure-server ! ! ip access-list extended IDS_FastEthernet0/1_in_0 permit ip host 10.66.79.195 any permit ip any any !--- After you configure blocking, !--- IDS Sensor inserts this line. ! call rsvp-sync ! ! mgcp profile default ! ! line con 0 exec-timeout 0 0 line aux 0 line vty 0 4 exec-timeout 0 0 password cisco login line vty 5 15 login ! ! end |
完成以下步骤以开始配置传感器。
如果这是您第一次登录传感器,您必须在用户名和密码栏输入cisco。
系统提示时,请更改密码。
注意:Cisco123是字典词,系统中不允许使用。
键入setup并按照系统提示设置传感器的基本参数。
输入此信息:
sensor5#setup --- System Configuration Dialog --- !--- At any point you may enter a question mark '?' for help. !--- Use ctrl-c to abort the configuration dialog at any prompt. !--- Default settings are in square brackets '[]'. Current time: Thu Oct 22 21:19:51 2009 Setup Configuration last modified: Enter host name[sensor]: Enter IP interface[10.66.79.195/24,10.66.79.193]: Modify current access list?[no]: Current access list entries: !--- permit the ip address of workstation or network with IME Permit:10.66.79.0/24 Permit: Modify system clock settings?[no]: Modify summer time settings?[no]: Use USA SummerTime Defaults?[yes]: Recurring, Date or Disable?[Recurring]: Start Month[march]: Start Week[second]: Start Day[sunday]: Start Time[02:00:00]: End Month[november]: End Week[first]: End Day[sunday]: End Time[02:00:00]: DST Zone[]: Offset[60]: Modify system timezone?[no]: Timezone[UTC]: UTC Offset[0]: Use NTP?[no]: yes NTP Server IP Address[]: Use NTP Authentication?[no]: yes NTP Key ID[]: 1 NTP Key Value[]: 8675309
保存配置。
传感器保存配置可能需要几分钟时间。
[0] Go to the command prompt without saving this config. [1] Return back to the setup without saving this config. [2] Save this configuration and exit setup. Enter your selection[2]: 2
完成以下步骤,将传感器添加到IME。
转到安装了IPS Manager Express的Windows PC,然后打开IPS Manager Express。
选择“主页”>“添加”。
键入此信息并单击OK以完成配置。
选择Devices > sensor5以验证传感器状态,然后右键单击选择Status。
确保您能看到订阅已成功打开。邮件.
要配置Cisco IOS路由的阻塞,请完成以下步骤:
从IME PC打开Web浏览器,然后转到https://10.66.79.195。
单击OK以接受从传感器下载的HTTPS证书。
在Login窗口中输入用户名cisco和密码123cisco123。
此IME管理界面显示:
在“配置”选项卡中,单击“活动签名”。
然后,单击“签名向导”。
注意:由于空间限制,上一屏幕截图已被切分成两部分。
选择Yes和String TCP作为签名引擎。单击 Next。
您可以将此信息保留为“默认”,或输入您自己的“签名ID”、“签名名称”和“用户注释”。单击 Next。
选择Event Action,然后选择Produce Alert和Request Block Host。单击 Next 继续操作。
输入正则表达式(在本例中为testattack),输入23(服务端口),选择To Service(方向),然后单击Next以继续。
您可以将此信息保留为默认值。单击 Next。
单击Finish以完成向导。
选择Configuration > sig0 > Active Signatures,以便通过Sig ID或Sig Name找到新创建的签名。单击Edit以查看签名。
确认后,单击“OK(确定)” ,然后单击“Apply(应用)”按钮,将签名应用于传感器。
在Configuration(配置)选项卡的Sensor Management(传感器管理)下,单击Blocking(阻止)。从左窗格中,选择Blocking Properties并选中Enable Blocking。
现在从左窗格转到Device Login Profile。要创建新配置文件,请单击“添加”。创建后,单击OK并Apply以便传感器并继续。
下一步是将路由器配置为阻塞设备。从左窗格中,选择阻止设备,单击添加以添加此信息。然后单击“确定”并“应用”。
现在从左窗格配置Blocking device interfaces。添加信息,单击确定并应用。
完成以下步骤以发起攻击并阻止:
在发动攻击之前,请转至IME,选择Event Monitoring > Dropped Attacks View,然后选择右侧的传感器。
Telnet至Router House,并使用这些命令检验从服务器发出的通信。
house#show user Line User Host(s) Idle Location * 0 con 0 idle 00:00:00 226 vty 0 idle 00:00:17 10.66.79.195 house#show access-list Extended IP access list IDS_FastEthernet0/1_in_0 permit ip host 10.66.79.195 any permit ip any any (12 matches) house#
从Router Light(路由器指示灯),Telnet至Router House(路由器房),然后键入testatck。
单击<space>或<enter>以重置Telnet会话。
light#telnet 10.100.100.1 Trying 10.100.100.1 ... Open User Access Verification Password: house>en Password: house#testattack [Connection to 10.100.100.1 lost] !--- Host 10.100.100.2 has been blocked due to the !--- signature "testattack" triggered.
Telnet至Router House,然后使用show access-list命令,如下所示。
house#show access-list Extended IP access list IDS_FastEthernet0/1_in_0 10 permit ip host 10.66.79.195 any 20 deny ip host 10.100.100.2 any (71 matches) 30 permit ip any any
在IDS事件查看器的控制面板中,一旦攻击启动,就会显示红色警报。
本部分提供的信息可用于对配置进行故障排除。
使用以下故障排除提示:
从Sensor(传感器)中查看show statistics network-access输出,并确保状态“”处于活动状态。从控制台或SSH到传感器,可查看以下信息:
sensor5#show statistics network-access Current Configuration AllowSensorShun = false ShunMaxEntries = 100 NetDevice Type = Cisco IP = 10.66.79.210 NATAddr = 0.0.0.0 Communications = telnet ShunInterface InterfaceName = FastEthernet0/1 InterfaceDirection = in State ShunEnable = true NetDevice IP = 10.66.79.210 AclSupport = uses Named ACLs State = Active ShunnedAddr Host IP = 10.100.100.2 ShunMinutes = 15 MinutesRemaining = 12 sensor5#
确保通信参数显示使用了正确的协议,例如Telnet或SSH与3DES。您可以尝试从PC上的SSH/Telnet客户端手动执行SSH或Telnet,以检查用户名和密码凭证是否正确。然后从传感器到路由器中尝试Telnet或SSH操作,看您是否能成功登录路由器。
版本 | 发布日期 | 备注 |
---|---|---|
1.0 |
17-Dec-2009 |
初始版本 |