[go: up one dir, main page]

CN104539595B - It is a kind of to integrate the SDN frameworks and method of work for threatening processing and routing optimality - Google Patents

It is a kind of to integrate the SDN frameworks and method of work for threatening processing and routing optimality Download PDF

Info

Publication number
CN104539595B
CN104539595B CN201410788069.5A CN201410788069A CN104539595B CN 104539595 B CN104539595 B CN 104539595B CN 201410788069 A CN201410788069 A CN 201410788069A CN 104539595 B CN104539595 B CN 104539595B
Authority
CN
China
Prior art keywords
message
attack
plane
network
threat
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
CN201410788069.5A
Other languages
Chinese (zh)
Other versions
CN104539595A (en
Inventor
史毓凯
杨种学
陈飞
张家华
王江平
李滢
欧家豪
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nanjing Xiaozhuang University
Original Assignee
Nanjing Xiaozhuang University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nanjing Xiaozhuang University filed Critical Nanjing Xiaozhuang University
Priority to CN201711302091.4A priority Critical patent/CN107786578A/en
Priority to CN201711302100.XA priority patent/CN107888619A/en
Priority to CN201711302098.6A priority patent/CN107888618A/en
Priority to CN201410788069.5A priority patent/CN104539595B/en
Publication of CN104539595A publication Critical patent/CN104539595A/en
Application granted granted Critical
Publication of CN104539595B publication Critical patent/CN104539595B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/14Network architectures or network communication protocols for network security for detecting or protecting against malicious traffic
    • H04L63/1408Network architectures or network communication protocols for network security for detecting or protecting against malicious traffic by monitoring network traffic
    • H04L63/1416Event detection, e.g. attack signature detection
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/12Shortest path evaluation
    • H04L45/123Evaluation of link metrics
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/12Shortest path evaluation
    • H04L45/125Shortest path evaluation based on throughput or bandwidth
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/20Support for services
    • H04L49/208Port mirroring
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/02Network architectures or network communication protocols for network security for separating internal from external traffic, e.g. firewalls
    • H04L63/0227Filtering policies
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/02Network architectures or network communication protocols for network security for separating internal from external traffic, e.g. firewalls
    • H04L63/0227Filtering policies
    • H04L63/0236Filtering by address, protocol, port number or service, e.g. IP-address or URL
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/14Network architectures or network communication protocols for network security for detecting or protecting against malicious traffic
    • H04L63/1408Network architectures or network communication protocols for network security for detecting or protecting against malicious traffic by monitoring network traffic
    • H04L63/1425Traffic logging, e.g. anomaly detection
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/14Network architectures or network communication protocols for network security for detecting or protecting against malicious traffic
    • H04L63/1441Countermeasures against malicious traffic
    • H04L63/1458Denial of Service
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/20Network architectures or network communication protocols for network security for managing network security; network security policies in general

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Hardware Design (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Computer And Data Communications (AREA)

Abstract

本发明公开了一种集威胁处理和路由优化于一体的SDN架构、系统及工作方法,本SDN网络架构,包括:应用平面、数据平面和控制平面;其中数据平面,当位于数据平面中任一IDS设备检测到攻击威胁时,DDoS攻击特征的报文时,即通过SSL通信信道上报至应用平面;应用平面,用于对攻击类型进行分析,并根据攻击类型定制相应的攻击威胁处理策略;控制平面,为应用平面提供攻击威胁处理接口,并为数据平面提供最优路径计算和/或攻击威胁识别接口。本发明可使网络在遭受大规模DDoS威胁时,能够根据链路的实时状况实现路由优化的流量转发,同时迅速准确的进行DDoS威胁识别和处理响应,全面保障网络通信质量。

The invention discloses an SDN architecture, system and working method integrating threat processing and routing optimization. The SDN network architecture includes: an application plane, a data plane, and a control plane; When the IDS device detects an attack threat, a packet with DDoS attack characteristics is reported to the application plane through the SSL communication channel; the application plane is used to analyze the attack type, and customize the corresponding attack threat processing strategy according to the attack type; control The plane provides an attack threat processing interface for the application plane, and provides an optimal path calculation and/or attack threat identification interface for the data plane. The present invention enables the network to realize route-optimized traffic forwarding according to the real-time status of links when the network suffers from large-scale DDoS threats, and at the same time quickly and accurately perform DDoS threat identification and processing responses, thereby fully guaranteeing network communication quality.

Description

一种集威胁处理和路由优化于一体的SDN架构及工作方法An SDN Architecture and Working Method Integrating Threat Processing and Routing Optimization

技术领域technical field

本发明涉及网络安全领域,特别是涉及一种集DDoS威胁过滤、路由优化于一体的SDN架构及工作方法。The invention relates to the field of network security, in particular to an SDN architecture and working method integrating DDoS threat filtering and routing optimization.

背景技术Background technique

当前,高速广泛连接的网络已经成为现代社会的重要基础设施。然而,随着互联网规模的膨胀,传统规范体系的缺陷也日益呈现出来。At present, high-speed and widely connected networks have become an important infrastructure of modern society. However, with the expansion of the scale of the Internet, the defects of the traditional normative system are increasingly emerging.

国家计算机网络应急技术处理协调中心(CNCERT/CC)最新发布的报告表明:黑客活动日趋频繁,网站后门、网络钓鱼、Web恶意挂马等攻击事件呈大幅增长趋势,国家、企业的网络安全性面临着严峻挑战。The latest report released by the National Computer Network Emergency Response Technology Coordination Center (CNCERT/CC) shows that hacker activities are becoming more and more frequent, and attacks such as website backdoors, phishing, and malicious web malware are on the rise. facing serious challenges.

其中,分布式拒绝服务攻击(Distributed Denial of Service,DDoS)仍然是影响互联网运行安全最主要的威胁之一。在过去的几年里,DDoS攻击的数目、大小、类型都大幅上涨。Among them, Distributed Denial of Service attack (Distributed Denial of Service, DDoS) is still one of the most important threats affecting the security of Internet operation. The number, size, and type of DDoS attacks have increased dramatically over the past few years.

软件定义网络(Software Defined Network,SDN)具有可实时更新路由策略与规则、支持深层次的数据包分析等特性,因而可针对复杂网络环环境中的DDoS威胁提供更迅速准确的网络监控及防御功能。Software Defined Network (SDN) has the characteristics of real-time update of routing policies and rules, support for in-depth data packet analysis, etc., so it can provide faster and more accurate network monitoring and defense functions against DDoS threats in complex network ring environments .

发明内容Contents of the invention

本发明的目的是提供一种集威胁处理和路由优化于一体的SDN架构及工作方法,以解决现有网络中大量DDoS攻击所造成的网络安全问题,以实现快速、高效、全面地识别与防御DDoS攻击。The purpose of the present invention is to provide an SDN architecture and working method that integrates threat processing and routing optimization to solve the network security problems caused by a large number of DDoS attacks in the existing network, so as to realize fast, efficient and comprehensive identification and defense DDoS attack.

为了解决上述技术问题,本发明提供了一种SDN网络架构,包括:应用平面、数据平面和控制平面;其中In order to solve the above technical problems, the present invention provides an SDN network architecture, including: application plane, data plane and control plane; wherein

数据平面,当位于数据平面中任一IDS设备检测到DDoS攻击特征的报文时,即通过SSL通信信道上报至应用平面;Data plane, when any IDS device in the data plane detects a message with DDoS attack characteristics, it will report to the application plane through the SSL communication channel;

应用平面,用于对攻击类型进行分析,并根据攻击类型定制相应的攻击威胁处理策略;The application plane is used to analyze the attack type and customize the corresponding attack threat handling strategy according to the attack type;

控制平面,为应用平面提供攻击威胁处理接口,并为数据平面提供最优路径计算和/或攻击威胁识别接口。The control plane provides an attack threat processing interface for the application plane, and provides an optimal path calculation and/or attack threat identification interface for the data plane.

优选的,为了在IDS设备中实现DDoS检测,所述IDS设备内包括:欺骗报文检测模块,对链路层和网际层地址的欺骗行为进行检测;破坏报文检测模块,对网际层和传输层标志位设置的异常行为进行检测;异常报文检测模块,对应用层和传输层泛洪式攻击行为进行检测;通过所述欺骗报文检测模块、破坏报文检测模块、异常报文检测模块依次对报文进行检测;且若任一检测模块检测出报文存在上述相应行为时,则将该报文转入应用平面。Preferably, in order to realize DDoS detection in the IDS device, the IDS device includes: a fraudulent message detection module, which detects the fraudulent behavior of the link layer and the Internet layer address; The abnormal behavior of layer flag bit setting is detected; the abnormal message detection module detects the flooding attack behavior of the application layer and the transport layer; The packets are detected sequentially; and if any detection module detects that the above-mentioned corresponding behavior exists in the packet, the packet is transferred to the application plane.

优选的,所述应用平面适于当报文具有欺骗行为,且攻击威胁在OpenFlow域中,则通过控制平面中的控制器屏蔽主机;或当攻击威胁不在OpenFlow域中,则通过控制器将该报文所对应的交换机接入端口流量重定向至流量清洗中心进行过滤;Preferably, the application plane is suitable for when the message has fraudulent behavior, and the attack threat is in the OpenFlow domain, then the controller in the control plane shields the host; or when the attack threat is not in the OpenFlow domain, the controller passes the The access port traffic of the switch corresponding to the message is redirected to the traffic cleaning center for filtering;

所述应用平面还适于当报文具有异常行为,则通过控制器对攻击程序或攻击主机的流量进行屏蔽;以及The application plane is also suitable for shielding the traffic of the attack program or the attack host through the controller when the message has abnormal behavior; and

当报文具有泛洪式攻击行为,则所述应用平面适于通过控制器将该报文所对应的交换机接入端口流量重定向至流量清洗中心进行过滤。When the message has a flood attack behavior, the application plane is adapted to redirect the traffic of the access port of the switch corresponding to the message to the traffic cleaning center through the controller for filtering.

本发明的有益效果:本发明将DDoS威胁监测、威胁防护、路由优化等业务功能模块分别部署于数据平面、控制平面和应用平面。可使网络在遭受大规模DDoS威胁时,能够根据链路的实时状况实现路由优化的流量转发,同时迅速准确的进行DDoS威胁识别和处理响应,全面保障网络通信质量。Beneficial effects of the present invention: the present invention deploys service function modules such as DDoS threat monitoring, threat protection, and routing optimization on the data plane, control plane, and application plane, respectively. When the network suffers from large-scale DDoS threats, it can realize routing-optimized traffic forwarding according to the real-time status of the link, and at the same time quickly and accurately identify and process DDoS threats to fully guarantee the quality of network communication.

又一方面,本发明还提供了一种DDoS威胁过滤SDN系统的工作方法,以解决防御DDoS攻击的技术问题。In another aspect, the present invention also provides a working method of a DDoS threat filtering SDN system to solve the technical problem of defending against DDoS attacks.

为了解决上述技术问题,所述DDoS威胁过滤SDN系统的工作方法包括:当任一IDS设备检测到具有DDoS攻击特征的报文时,即通过SSL通信信道上报至IDS决策服务器;所述IDS决策服务器根据上报信息,制定出与具有DDoS攻击特征的报文对应的处理策略,然后将该报文通过控制器屏蔽或者将该报文所对应的交换机接入端口流量重定向到流量清洗中心进行过滤。In order to solve the above technical problems, the working method of the DDoS threat filtering SDN system includes: when any IDS device detects a message with DDoS attack characteristics, it reports to the IDS decision server through the SSL communication channel; the IDS decision server According to the reported information, formulate the processing policy corresponding to the message with DDoS attack characteristics, and then shield the message through the controller or redirect the traffic of the access port of the switch corresponding to the message to the traffic cleaning center for filtering.

优选的,为了在IDS设备中实现DDoS检测,所述IDS设备内包括:欺骗报文检测模块,对链路层和网际层地址的欺骗行为进行检测;破坏报文检测模块,对网际层和传输层标志位设置的异常行为进行检测;异常报文检测模块,对应用层和传输层泛洪式攻击行为进行检测;通过所述欺骗报文检测模块、破坏报文检测模块、异常报文检测模块依次对报文进行检测;且若任一检测模块检测出报文存在上述相应行为时,则将该报文转入IDS决策服务器。Preferably, in order to realize DDoS detection in the IDS device, the IDS device includes: a fraudulent message detection module, which detects the fraudulent behavior of the link layer and the Internet layer address; The abnormal behavior of layer flag bit setting is detected; the abnormal message detection module detects the flooding attack behavior of the application layer and the transport layer; The packets are detected sequentially; and if any detection module detects that the above-mentioned corresponding behavior exists in the packet, the packet is transferred to the IDS decision server.

优选的,所述IDS决策服务器适于当报文具有欺骗行为,且攻击威胁在OpenFlow域中,则通过控制器屏蔽主机;或当攻击威胁不在OpenFlow域中,则通过控制器将该报文所对应的交换机接入端口流量重定向至流量清洗中心进行过滤;所述IDS决策服务器还适于当报文具有异常行为,则通过控制器对攻击程序或攻击主机的流量进行屏蔽;以及当报文具有泛洪式攻击行为,则所述IDS决策服务器适于通过控制器将该报文所对应的交换机接入端口流量重定向至流量清洗中心进行过滤。Preferably, the IDS decision server is adapted to shield the host through the controller when the message has deceptive behavior and the attack threat is in the OpenFlow domain; or when the attack threat is not in the OpenFlow domain, then use the controller to block the message The traffic of the corresponding switch access port is redirected to the traffic cleaning center for filtering; the IDS decision server is also suitable for shielding the traffic of the attack program or the attack host through the controller when the packet has abnormal behavior; and when the packet If there is a flood attack behavior, the IDS decision server is adapted to redirect the traffic of the access port of the switch corresponding to the message to the traffic cleaning center through the controller for filtering.

第三方面,本发明还提供了一种集威胁处理和路由优化于一体的SDN系统的工作方法,以解决对DDoS攻击的分布式监测,在制定相应威胁处理策略的技术问题。In the third aspect, the present invention also provides a working method of an SDN system integrating threat processing and routing optimization, so as to solve the technical problems of distributed monitoring of DDoS attacks and formulation of corresponding threat processing strategies.

为了解决上述技术问题,本发明还提供了一种集威胁处理和路由优化于一体的SDN系统的工作方法,包括如下步骤:In order to solve the above-mentioned technical problems, the present invention also provides a working method of an SDN system integrating threat processing and routing optimization, including the following steps:

步骤S100,网络初始化;步骤S200,分布式DDoS威胁监测;以及步骤S300,威胁处理和/或路由优化。Step S100, network initialization; Step S200, distributed DDoS threat monitoring; and Step S300, threat processing and/or route optimization.

优选的,为了更好的实现网络配置,所述步骤S100中网络初始化所涉及的装置包括:控制器、IDS决策服务器和分布式的IDS设备;Preferably, in order to better realize the network configuration, the devices involved in the network initialization in the step S100 include: a controller, an IDS decision server and distributed IDS devices;

网络初始化的步骤如下:The steps of network initialization are as follows:

所述控制器构建网络设备信息绑定表,并且将网络设备信息绑定表实时更新到各IDS设备中;The controller constructs a network device information binding table, and updates the network device information binding table to each IDS device in real time;

所述控制器下发镜像策略的流表,即将OF交换机所有拖载有主机的端口流量镜像转发给网域内对应的IDS设备;以及The controller issues the flow table of the mirroring strategy, that is, forwards all port traffic mirroring of the host towed by the OF switch to the corresponding IDS device in the network domain; and

所述控制器下发DDoS威胁识别规则给每个网域中对应的各IDS设备;The controller issues DDoS threat identification rules to each corresponding IDS device in each network domain;

所述步骤S200中分布式DDoS威胁监测的方法包括:The method for distributed DDoS threat monitoring in the step S200 includes:

依次对链路层和网际层地址的欺骗行为,网际层和传输层标志位设置异常行为,以及应用层和传输层的泛洪式攻击行为进行检测;Detect the spoofing behavior of the link layer and the Internet layer address, the abnormal behavior of the flag bit setting of the Internet layer and the transport layer, and the flood attack behavior of the application layer and the transport layer in turn;

若上述过程中任一检测判断出报文存在相应行为时,则将该报文转入步骤S300。If any detection in the above process determines that the message has a corresponding behavior, then the message is transferred to step S300.

优选的,对链路层和网际层地址的欺骗行为进行检测的方法包括:Preferably, the method for detecting spoofing of link layer and Internet layer addresses includes:

通过欺骗报文检测模块对欺骗行为进行检测,即首先,通过欺骗报文检测模块调用网络设备信息绑定表;其次,通过欺骗报文检测模块将封装在Packet-In消息中报文的类型进行解析,以获得相应的源、目的IP地址、MAC地址以及上传此Packet-In消息的交换机DPID号和端口号,并将上述各信息分别与网络设备信息绑定表中的相应信息进行比对;若报文中的上述信息匹配,则将报文进行下一检测;若报文中的上述信息不匹配,则将报文转入步骤S300;所述网际层和传输层标志位设置异常行为进行检测的方法包括:通过破坏报文检测模块对标志位设置异常行为进行检测,即对报文的各标志位进行检测,以判断各标志位是否符合TCP/IP协议规范;若报文的各标志位符合,则将报文转入进行下一检测;若报文的各标志位不符合,则将报文转入步骤S300;所述应用层和传输层的泛洪式攻击行为进行检测的方法包括:通过异常报文检测模块对泛洪式攻击行为进行检测,即在异常报文检测模块构建用于识别泛洪式攻击报文的哈希表,并根据该哈希表中设定的阀值判断报文是否具有泛洪式攻击行为,且将判断结果转入步骤S300。The fraudulent behavior is detected by the fraudulent message detection module, that is, at first, the network device information binding table is called by the fraudulent message detection module; secondly, the type of the message encapsulated in the Packet-In message is detected by the fraudulent message detection module Parse to obtain the corresponding source and destination IP addresses, MAC addresses, and the DPID number and port number of the switch that uploaded the Packet-In message, and compare the above information with the corresponding information in the network device information binding table; If the above-mentioned information in the message matches, then the next detection is carried out with the message; If the above-mentioned information in the message does not match, then the message is transferred to step S300; The detection method comprises: by destroying the message detection module, the abnormal behavior of flag bit setting is detected, that is, each flag bit of the message is detected to judge whether each flag bit conforms to the TCP/IP protocol specification; if each flag bit of the message If the bit matches, then the message is transferred to the next detection; if each flag bit of the message does not match, the message is transferred to step S300; the method for detecting the flooding attack behavior of the application layer and the transport layer Including: detecting the flood attack behavior through the abnormal message detection module, that is, constructing a hash table for identifying flood attack messages in the abnormal message detection module, and according to the threshold set in the hash table value to determine whether the message has a flooding attack behavior, and transfer the determination result to step S300.

优选的,所述步骤S300中威胁处理和/或路由优化的方法包括:若报文具有欺骗行为,且攻击威胁在OpenFlow域中,则所述IDS决策服务器适于通过控制器屏蔽主机;以及当攻击威胁不在OpenFlow域中,则通过控制器将该报文所对应的交换机接入端口流量重定向至流量清洗中心进行过滤;若报文具有异常行为,则所述IDS决策服务器通过控制器对攻击程序或攻击主机的流量进行屏蔽;若报文具有泛洪式攻击行为,则所述IDS决策服务器通过控制器将该报文所对应的交换机接入端口流量重定向至流量清洗中心进行过滤;和/或根据链路负载系数计算出优化路径,即检测两相邻节点的链路剩余带宽,获得该链路的负载系数,在根据该负载系数和初始化的网络拓扑图获得任意两点的最优路径,所述控制器根据该最优路径得出对应的转发流表并下发各交换机。Preferably, the method for threat processing and/or route optimization in step S300 includes: if the message has fraudulent behavior and the attack threat is in the OpenFlow domain, the IDS decision server is adapted to shield the host through the controller; and when If the attack threat is not in the OpenFlow domain, the traffic of the access port of the switch corresponding to the message is redirected to the traffic cleaning center by the controller for filtering; The traffic of the program or the attacking host is shielded; if the message has a flooding attack behavior, the IDS decision server redirects the traffic of the switch access port corresponding to the message to the traffic cleaning center through the controller for filtering; and /or calculate the optimal path according to the link load factor, that is, detect the remaining link bandwidth of two adjacent nodes, obtain the load factor of the link, and obtain the optimal path of any two points according to the load factor and the initialized network topology map path, the controller obtains a corresponding forwarding flow table according to the optimal path and issues it to each switch.

优选的,所述IDS决策服务器屏蔽发送报文的程序和/或主机的方法包括:首先,构建计数用的相应哈希表及设定相应阈值,即单位时间内,所述IDS决策服务器中构建对欺骗行为进行计数的第一哈希表,标志位设置异常行为进行计数的第二哈希表,以及对泛洪式攻击行为进行计数的第三哈希表;同时设定第一、第二、第三哈希表中的第一、第二、第三阀值;其次,屏蔽发送该报文的程序和/或主机,即针对转入IDS决策服务器的报文的行为,利用相应哈希表进行计数,当计数值超过相应阀值时,屏蔽发送该报文的程序和/或主机。Preferably, the method for the IDS decision server to shield the program and/or host that sends the message includes: first, constructing a corresponding hash table for counting and setting a corresponding threshold, that is, within a unit time, the IDS decision server constructs The first hash table for counting fraudulent behaviors, the second hash table for counting abnormal behaviors with flag bits set, and the third hash table for counting flooding attack behaviors; set the first and second hash tables at the same time , the first, second, and third thresholds in the third hash table; secondly, shield the program and/or host that sends the message, that is, use the corresponding hash for the behavior of the message transferred to the IDS decision server The table counts, and when the count exceeds the corresponding threshold, the program and/or the host that sends the message is blocked.

本发明的有益效果:(1)本发明将DDoS威胁过滤技术与路由优化技术融合,在进行监测、屏蔽DDOS攻击时,并不会造成数据的拥堵,并且通过将监测和威胁处理分开,有效的减轻了控制层面的负担,保证了网络更安全、高校的运行;(2)本发明使得传统网络体系架构下无法对地址伪造DDoS攻击进行识别与溯源的难题从根本上得到了解决。在网络中存在DDoS攻击或正常大流量业务的情况下,控制器可基于对链路剩余带宽等网络参数的实时感知,实现对正常流量的路由优化,大幅提升用户的体验;(3)本发明的处理架构采用可扩展的模块化设计,实现了对DDoS威胁的高效检测和灵活处理;(4)各模块获取数据包信息采用独立的接口设计,降低了模块间的耦合关联性;(5)各模块使用优化的程序数据结构,细致分割各处理子流程,提升了模块的高内聚特性。Beneficial effects of the present invention: (1) the present invention integrates DDoS threat filtering technology and routing optimization technology, when monitoring and shielding DDOS attacks, data congestion will not be caused, and by separating monitoring and threat processing, effective The burden on the control plane is reduced, and the network is safer and the operation of universities is guaranteed; (2) the present invention fundamentally solves the problem that the address forgery DDoS attack cannot be identified and traced under the traditional network architecture. In the case of DDoS attacks or normal high-traffic services in the network, the controller can realize the routing optimization of normal traffic based on the real-time perception of network parameters such as the remaining bandwidth of the link, and greatly improve the user experience; (3) the present invention The processing architecture adopts scalable modular design, which realizes efficient detection and flexible processing of DDoS threats; (4) each module adopts independent interface design to obtain data packet information, which reduces the coupling correlation between modules; (5) Each module uses an optimized program data structure to finely divide each processing sub-flow, which improves the high cohesion characteristics of the module.

附图说明Description of drawings

为了使本发明的内容更容易被清楚的理解,下面根据的具体实施例并结合附图,对本发明作进一步详细的说明,其中In order to make the content of the present invention more easily understood, the present invention will be described in further detail below in conjunction with the specific embodiments according to the accompanying drawings, wherein

图1示出了软件定义网络中数据层的原理框图;Figure 1 shows a functional block diagram of a data layer in a software-defined network;

图2示出了基于SDN架构的DDoS攻击识别与防护系统的原理框图;Fig. 2 shows the functional block diagram of the DDoS attack identification and protection system based on SDN architecture;

图3示出了欺骗报文检测模块的工作流程图;Fig. 3 shows the working flow diagram of fraudulent message detection module;

图4示出了破坏报文检测模块的工作流程图;Fig. 4 shows the work flow chart of destroying message detection module;

图5示出了UDP Floodling的检测流程图;Fig. 5 shows the detection flowchart of UDP Floodling;

图6示出了ICMP Floodling的检测流程图。FIG. 6 shows a flow chart of ICMP Floodling detection.

具体实施方式Detailed ways

为使本发明的目的、技术方案和优点更加清楚明了,下面结合具体实施方式并参照附图,对本发明进一步详细说明。应该理解,这些描述只是示例性的,而并非要限制本发明的范围。此外,在以下说明中,省略了对公知结构和技术的描述,以避免不必要地混淆本发明的概念。In order to make the object, technical solution and advantages of the present invention clearer, the present invention will be further described in detail below in combination with specific embodiments and with reference to the accompanying drawings. It should be understood that these descriptions are exemplary only, and are not intended to limit the scope of the present invention. Also, in the following description, descriptions of well-known structures and techniques are omitted to avoid unnecessarily obscuring the concept of the present invention.

图1示出了软件定义网络中数据层的原理框图。Figure 1 shows a functional block diagram of the data layer in software-defined networking.

如图1所示,在软件定义网络(Software Defined Network,SDN)架构中,当一个报文(Packet)到达交换机的时候,首先对交换机中所带的流表进行匹配。如果匹配成功,就按照流表指定的动作执行转发规则。如果匹配失败,则交换机将该报文封装在Packet In消息中,发送给控制器,并且交换机将此报文存在本地缓存中。等待控制器作出决策,如何处理此报文。As shown in FIG. 1 , in a software-defined network (Software Defined Network, SDN) architecture, when a packet (Packet) arrives at a switch, the flow table carried in the switch is first matched. If the match is successful, execute the forwarding rule according to the action specified in the flow table. If the matching fails, the switch encapsulates the packet in a Packet In message and sends it to the controller, and the switch stores the packet in a local cache. Wait for the controller to make a decision on how to process this message.

网络中有很多主机,则需要建立一张针对网络中所有主机为键的哈希表,称之为“违规次数哈希表组”,其包括:适于对欺骗报文进行计数的第一哈希表,适于对破坏报文进行计数的第二哈希表,适于对泛洪式攻击进行计数的第三哈希表。记录对应主机的违规次数,也就是主机的诚信度。If there are many hosts in the network, it is necessary to establish a hash table with keys for all hosts in the network, which is called "violation times hash table group", which includes: the first hash table suitable for counting spoofed messages A hash table, a second hash table suitable for counting damaged packets, and a third hash table suitable for counting flood attacks. Record the number of violations of the corresponding host, that is, the integrity of the host.

网络中的数据包是实时的,所以需要建立一种单位时间内的威胁报文计数的哈希表,并且每个主机对应一个哈希表中的一个键,对应的键值是记录的单位时间内对应键的主机发送的威胁数据包的个数。此类哈希表在单位时间“时间片”开始时候必须将哈希表内所有键对应的键值置0;且每种检测的报文都需要有这样的一张表,就比如说检测了100种报文,就需要有100个此类的哈希表。The data packets in the network are real-time, so it is necessary to establish a hash table of threat message counts per unit time, and each host corresponds to a key in the hash table, and the corresponding key value is the recorded unit time The number of threat data packets sent by the host corresponding to the key. This type of hash table must set the key values corresponding to all keys in the hash table to 0 at the beginning of the unit time "time slice"; and each type of detected message needs to have such a table, for example, detected For 100 types of messages, 100 such hash tables are required.

而且,每个哈希表必须有一个对应的阈值。哈希表中只要一有主机在相应值中累加计数。计数后检查该值是否超过设定的阈值。如果超过相应的阈值,则在违规次数哈希表对应记录中的键值计数。Also, each hash table must have a corresponding threshold. As long as there is a host in the hash table, the count is accumulated in the corresponding value. Check if the value exceeds the set threshold after counting. If the corresponding threshold is exceeded, the key-value count in the corresponding record of the number of violations hash table.

并且,每个哈希表的阈值,哈希表时间片长度等参数都是可以通过接口调节的。Moreover, parameters such as the threshold of each hash table and the time slice length of the hash table can be adjusted through the interface.

例如:主机的哈希表为:For example: the hash table for hosts is:

单位时间欺骗报文计数哈希表Spoofed packet count hash table per unit time

Host1Host1 Host2Host2 Host3Host3 Host4Host4 Host5Host5 Host6Host6 Host7Host7 Host8Host8 ...... … Host nHost n 11 22 22 11 100100 22 00 00 ...... … 00

单位时间破坏报文计数哈希表Destroy packet count hash table per unit time

单位时间SYN计数哈希表SYN count hash table per unit time

Host1Host1 Host2Host2 Host3Host3 Host4Host4 Host5Host5 Host6Host6 Host7Host7 Host8Host8 ...... … Host nHost n 11 11 00 11 100100 22 00 00 ...... … 00

单位时间UDP Flood计数哈希表UDP Flood count hash table per unit time

单位时间ICMP Flood计数哈希表ICMP Flood count hash table per unit time

以上所有的哈希表都是单位时间计数表,时间片计数开始会将所有对应键值置0;All the above hash tables are counting tables per unit time, and all corresponding key values will be set to 0 when the time slice counting starts;

违规次数哈希表Violations Hash Table

在上述发明原理的基础上,本实施例的具体实施过程如下。On the basis of the principles of the above invention, the specific implementation process of this embodiment is as follows.

实施例1Example 1

一种SDN网络架构,包括:应用平面、数据平面和控制平面;其中数据平面,当位于数据平面中任一IDS(即入侵检测设备)设备检测到DDoS攻击特征的报文时,即通过SSL通信信道上报至应用平面;应用平面,用于对攻击类型进行分析,并根据攻击类型定制相应的攻击威胁处理策略;控制平面,为应用平面提供攻击威胁处理接口,并为数据平面提供最优路径计算和/或攻击威胁识别接口。A kind of SDN network framework, comprises: application plane, data plane and control plane; Wherein data plane, when being positioned at any IDS (being intrusion detection device) equipment in the data plane detects the message of DDoS attack characteristic, namely through SSL communication The channel is reported to the application plane; the application plane is used to analyze the attack type, and customize the corresponding attack threat processing strategy according to the attack type; the control plane provides the attack threat processing interface for the application plane, and provides the optimal path calculation for the data plane and/or attack threat identification interfaces.

其中,DDoS攻击特征定义为:对链路层和网际层地址的欺骗行为、对网际层和传输层标志位设置的异常行为,以及对应用层和传输层泛洪式攻击行为。Among them, the characteristics of DDoS attack are defined as: spoofing of link layer and Internet layer addresses, abnormal behavior of Internet layer and transport layer flag setting, and flood attack behavior of application layer and transport layer.

所述IDS设备内包括:The IDS equipment includes:

欺骗报文检测模块,对链路层和网际层地址的欺骗行为进行检测;破坏报文检测模块,对网际层和传输层标志位设置的异常行为进行检测;异常报文检测模块,对应用层和传输层泛洪式攻击行为进行检测;通过所述欺骗报文检测模块、破坏报文检测模块、异常报文检测模块依次对报文进行检测;且若任一检测模块检测出报文存在上述相应行为时,则将该报文转入应用平面。Spoofed message detection module detects the spoofing behavior of link layer and Internet layer addresses; damage message detection module detects abnormal behaviors set by Internet layer and transport layer flag bits; abnormal message detection module detects the abnormal behavior of application layer and transport layer flood attack behaviors are detected; through the fraudulent message detection module, damaged message detection module, and abnormal message detection module, the messages are detected in turn; and if any detection module detects that the message has the above-mentioned When the corresponding action is taken, the message is transferred to the application plane.

所述应用平面适于当报文具有欺骗行为,且攻击威胁在OpenFlow域中,则通过控制平面中的控制器屏蔽主机;或当攻击威胁不在OpenFlow域中,则通过控制器将该报文所对应的交换机接入端口流量重定向至流量清洗中心进行过滤;所述应用平面还适于当报文具有异常行为,则通过控制器对攻击程序或攻击主机的流量进行屏蔽;以及当报文具有泛洪式攻击行为,则所述应用平面适于通过控制器将该报文所对应的交换机接入端口流量重定向至流量清洗中心进行过滤。The application plane is suitable for when the message has fraudulent behavior and the attack threat is in the OpenFlow domain, then the controller in the control plane shields the host; or when the attack threat is not in the OpenFlow domain, then the message is transmitted by the controller The traffic of the corresponding switch access port is redirected to the traffic cleaning center for filtering; the application plane is also suitable for shielding the traffic of the attacking program or attacking host through the controller when the message has abnormal behavior; and when the message has flooding attack behavior, the application plane is suitable for redirecting the access port traffic of the switch corresponding to the message to the traffic cleaning center through the controller for filtering.

应用平面的关于攻击类型分析、攻击威胁处理策略,数据平面的攻击行为监测、攻击威胁屏蔽和路由优化,以及控制平面的攻击威胁处理、攻击威胁识别和最优路径计算将在下面的实施例中展开。The attack type analysis and attack threat processing strategy of the application plane, the attack behavior monitoring, attack threat shielding and route optimization of the data plane, and the attack threat processing, attack threat identification and optimal path calculation of the control plane will be described in the following embodiments Expand.

其中,应用平面可以通过IDS决策服务器来实现,控制平面可以通过控制器来实现。具体可详见以下实施例。Wherein, the application plane can be realized through the IDS decision server, and the control plane can be realized through the controller. For details, see the following examples.

实施例2Example 2

如图2所示,在所述DDoS威胁过滤SDN系统基础上的一种工作方法,其包括:当任一IDS设备检测到具有DDoS攻击特征的报文时,即通过SSL通信信道上报至IDS决策服务器;所述IDS决策服务器根据上报信息,制定出与具有DDoS攻击特征的报文对应的处理策略,然后将该报文通过控制器屏蔽或者将该报文所对应的交换机接入端口流量重定向到流量清洗中心进行过滤。As shown in Figure 2, a working method based on the DDoS threat filtering SDN system includes: when any IDS device detects a message with DDoS attack characteristics, it reports to the IDS decision-making through the SSL communication channel Server; the IDS decision server formulates a processing strategy corresponding to the message with DDoS attack characteristics according to the reported information, and then shields the message through the controller or redirects the flow of the switch access port corresponding to the message Go to the flow cleaning center for filtration.

进一步,所述IDS设备内包括:Further, the IDS equipment includes:

欺骗报文检测模块,对链路层和网际层地址的欺骗行为进行检测;Spoofed message detection module detects spoofing behavior of link layer and Internet layer addresses;

破坏报文检测模块,对网际层和传输层标志位设置的异常行为进行检测;Destroy the message detection module to detect abnormal behaviors set by the flag bits of the Internet layer and the transport layer;

异常报文检测模块,对应用层和传输层泛洪式攻击行为进行检测;Abnormal message detection module, which detects the flood attack behavior of the application layer and the transport layer;

通过所述欺骗报文检测模块、破坏报文检测模块、异常报文检测模块依次对报文进行检测;Detecting the messages sequentially through the fraudulent message detection module, the damaged message detection module, and the abnormal message detection module;

且若任一检测模块检测出报文存在上述相应行为时,则将该报文转入IDS决策服务器。And if any detection module detects that the message has the above-mentioned corresponding behavior, it transfers the message to the IDS decision server.

进一步,所述IDS决策服务器适于当报文具有欺骗行为,且攻击威胁在OpenFlow域中,则通过控制器屏蔽主机;或当攻击威胁不在OpenFlow域中,则通过控制器将该报文所对应的交换机接入端口流量重定向至流量清洗中心进行过滤;所述IDS决策服务器还适于当报文具有异常行为,则通过控制器对攻击程序或攻击主机的流量进行屏蔽;以及当报文具有泛洪式攻击行为,则所述IDS决策服务器适于通过控制器将该报文所对应的交换机接入端口流量重定向至流量清洗中心进行过滤。Further, the IDS decision server is adapted to shield the host through the controller when the message has deceptive behavior and the attack threat is in the OpenFlow domain; or when the attack threat is not in the OpenFlow domain, then use the controller to correspond to the message The access port traffic of the switch is redirected to the traffic cleaning center for filtering; the IDS decision server is also suitable for shielding the flow of the attacking program or attacking host through the controller when the message has abnormal behavior; and when the message has abnormal behavior flooding attack behavior, the IDS decision server is adapted to redirect the access port traffic of the switch corresponding to the message to the traffic cleaning center through the controller for filtering.

本发明采用从欺骗报文检测模块到破坏报文检测模块,再到异常报文检测模块依次检测的顺序,其中,各模块获取数据包信息采用独立的接口设计,降低了模块间的耦合关联性;并且各模块使用优化的程序数据结构,细致分割各处理子流程,提升了模块的高内聚特性。这种检测顺序提高了对报文数据的检测效率,以及降低了漏检率。The present invention adopts the sequence from the fraudulent message detection module to the damaged message detection module, and then to the abnormal message detection module, wherein each module adopts an independent interface design to obtain data packet information, which reduces the coupling correlation between modules ; and each module uses an optimized program data structure to finely divide each processing sub-flow, which improves the high cohesion characteristics of the module. This detection sequence improves the detection efficiency of message data and reduces the missed detection rate.

如图3所示,通过所述欺骗报文检测模块调用网络设备信息绑定表,并在所述IDS决策服务器中构建单位时间内的适于对报文欺骗行为进行计数的第一哈希表,以及设定该第一哈希表中的第一阀值;所述欺骗报文检测模块,将封装在Packet-In消息中的报文的类型进行解析,以获得相应的源、目的IP地址、MAC地址以及上传Packet-In消息的交换机DPID号和端口号信息,并将各信息分别与网络设备信息绑定表中的相应信息进行比对;若报文中的上述信息匹配,则将报文转入破坏报文检测模块;若报文中的上述信息不匹配,则转入所述IDS决策服务器,对报文进行丢弃,并同时对欺骗行为进行计数,当该计数值超过第一阀值时,屏蔽发送该报文的程序和/或主机。As shown in Figure 3, the network device information binding table is invoked by the fraudulent message detection module, and the first hash table suitable for counting message fraudulent behaviors is constructed in the IDS decision server within a unit time , and setting the first threshold in the first hash table; the fraudulent message detection module analyzes the type of the message encapsulated in the Packet-In message to obtain the corresponding source and destination IP addresses , MAC address, and the DPID number and port number information of the switch that uploaded the Packet-In message, and compare each information with the corresponding information in the network device information binding table; if the above information in the message matches, the report will be The text is transferred to the damaged message detection module; if the above information in the message does not match, it is transferred to the IDS decision server, the message is discarded, and the fraudulent behavior is counted at the same time, when the count value exceeds the first threshold When set to a value, blocks the program and/or host that sent the message.

具体的,所述欺骗报文检测模块用于对报文进行第一次判断,即判断报文是否是IP欺骗攻击报文、端口欺骗攻击报文或MAC欺骗攻击报文。Specifically, the spoofed message detection module is used to judge the message for the first time, that is, to determine whether the message is an IP spoofing attack message, a port spoofing attack message or a MAC spoofing attack message.

具体步骤包括:首先在以太网帧中解析出源、目的MAC地址和交换机入口,然后根据不同的报文类型解析出不同的报文。当报文类型为IP、ARP、RARP时,则解析出相应的源、目的IP地址然后将这些信息对网络设备信息绑定表中的信息进行查表匹配,如果匹配到相应的信息,则交给破坏报文检测模块处理。若不匹配,则将该报文转入IDS决策服务器处理;并同时对欺骗行为进行累加计数,当该计数值超过第一阀值时,屏蔽发送该报文的程序和/或主机。The specific steps include: first parsing out the source, destination MAC address and switch entry in the Ethernet frame, and then parsing out different messages according to different message types. When the packet type is IP, ARP, or RARP, the corresponding source and destination IP addresses are parsed out, and then the information is checked and matched against the information in the network device information binding table. If the corresponding information is matched, the It is processed by the damaged message detection module. If it does not match, the message is transferred to the IDS decision server for processing; and at the same time, the cheating behavior is accumulated and counted, and when the count value exceeds the first threshold, the program and/or host that sends the message is blocked.

Floodlight中有一个设备管理器模块DeviceManagerImpl,当一个设备在网络中移动设备的时候跟踪设备,并且根据新流定义设备。Floodlight has a device manager module, DeviceManagerImpl, that tracks devices as they move across the network and defines devices based on new flows.

设备管理器从PacketIn请求中得知设备,并从PacketIn报文中获取设备网络参数信息(源、目的IP、MAC、VLAN等信息),通过实体分类器将设备进行区分为交换机或主机。默认情况下实体分类器使用MAC地址和/或VLAN表示一个设备,这两个属性可以唯一的标识一个设备。另外一个重要的信息是设备的安装点(交换机的DPID号和端口号)(,在一个openflow区域中,一个设备只能有一个安装点,在这里openflow区域指的是和同一个Floodlight实例相连的多个交换机的集合。设备管理器也为IP地址、安装点、设备设置了过期时间,最后一次时间戳作为判断它们是否过期的依据。)The device manager knows the device from the PacketIn request, and obtains the device network parameter information (source, destination IP, MAC, VLAN, etc.) from the PacketIn message, and distinguishes the device into a switch or a host through an entity classifier. By default, the entity classifier uses MAC address and/or VLAN to represent a device, and these two attributes can uniquely identify a device. Another important information is the installation point of the device (DPID number and port number of the switch) (in an openflow area, a device can only have one installation point, here the openflow area refers to the same Floodlight instance connected A collection of multiple switches. The device manager also sets expiration times for IP addresses, installation points, and devices, and the last timestamp is used as the basis for judging whether they are expired.)

故网络设备信息绑定表模块里面只需调用DeviceManagerImpl模块提供的IDeviceService即可,同时向该服务添加IDeviceListener的监听接口即可。Therefore, the network device information binding table module only needs to call the IDeviceService provided by the DeviceManagerImpl module, and add the monitoring interface of IDeviceListener to the service at the same time.

其中IDeviceListener提供的监听接口有:Among them, the monitoring interfaces provided by IDeviceListener are:

服务提供者:IFloodlightProviderService,IDeviceServiceService provider: IFloodlightProviderService, IDeviceService

依赖接口:IFloodlightModule,IDeviceListenerDependency interface: IFloodlightModule, IDeviceListener

表内的记录根据交换机的高低电平触发机制(网线拔出触发Port Down的低电平,网线拔入触发Port Up的高电平)可以实时刷新绑定表中的记录。The records in the table can refresh the records in the binding table in real time according to the high and low level trigger mechanism of the switch (the low level of Port Down is triggered when the network cable is pulled out, and the high level of Port Up is triggered when the network cable is pulled in).

传统的DDoS攻击无法触及、修改Switch DPID和Switch Port的信息,利用此优势,可以更加灵活的检测欺骗攻击。Traditional DDoS attacks cannot touch or modify Switch DPID and Switch Port information. Taking advantage of this advantage, spoofing attacks can be detected more flexibly.

图4示出了破坏报文检测模块的工作流程图。Fig. 4 shows the working flow diagram of the damaged message detection module.

如图4所示,在所述IDS决策服务器中构建单位时间内的适于对报文的标志位设置异常行为进行计数的第二哈希表,以及设定该第二哈希表中的第二阀值;所述破坏报文检测模块对报文的各标志位进行检测,以判断各标志位是否符合TCP/IP协议规范;若报文的各标志位符合,则将报文转入异常报文检测模块;若报文的各标志位不符合,则转入所述IDS决策服务器,对报文进行丢弃,并同时对标志位设置异常行为进行计数,当该计数值超过第二阀值时,屏蔽发送该报文的程序和/或主机。As shown in Figure 4, the second hash table suitable for counting the abnormal behavior of the flag bit setting of the message is constructed in the IDS decision server in the unit time, and the first hash table in the second hash table is set. Two thresholds; the damaged message detection module detects each flag bit of the message to judge whether each flag bit meets the TCP/IP protocol specification; if each flag bit of the message meets, then the message is transferred to abnormal Message detection module; if each flag bit of the message does not meet, then transfer to the IDS decision server to discard the message, and simultaneously count the abnormal behavior of flag bit setting, when the count value exceeds the second threshold , block the program and/or host that sent the message.

具体的,所述破坏报文检测模块,用于对报文进行第二次判断,即判断报文是否为具有恶意标志位特征的攻击报文。其中,具有恶意标志位特征的攻击报文包括但不限于IP攻击报文、TCP攻击报文。实施步骤包括:对IP攻击报文及其中的TCP/UDP攻击报文实现各个报文的标志位的检测,即识别各标志位是否符合TCP/IP协议规范。如果符合的话,就直接交由异常数报文检测模块处理。若不符合,则判断为攻击报文,转入IDS决策服务器处理。Specifically, the damaged message detection module is used to perform a second judgment on the message, that is, to determine whether the message is an attack message with a malicious flag feature. Wherein, the attack packets with the characteristics of malicious flag bits include but not limited to IP attack packets and TCP attack packets. The implementation steps include: detecting the flag bits of each message for the IP attack message and the TCP/UDP attack message therein, that is, identifying whether each flag bit conforms to the TCP/IP protocol specification. If it matches, it will be directly handed over to the abnormal number packet detection module for processing. If not, it is judged as an attack packet and transferred to the IDS decision server for processing.

以Tear Drop等典型攻击为列,在IP包头中有一个偏移字段和一个分片标志(MF),若攻击者把偏移字段设置成不正确的值,IP分片报文就会出现重合或断开的情况,目标机系统就会崩溃。Taking typical attacks such as Tear Drop as an example, there is an offset field and a fragment flag (MF) in the IP packet header. If the attacker sets the offset field to an incorrect value, the IP fragments will overlap or disconnected, the target machine system will crash.

在IP报文头中,有一协议字段,该字段指明了该IP报文承载了何种协议。该字段的值是小于100的,如果攻击者向目标机发送大量的带大于100的协议字段的IP报文,目标机系统中的协议栈就会受到破坏,形成攻击。In the IP packet header, there is a protocol field, which indicates which protocol the IP packet carries. The value of this field is less than 100. If an attacker sends a large number of IP packets with a protocol field greater than 100 to the target computer, the protocol stack in the target computer system will be destroyed, forming an attack.

故在破坏报文检测模块中,首先提取出报文的各标志位,然后检查是否正常。Therefore, in the damaged message detection module, first extract the flag bits of the message, and then check whether it is normal.

如果正常,则交给后续模块处理。If it is normal, it will be handed over to the subsequent module for processing.

如果不正常,则丢弃该数据包,并对相应哈希表计数器计数。如果单位时间内计数器超过设定的所述第二阀值时,则调用IDS决策服务器对相应的程序进行屏蔽和/或直接屏蔽相应的主机。If it is not normal, the data packet is discarded, and the counter of the corresponding hash table is counted. If the counter exceeds the set second threshold per unit time, the IDS decision server is invoked to block the corresponding program and/or directly block the corresponding host.

通过欺骗报文检测模块的数据包滤除之后,后续的破坏报文检测模块所处理的数据包中的地址都是真实的。这样,有效的避免了目标机收到了破坏报文,可能直接导致目标机的协议栈崩溃,甚至目标机直接崩溃。After the data packets filtered by the fraudulent message detection module, the addresses in the subsequent data packets processed by the corrupted message detection module are all real. In this way, it is effectively avoided that the target machine receives a damaged message, which may directly lead to the collapse of the protocol stack of the target machine, or even the direct crash of the target machine.

破坏报文检测模块的处理功能与欺骗报文检测处理流程大致相似,区别在于破坏报文检测模块解析出的是各个报文的标志位,然后检测各个标志位是否正常。The processing function of the damaged message detection module is roughly similar to that of the spoofed message detection process, the difference is that the damaged message detection module parses out the flag bits of each message, and then checks whether each flag bit is normal.

如果正常的话,就直接给后续的异常报文检测模块处理。If it is normal, it is directly processed by the subsequent abnormal packet detection module.

如果不正常,则丢弃该数据包,并且对主机应用征信机制相应的哈希表内计数器计数。如果超过设定的阀值,则屏蔽相应的攻击程序或者直接屏蔽攻击主机。If it is not normal, the data packet is discarded, and the counter in the hash table corresponding to the credit checking mechanism is applied to the host to count. If it exceeds the set threshold, block the corresponding attack program or directly block the attack host.

在所述异常报文检测模块构建用于识别泛洪式攻击报文的哈希表,在所述IDS决策服务器中构建单位时间内的适于对泛洪式攻击行为进行计数的第三哈希表,以及设定该第三哈希表中的第三阀值;所述异常报文检测模块,适于根据所述哈希表中设定的阀值判断所述报文是否具有攻击行为;若无攻击行为,则将数据下发;若具有攻击行为,则转入所述IDS决策服务器,对报文进行丢弃,并同时对攻击行为进行计数,当计数值超过第三阀值时,屏蔽发送该报文的程序和/或主机。Build a hash table for identifying flood attack messages in the abnormal message detection module, and build a third hash suitable for counting flood attack behaviors per unit time in the IDS decision server table, and setting a third threshold in the third hash table; the abnormal message detection module is adapted to judge whether the message has an attack behavior according to the threshold set in the hash table; If there is no attack behavior, then send the data; if there is an attack behavior, then transfer to the IDS decision server, discard the message, and count the attack behavior at the same time, when the count value exceeds the third threshold, block The program and/or host that sent the message.

具体的,所述异常报文检测模块,用于对报文进行第三次判断,即判断报文是否是泛洪式攻击报文。Specifically, the abnormal message detection module is used to perform a third judgment on the message, that is, to determine whether the message is a flooding attack message.

具体步骤包括:利用对构建的识别泛洪式攻击报文的对哈希表内的相应记录进行累加,并检测是否超过阈值,以判断是否是泛洪式攻击报文。The specific steps include: accumulating the corresponding records in the hash table of the constructed identification flood attack message, and detecting whether it exceeds a threshold, so as to determine whether it is a flood attack message.

经过上述欺骗报文检测模块、破坏报文检测模块两个模块的滤除,后续模块处理的数据包基本属于正常情况下的数据包。然而,正常情况下,也会有DDoS攻击产生,在现有技术中,一般仅进行欺骗报文检测模块、破坏报文检测模块,而在本技术方案中,为了尽可能的避免DDoS攻击。After filtering by the above two modules of the fraudulent message detection module and the damaged message detection module, the data packets processed by the subsequent modules basically belong to the normal data packets. However, under normal circumstances, there will also be DDoS attacks. In the prior art, generally only the deceptive message detection module and the damaged message detection module are performed. In this technical solution, in order to avoid DDoS attacks as much as possible.

以下实施例对在进行欺骗报文检测模块、破坏报文检测模块过滤后,再通过异常报文检测模块屏蔽DDoS攻击的具体实施方式。该实施方式以UDP Flooding和ICMPFlooding为例。The following embodiments are specific implementations of shielding DDoS attacks through the abnormal message detection module after filtering by the fraudulent message detection module and the damaged message detection module. This implementation manner uses UDP Flooding and ICMPFlooding as examples.

图5示出了UDP Floodling的检测流程图。Fig. 5 shows a flow chart of UDP Floodling detection.

关于UDP Floodling,如图5所示,利用UDP协议无需建立连接的机制,向目标机发送大量UDP报文。目标机会花费大量的时间处理UDP报文,这些UDP攻击报文不但会使存放UDP报文的缓存溢出,而且也会占用大量的网络带宽,目标机无法(或很少)接收到合法的UDP报文。Regarding UDP Floodling, as shown in Figure 5, a large number of UDP packets are sent to the target machine using the mechanism of the UDP protocol without establishing a connection. The target machine spends a lot of time processing UDP packets. These UDP attack packets will not only overflow the buffer storing UDP packets, but also occupy a large amount of network bandwidth. The target machine cannot (or seldom) receive legitimate UDP packets. arts.

由于不同的主机向单一主机发送大量UDP数据包,所以肯定会有UDP端口占用的情况,所以本技术方案可以接收到一个ICMP的端口不可达包。Since different hosts send a large number of UDP data packets to a single host, there must be a situation that the UDP port is occupied, so this technical solution can receive an ICMP port unreachable packet.

所以本技术方案可以对所有主机建立一个哈希表,专门用来存放单位时间内收到ICMP端口不可达包的次数。如果超过设定的阀值,则直接屏蔽相应的攻击程序。Therefore, this technical solution can establish a hash table for all hosts, which is specially used to store the times of receiving ICMP port unreachable packets per unit time. If it exceeds the set threshold, the corresponding attack program will be blocked directly.

图6示出了ICMP Floodling的检测流程图。FIG. 6 shows a flow chart of ICMP Floodling detection.

关于ICMP Floodling,如图6所示,对于ICMP Flooding直接进行单位时间内计数。如果超过相应的阀值,则直接对相应主机进行相应屏蔽,该方法虽然简单,但是直接有效。With regard to ICMP Floodling, as shown in FIG. 6 , ICMP Flooding is directly counted per unit time. If the corresponding threshold value is exceeded, the corresponding host is directly shielded. Although this method is simple, it is direct and effective.

因此,异常报文检测模块,如果检测到的报文类型是异常报文检测类型,则进行相应的计数器检测是否超过阈值,如果没有超过阈值,也可对该数据包通过最优的路由策略下发。如果超过了阈值,则屏蔽相应的攻击程序,或直接对相应主机进行相应屏蔽。Therefore, the abnormal packet detection module, if the detected packet type is an abnormal packet detection type, then carry out the corresponding counter detection whether it exceeds the threshold value, if it does not exceed the threshold value, it can also pass the optimal routing strategy to the data packet. send. If the threshold is exceeded, the corresponding attack program is blocked, or the corresponding host is directly blocked accordingly.

所述欺骗报文检测模块、破坏报文检测模块和异常报文检测模块中任一模块判断所述报文为上述攻击报文时,则将该攻击报文转入IDS决策服务器,即,丢弃所述报文,并屏蔽发送该报文的程序和/或主机。When any module in the fraudulent message detection module, destruction message detection module and abnormal message detection module judges that the message is the above-mentioned attack message, then the attack message is transferred to the IDS decision server, that is, discarded said message, and block the program and/or host that sent the message.

当“欺骗报文检测模块”、“破坏报文检测模块”和“异常报文检测模块”需要丢弃数据包或者需要屏蔽威胁主机的时候。直接调用IDS决策服务器进行相应的威胁处理操作。When the "spoofed packet detection module", "destroyed packet detection module" and "abnormal packet detection module" need to discard data packets or shield threat hosts. Directly call the IDS decision server to perform corresponding threat processing operations.

所述IDS决策服务器的具体的实施步骤包括:The specific implementation steps of the IDS decision server include:

丢弃所述报文,即丢弃数据包的步骤包括如下:Discard described message, promptly the step of discarding data packet comprises as follows:

OpenFlow交换机在未匹配到相应的流表情况下,会将该数据包封装在Packet In消息中,同时交换机会将此数据包存在本地的缓存中,数据包存放在缓存中,有一个缓存区ID号,这个ID号也会封装在Packet In消息的buffer_id中,通过Packet out的形式,同时Packet out消息内的buffer_id填写要丢弃的数据包的缓存区ID(对应的Packet In消息中的buffer_id)。When the OpenFlow switch does not match the corresponding flow table, it will encapsulate the data packet in the Packet In message, and the switch will store the data packet in the local cache. The data packet is stored in the cache and has a cache area ID This ID number will also be encapsulated in the buffer_id of the Packet In message, in the form of Packet out, and the buffer_id in the Packet out message will fill in the buffer ID of the data packet to be discarded (the buffer_id in the corresponding Packet In message).

屏蔽主机的步骤包括如下:The steps to block a host include the following:

OpenFlow协议流表结构如下:The OpenFlow protocol flow table structure is as follows:

其中包头域的结构为:The structure of the header field is:

包头域header field 计数器counter 动作action

IDS决策服务器中包括对应用程序进行屏蔽的步骤包括如下:The steps of shielding the application program in the IDS decision server include the following:

步骤1:在流表的包头域中填写相应匹配字段,并且通过设置Wildcards屏蔽字段,来获取屏蔽攻击程序或主机信息。其中,如需屏蔽攻击程序,则在流表包头域中填写下列匹配字段:IP、MAC、VLAN、Swtich DPID、Swtich Port、协议类型及其端口号等。如需屏蔽主机,则在流表包头域中填写:IP、MAC、VLAN、Swtich DPID、Swtich Port等匹配字段。Step 1: Fill in the corresponding matching field in the packet header field of the flow table, and obtain the shielded attack program or host information by setting the Wildcards shielded field. Among them, if it is necessary to shield the attack program, fill in the following matching fields in the header field of the flow table: IP, MAC, VLAN, Switch DPID, Switch Port, protocol type and its port number, etc. If you need to shield the host, fill in the flow table header field: IP, MAC, VLAN, Swtich DPID, Swtich Port and other matching fields.

步骤2:将流表动作列表置空,实现攻击程序/主机的数据包丢弃。Step 2: Set the action list of the flow table to empty to realize the packet discarding of the attacking program/host.

步骤3:调用各哈希表中的记录值,计算出流表超时自动删除时间。Step 3: Invoke the record values in each hash table to calculate the automatic deletion time when the flow table expires.

步骤4:下发流表屏蔽程序或主机。Step 4: Deliver the flow table masking program or host.

因此,本技术方案的网络可有效识别并滤除攻击包。Therefore, the network of the technical solution can effectively identify and filter out attack packets.

可选的,在经过上述各模块之后,将正常报文的实时最优路由策略的下发。Optionally, after passing through the above modules, the real-time optimal routing policy of the normal message is issued.

具体步骤如下:Specific steps are as follows:

首先进入步骤S1来向控制器的拓扑接口(API)提交获取请求,然后通过步骤S2来获取全网拓扑。First enter step S1 to submit an acquisition request to the topology interface (API) of the controller, and then acquire the whole network topology through step S2.

然后,通过进行全网链路状态的获取。首先进入步骤S3,然后通过步骤S10来获取全网链路状态,然后计算出全网链路剩余带宽。Then, obtain the link status of the whole network. First enter step S3, then obtain the link status of the whole network through step S10, and then calculate the remaining bandwidth of the link of the whole network.

然后就是实时最优路径的计算,算法采用经典的Dijkstra算法,算法的权值改为上一步获取的全网链路剩余带宽的倒数,这样就能保证计算出的路径是最通畅,传输时延最小的路径。(最优路径的具体算法参见实施例3中相关内容)Then there is the calculation of the real-time optimal path. The algorithm uses the classic Dijkstra algorithm, and the weight of the algorithm is changed to the reciprocal of the remaining bandwidth of the entire network link obtained in the previous step, so as to ensure that the calculated path is the smoothest and has the lowest transmission delay. the smallest path. (For the specific algorithm of the optimal path, refer to the relevant content in Embodiment 3)

最后,将计算出的最优路径转换成由流表组成的实时最优路径策略,通过步骤S11下发。Finally, the calculated optimal path is converted into a real-time optimal path strategy composed of flow tables, which is delivered through step S11.

步骤S1使用的是拓扑接口,一种控制器自带的API接口,使用LLDP(链路层发现协议)和广播包发现链路,然后控制器自动计算出网络拓扑。Step S1 uses a topology interface, a kind of API interface provided by the controller, which uses LLDP (Link Layer Discovery Protocol) and broadcast packets to discover links, and then the controller automatically calculates the network topology.

步骤S2控制器的拓扑接口向“实时最优路径计算模块”的“全网拓扑获取模块”拓扑获取请求的反馈。Step S2: The topology interface of the controller sends feedback of the topology acquisition request to the "whole network topology acquisition module" of the "real-time optimal path calculation module".

步骤S3中,“全网链路状态获取模块”向“交换机查询接口模块”提出请求,获取全网链路状态。其中,“交换机查询接口模块”是在控制器自带的“交换机特性查询模块”和“交换机状态查询模块”基础上拓展而来,实现了链路剩余带宽的计算及查询功能。In step S3, the "network-wide link status acquisition module" sends a request to the "switch query interface module" to acquire the link status of the whole network. Among them, the "switch query interface module" is expanded on the basis of the "switch feature query module" and "switch status query module" that come with the controller, and realizes the calculation and query functions of the remaining bandwidth of the link.

然后,“交换机查询模块”通过步骤S4向网络中所有交换机发送交换机特性请求的广播包。再通过步骤S5来接收来自网络中交换机特性反馈的报文,解析出报文里面的curr字段,得到每个交换机端口当前带宽B。Then, the "switch query module" sends a switch characteristic request broadcast packet to all switches in the network through step S4. Then step S5 is used to receive the message from the switch characteristic feedback in the network, parse out the curr field in the message, and obtain the current bandwidth B of each switch port.

接下来,该模块通过步骤S6向网络中所有交换机发送交换机状态请求的广播包,包括端口发送包数、端口发送字节数、端口接收字节数、端口接收包数等报文状态。接着,该模块通过步骤S7接收来自网络中交换机状态反馈的报文,解析出tx_bytes字段,得到发送字节数N1,获取当前时间t1。Next, the module sends broadcast packets of switch status requests to all switches in the network through step S6, including message statuses such as the number of packets sent by the port, the number of bytes sent by the port, the number of bytes received by the port, and the number of packets received by the port. Next, the module receives the message from the status feedback of the switch in the network through step S7, parses out the tx_bytes field, obtains the number of sent bytes N1, and obtains the current time t1.

接下来,该模块通过步骤S8向网络中所有交换机发送交换机状态请求的广播包,接着,该模块通过S9接收来自网络中交换机状态反馈的报文,计时停止,获取当前时间t2。解析出tx_bytes字段,得到发送字节数N2。Next, the module sends a switch state request broadcast packet to all switches in the network through step S8, and then, through S9, the module receives a message from the switch state feedback in the network, stops timing, and obtains the current time t2. Parse the tx_bytes field to get the number of sent bytes N2.

则可以计算出当前端口剩余带宽为:B-(N2-N1)/(t2-t1)。Then the remaining bandwidth of the current port can be calculated as: B-(N2-N1)/(t2-t1).

然后,再利用获取的网络拓扑进行每条链路的剩余带宽计算:Then, use the obtained network topology to calculate the remaining bandwidth of each link:

若是交换机与交换机之间的连接,则获取该条链路两端的交换机端口的剩余带宽,该链路的剩余带宽为两个端口剩余带宽中的较小者。If it is a connection between switches, obtain the remaining bandwidth of the switch ports at both ends of the link, where the remaining bandwidth of the link is the smaller of the remaining bandwidths of the two ports.

如果是主机与交换机之间的连接,则获取连接主机的交换机端口的剩余带宽,该条链路剩余带宽即为连接该主机的交换机端口剩余带宽。If it is a connection between a host and a switch, the remaining bandwidth of the switch port connected to the host is obtained, and the remaining bandwidth of the link is the remaining bandwidth of the switch port connected to the host.

步骤S4控制器以广播的形式向全网所有交换机发送Feature Request消息。Step S4 The controller sends a Feature Request message to all switches in the whole network in the form of broadcast.

步骤S5控制器接收来自网络中交换机反馈给控制器的Feature Reply消息。Step S5 The controller receives the Feature Reply message fed back to the controller from the switches in the network.

步骤S6控制器以广播的形式向全网所有交换机发送Stats Request消息。In step S6, the controller sends a Stats Request message to all switches in the whole network in the form of broadcast.

步骤S7控制器接收来自网络中交换机反馈给控制器的Stats Reply消息。Step S7 The controller receives the Stats Reply message fed back to the controller from the switches in the network.

步骤S8控制器以广播的形式向全网所有交换机发送Stats Request消息。Step S8 The controller sends a Stats Request message to all switches in the whole network in the form of broadcast.

步骤S9控制器接收来自网络中交换机反馈给控制器的Stats Reply消息。Step S9 The controller receives the Stats Reply message fed back to the controller from the switch in the network.

步骤S10交换机查询接口将计算出的链路剩余带宽信息反馈给“全网链路状态获取模块”。Step S10: The switch query interface feeds back the calculated remaining link bandwidth information to the "network-wide link status acquisition module".

步骤S11路由策略下发模块计算出的实时最优路由策略,将计算出的流表通过步骤S12来下发给相关的交换机。Step S11: The real-time optimal routing policy calculated by the routing policy delivery module, and the calculated flow table is delivered to the relevant switch through step S12.

步骤S12该接口是控制器自带的API接口,用于下发计算出的最优路由策略。Step S12, the interface is an API interface provided by the controller, and is used to deliver the calculated optimal routing policy.

通过所述最优路径策略是在防御DDOS攻击的同时,网络的平均传输延时并没有激增。Through the optimal path strategy, while defending against DDOS attacks, the average transmission delay of the network does not increase sharply.

实施例3Example 3

在实施例1和实施例2基础上的一种集威胁处理和路由优化于一体的SDN系统的工作方法,以通过分布式的检测和集中式的处理,有效的减轻了控制器的工作负担,提高了检测效率和数据传输率。Based on Embodiment 1 and Embodiment 2, a working method of an SDN system that integrates threat processing and routing optimization can effectively reduce the workload of the controller through distributed detection and centralized processing. Improved detection efficiency and data transfer rate.

本发明的集威胁处理和路由优化于一体的SDN系统的工作方法,包括如下步骤:The working method of the SDN system integrating threat processing and routing optimization of the present invention comprises the following steps:

步骤S100,网络初始化;步骤S200,分布式DDoS威胁监测;以及步骤S300,威胁处理和/或路由优化。Step S100, network initialization; Step S200, distributed DDoS threat monitoring; and Step S300, threat processing and/or route optimization.

进一步,所述步骤S100中网络初始化所涉及的装置包括:控制器、IDS决策服务器和分布式的IDS设备;Further, the devices involved in network initialization in step S100 include: a controller, an IDS decision server and distributed IDS devices;

网络初始化的步骤如下:The steps of network initialization are as follows:

步骤S101,所述IDS决策服务器与各IDS设备建立专用的SSL通信信道(该步骤S101为可选的实施方案);步骤S102,所述控制器构建网络设备信息绑定表,并且将网络设备信息绑定表实时更新到各IDS设备中;步骤S104,所述控制器下发镜像策略的流表,即将OF交换机所有拖载有主机的端口流量镜像转发给网域内对应的IDS设备;以及步骤S105,所述控制器下发DDoS威胁识别规则给每个网域中对应的各IDS设备。Step S101, the IDS decision server establishes a dedicated SSL communication channel with each IDS device (this step S101 is an optional implementation); step S102, the controller builds a network device information binding table, and the network device information The binding table is updated in each IDS device in real time; step S104, the controller issues the flow table of the mirroring strategy, that is, forwards all port traffic mirroring of the host towed by the OF switch to the corresponding IDS device in the network domain; and step S105 , the controller delivers DDoS threat identification rules to corresponding IDS devices in each network domain.

所述步骤S200中分布式DDoS威胁监测的方法包括:依次对链路层和网际层地址的欺骗行为,网际层和传输层标志位设置异常行为,以及应用层和传输层的泛洪式攻击行为进行检测;若上述过程中任一检测判断出报文存在相应行为时,则将该报文转入步骤S300。The method for distributed DDoS threat monitoring in the step S200 includes: sequentially spoofing the address of the link layer and the Internet layer, setting abnormal behaviors of the flag bits of the Internet layer and the transport layer, and flooding attack behaviors of the application layer and the transport layer Perform detection; if any detection in the above process determines that the message has a corresponding behavior, then the message is transferred to step S300.

具体的实施步骤包括:The specific implementation steps include:

步骤S210,对链路层和网际层地址的欺骗行为进行检测。Step S210, detecting spoofing behavior of link layer and Internet layer addresses.

步骤S220,对网际层和传输层标志位设置的异常行为进行检测。Step S220, detecting the abnormal behavior of the flag bit settings of the Internet layer and the transport layer.

步骤S230,对应用层和传输层的泛洪式攻击行为进行检测。Step S230, detecting the flood attack behavior of the application layer and the transport layer.

步骤S240,若将报文依次通过所述步骤S210、步骤S220、步骤S230后,任一步骤判断出报文存在欺骗、异常、攻击行为时,则将所述报文转入步骤S300。Step S240, if after the message passes through the steps S210, S220, and S230 in sequence, and any step determines that the message has fraudulent, abnormal, or attacking behaviors, then transfer the message to step S300.

所述步骤S210中对链路层和网际层地址的欺骗行为进行检测的方法包括如下步骤:步骤S211,通过欺骗报文检测模块调用网络设备信息绑定表;步骤S212,通过欺骗报文检测模块将封装在Packet-In消息中报文的类型进行解析,以获得相应的源、目的IP地址、MAC地址以及上传此Packet-In消息的交换机DPID号和端口号,并将上述各信息分别与网络设备信息绑定表中的相应信息进行比对;若报文中的上述信息匹配,则将报文转入步骤S220;若报文中的上述信息不匹配,则将报文转入步骤S300。The method for detecting the spoofing of the link layer and the Internet layer address in the step S210 includes the following steps: Step S211, calling the network device information binding table by the fraudulent message detection module; Step S212, passing the fraudulent message detection module Analyze the type of message encapsulated in the Packet-In message to obtain the corresponding source, destination IP address, MAC address, and the DPID number and port number of the switch that uploaded the Packet-In message, and share the above information with the network Compare the corresponding information in the device information binding table; if the above information in the message matches, then transfer the message to step S220; if the above information in the message does not match, then transfer the message to step S300.

所述步骤S220中对网际层和传输层标志位设置异常行为进行检测的方法包括:对报文的各标志位进行检测,以判断各标志位是否符合TCP/IP协议规范;若报文的各标志位符合,则将报文转入S230;若报文的各标志位不符合,则将报文转入步骤S300。In the step S220, the method for detecting the abnormal behavior of the Internet layer and the transport layer flag bit setting includes: detecting each flag bit of the message to judge whether each flag bit meets the TCP/IP protocol specification; if each flag bit of the message If the flag bits match, the message is transferred to step S230; if the flag bits of the message are not matched, the message is transferred to step S300.

所述步骤S230中对应用层和传输层的泛洪式攻击行为进行检测的方法包括如下步骤:步骤S231,在异常报文检测模块构建用于识别泛洪式攻击报文的哈希表;步骤S232,通过异常报文检测模块根据所述哈希表中设定的阀值判断所述报文是否为泛洪式攻击报文,且将判断结果转入步骤S300,即若无攻击行为,则将数据正常下发或通过上述最优路径策略下发;若具有攻击行为,则采取相应的屏蔽措施。The method for detecting the flood attack behavior of the application layer and the transport layer in the step S230 includes the following steps: step S231, constructing a hash table for identifying flood attack messages in the abnormal message detection module; step S232, judge whether the message is a flood attack message by the abnormal message detection module according to the threshold set in the hash table, and transfer the judgment result to step S300, that is, if there is no attack behavior, then Send the data normally or through the above-mentioned optimal path strategy; if there is an attack behavior, take corresponding shielding measures.

所述步骤S300中威胁处理和/或路由优化的方法包括:The method for threat handling and/or route optimization in step S300 includes:

若报文具有欺骗行为,且攻击威胁在OpenFlow域中,则所述IDS决策服务器适于通过控制器屏蔽主机;以及当攻击威胁不在OpenFlow域中,则通过控制器将该报文所对应的交换机接入端口流量重定向至流量清洗中心进行过滤;If the message has deceptive behavior, and the attack threat is in the OpenFlow domain, then the IDS decision server is suitable for shielding the host through the controller; and when the attack threat is not in the OpenFlow domain, then the switch corresponding to the message is Access port traffic is redirected to the traffic cleaning center for filtering;

若报文具有异常行为,则所述IDS决策服务器通过控制器对攻击程序或攻击主机的流量进行屏蔽;具体的实施步骤包括:针对破坏报文攻击,由于IDS设备当前处理的报文通过了欺骗报文检测,所以该报文地址是真实的。IDS决策服务器只需通过控制器的北向接口下发动作为Drop的流表将攻击程序或攻击主机的流量屏蔽。但这都只是粗粒度的决策,只适用于攻击包少量的破坏报文攻击。If the message has an abnormal behavior, the IDS decision server shields the flow of the attack program or the attack host through the controller; the specific implementation steps include: for destroying the message attack, because the message currently processed by the IDS device has passed the deception Packet detection, so the packet address is real. The IDS decision server only needs to launch a drop flow table under the northbound interface of the controller to block the traffic of the attacking program or attacking host. But these are only coarse-grained decisions, which are only applicable to a small amount of packet destruction attacks.

若报文具有泛洪式攻击行为,则所述IDS决策服务器通过控制器将该报文所对应的交换机接入端口流量重定向至流量清洗中心进行过滤;可选的,流量清洗中心的安全设备也可以将防护的结果反馈给控制器,调整网络策略,实现SDN网络以及混合有传统网络情况下的多维防护。If the message has a flooding attack behavior, the IDS decision server redirects the traffic of the switch access port corresponding to the message to the traffic cleaning center through the controller for filtering; optionally, the security device in the traffic cleaning center The protection results can also be fed back to the controller to adjust the network strategy to realize multi-dimensional protection in the case of SDN network and traditional network.

进一步,根据链路负载系数计算出优化路径,即检测两相邻节点的链路剩余带宽,获得该链路的负载系数,在根据该负载系数和初始化的网络拓扑图获得任意两点的最优路径,所述控制器根据该最优路径得出对应的转发流表并下发各交换机。Further, the optimal path is calculated according to the link load factor, that is, the remaining link bandwidth of two adjacent nodes is detected, the load factor of the link is obtained, and the optimal path of any two points is obtained according to the load factor and the initialized network topology map. path, the controller obtains a corresponding forwarding flow table according to the optimal path and issues it to each switch.

优化路径的具体算法流程如下:The specific algorithm flow of the optimization path is as follows:

所述IDS决策服务器屏蔽发送报文的程序和/或主机的方法包括:The method for the IDS decision server to shield the program and/or host that sends the message includes:

首先,构建计数用的相应哈希表及设定相应阈值,即First, build the corresponding hash table for counting and set the corresponding threshold, namely

单位时间内,所述IDS决策服务器中构建对欺骗行为进行计数的第一哈希表,标志位设置异常行为进行计数的第二哈希表,以及对泛洪式攻击行为进行计数的第三哈希表;Within a unit time, the IDS decision server constructs a first hash table for counting fraudulent behaviors, a second hash table for counting abnormal behaviors with flag bits set, and a third hash table for counting flooding attack behaviors. Greek table;

同时设定第一、第二、第三哈希表中的第一、第二、第三阀值;Simultaneously set the first, second, and third thresholds in the first, second, and third hash tables;

其次,屏蔽发送该报文的程序和/或主机,即Second, block the program and/or host that sent the message, i.e.

针对转入IDS决策服务器的报文的行为,利用相应哈希表进行计数,当计数值超过相应阀值时,屏蔽发送该报文的程序和/或主机。For the behavior of the message transferred to the IDS decision server, use the corresponding hash table to count, and when the count value exceeds the corresponding threshold, block the program and/or host that sent the message.

实施例4Example 4

本发明的SDN架构和系统可以定义SDNQA(SDN Communication QualityAssurance Strategy)即SDN通信质量保障策略。The SDN architecture and system of the present invention can define SDNQA (SDN Communication Quality Assurance Strategy), that is, an SDN communication quality assurance strategy.

目标设计与场景部署相关测试。Tests related to target design and scenario deployment.

本发明已进行了部署和测试,主要测试环境和测试内容如下:The present invention has been deployed and tested, and the main test environment and test contents are as follows:

(1)基于OpenFlow 1.3协议,测试装有DDoS威胁过滤与通信质量保障组件的Floodlight控制器、OF交换机、IDS设备以及IDS决策服务器之间的通信。(1) Based on the OpenFlow 1.3 protocol, test the communication between the Floodlight controller, OF switch, IDS device and IDS decision server equipped with DDoS threat filtering and communication quality assurance components.

(2)测试IDS设备是否能够实时监测网络中的异常攻击流量,并且通过SSL通信信道上报IDS决策服务器。(2) Test whether the IDS device can monitor the abnormal attack traffic in the network in real time, and report to the IDS decision server through the SSL communication channel.

(3)测试IDS决策服务器是否能够根据IDS设备上报的信息,制定出处理对应攻击威胁的策略,并通过控制器的北向接口下发。(3) Test whether the IDS decision server can formulate a strategy to deal with the corresponding attack threat according to the information reported by the IDS device, and issue it through the northbound interface of the controller.

(4)测试控制器是否能够根据网络实时状况,生成并下发实时优化的转发路径,提升用户体验。(4) Test whether the controller can generate and deliver real-time optimized forwarding paths according to the real-time network conditions to improve user experience.

实验场景的具体部署。中间为基础网络区域,有两个虚网。其中虚网A部署了本SDNQA系统,而虚网B尚未部署,并且各虚网中都存在若干DDoS攻击傀儡机。右侧为实验效果对比区域,包括一台Web服务器和两台用户主机,其中Web服务器上运行Tomcat对外提供Web服务,用户主机A、B分别是接入虚网A、B的主机。左侧为攻击模拟区域,有一台DDoS攻击机,攻击机将作为主控机控制虚网A和虚网B中的傀儡机对Web服务器发起混合式的DDoS攻击。The specific deployment of the experimental scene. The middle is the basic network area, and there are two virtual networks. Among them, virtual network A has deployed the SDNQA system, but virtual network B has not been deployed, and there are several DDoS attack puppets in each virtual network. The right side is the experimental effect comparison area, including a web server and two user hosts, where Tomcat runs on the web server to provide web services to the outside world, and user hosts A and B are hosts connected to virtual networks A and B respectively. The left side is the attack simulation area. There is a DDoS attack machine, which will act as the master control machine to control the puppet machines in virtual network A and virtual network B to launch hybrid DDoS attacks on the web server.

基于上述实验环境,从两方面对SDNQA架构的性能进行验证:(1)对比混合式的DDoS攻击下Web服务器端所承受的攻击频率;(2)对比泛洪式攻击所造成的网络平均传输延迟。Based on the above experimental environment, the performance of the SDNQA architecture is verified from two aspects: (1) comparing the attack frequency of the Web server under the hybrid DDoS attack; (2) comparing the average network transmission delay caused by the flooding attack .

首先,对Web服务器端流量流入情况进行分析。攻击机控制各虚网中的傀儡机同时对Web服务器发起混合式的DDoS攻击,其最高频率为55Hz,攻击时长为100秒。截取Web服务器所有的数据包序列,并分离出各虚网的请求序列,分别得出虚网A和虚网B所流入服务器的请求序列,Web服务器所承受的攻击频率对比。First, analyze the flow inflow of the web server. The attacking machine controls the puppet machines in each virtual network and launches a hybrid DDoS attack on the web server at the same time, the highest frequency is 55Hz, and the attack duration is 100 seconds. Intercept all the data packet sequences of the web server, and separate the request sequences of each virtual network, respectively obtain the request sequences of virtual network A and virtual network B flowing into the server, and compare the attack frequency of the web server.

可以看出,SDNQA系统在0s~5s时间段内快速识别了典型的DDoS攻击,并在0s~40s的时间段内采取了过滤防护措施。在40s之后,网络流量趋于正常,测试用户主机A一直可正常得到网页请求响应。而未部署SDNQA系统的虚网B中一直有大量的攻击流量流入,测试用户主机B无法得到网页请求响应。It can be seen that the SDNQA system quickly identified typical DDoS attacks within the time period of 0s to 5s, and took filtering protection measures within the time period of 0s to 40s. After 40 seconds, the network traffic tends to be normal, and the test user host A can always get the webpage request response normally. However, there has been a large amount of attack traffic flowing in the virtual network B where the SDNQA system is not deployed, and the test user host B cannot get a response to the web page request.

其次,我们从之前截取的数据包序列中提取出测试用户主机A和测试用户主机B的请求序列,从各请求序列中统计数据包的平均传输的延迟时间,得出两个虚网的平均传输延时对比。Secondly, we extract the request sequence of test user host A and test user host B from the previously intercepted data packet sequence, and calculate the average transmission delay time of data packets from each request sequence to obtain the average transmission of the two virtual networks Latency comparison.

可以看出,经过路由优化,虚网A的平均传输延迟没有随着数据量的增大而激增。由此可见,SDNQA架构能够基于对网络实时状况的感知,对流转发路径进行优化,从而在网络中存在DDoS攻击或正常大流量业务的情况下保证最佳用户体验。It can be seen that after routing optimization, the average transmission delay of virtual network A does not increase sharply with the increase of data volume. It can be seen that the SDNQA architecture can optimize the flow forwarding path based on the perception of real-time network conditions, so as to ensure the best user experience in the case of DDoS attacks or normal large-traffic services in the network.

应当理解的是,本发明的上述具体实施方式仅仅用于示例性说明或解释本发明的原理,而不构成对本发明的限制。因此,在不偏离本发明的精神和范围的情况下所做的任何修改、等同替换、改进等,均应包含在本发明的保护范围之内。此外,本发明所附权利要求旨在涵盖落入所附权利要求范围和边界、或者这种范围和边界的等同形式内的全部变化和修改例。It should be understood that the above specific embodiments of the present invention are only used to illustrate or explain the principle of the present invention, and not to limit the present invention. Therefore, any modification, equivalent replacement, improvement, etc. made without departing from the spirit and scope of the present invention shall fall within the protection scope of the present invention. Furthermore, it is intended that the appended claims of the present invention embrace all changes and modifications that come within the scope and metesques of the appended claims, or equivalents of such scope and metes and bounds.

Claims (1)

  1. A kind of 1. SDN framework, it is characterised in that including:Datum plane, using plane and control plane;Wherein
    Datum plane, when any IDS equipment detects the message of ddos attack feature in datum plane, that is, pass through SSL Communication channel is reported to using plane;
    Using plane, for analyzing attack type, and corresponding attack is customized according to attack type and threatens processing strategy;
    Control plane, for using plane provides attack threat Processing Interface, and for datum plane provide optimal path computation and/or Attack threat identification interface;
    Include in the IDS equipment:
    Packet check module is cheated, the deceptive practices to link layer and internet layer address detect;
    Packet check module is destroyed, the abnormal behaviour set to internetwork layer and transport layer flag bit detects;
    Exception message detection module, the formula attack that flooded to application layer and transport layer detect;
    By the deception packet check module, packet check module, exception message detection module are destroyed successively to message progress Detection;And if the message is transferred to using plane when above-mentioned respective behavior be present by any detection module detection outgoing packet;
    The application plane is attacked and threatened in OpenFlow domains suitable for having deceptive practices when message, then is put down by controlling Controller shielding main frame in face;Or threatened when attacking not in OpenFlow domains, then by controller by corresponding to the message Interchanger access interface flow be redirected to flow cleaning center and filtered;
    The application plane is further adapted for having abnormal behaviour when message, then to attacker or attacks the stream of main frame by controller Amount is shielded;And
    Flooded formula attack when message has, then it is described using plane be suitable to by controller by the message corresponding to exchange Machine access interface flow is redirected to flow cleaning center and filtered.
CN201410788069.5A 2014-12-17 2014-12-17 It is a kind of to integrate the SDN frameworks and method of work for threatening processing and routing optimality Expired - Fee Related CN104539595B (en)

Priority Applications (4)

Application Number Priority Date Filing Date Title
CN201711302091.4A CN107786578A (en) 2014-12-17 2014-12-17 Suitable for solving the SDN frameworks and method of work of network security problem
CN201711302100.XA CN107888619A (en) 2014-12-17 2014-12-17 Integrate the method for work for the SDN systems for threatening processing and routing optimality
CN201711302098.6A CN107888618A (en) 2014-12-17 2014-12-17 The DDoS for solving network security threatens the method for work of filtering SDN systems
CN201410788069.5A CN104539595B (en) 2014-12-17 2014-12-17 It is a kind of to integrate the SDN frameworks and method of work for threatening processing and routing optimality

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410788069.5A CN104539595B (en) 2014-12-17 2014-12-17 It is a kind of to integrate the SDN frameworks and method of work for threatening processing and routing optimality

Related Child Applications (3)

Application Number Title Priority Date Filing Date
CN201711302098.6A Division CN107888618A (en) 2014-12-17 2014-12-17 The DDoS for solving network security threatens the method for work of filtering SDN systems
CN201711302091.4A Division CN107786578A (en) 2014-12-17 2014-12-17 Suitable for solving the SDN frameworks and method of work of network security problem
CN201711302100.XA Division CN107888619A (en) 2014-12-17 2014-12-17 Integrate the method for work for the SDN systems for threatening processing and routing optimality

Publications (2)

Publication Number Publication Date
CN104539595A CN104539595A (en) 2015-04-22
CN104539595B true CN104539595B (en) 2018-04-10

Family

ID=52855064

Family Applications (4)

Application Number Title Priority Date Filing Date
CN201711302100.XA Withdrawn CN107888619A (en) 2014-12-17 2014-12-17 Integrate the method for work for the SDN systems for threatening processing and routing optimality
CN201410788069.5A Expired - Fee Related CN104539595B (en) 2014-12-17 2014-12-17 It is a kind of to integrate the SDN frameworks and method of work for threatening processing and routing optimality
CN201711302098.6A Withdrawn CN107888618A (en) 2014-12-17 2014-12-17 The DDoS for solving network security threatens the method for work of filtering SDN systems
CN201711302091.4A Withdrawn CN107786578A (en) 2014-12-17 2014-12-17 Suitable for solving the SDN frameworks and method of work of network security problem

Family Applications Before (1)

Application Number Title Priority Date Filing Date
CN201711302100.XA Withdrawn CN107888619A (en) 2014-12-17 2014-12-17 Integrate the method for work for the SDN systems for threatening processing and routing optimality

Family Applications After (2)

Application Number Title Priority Date Filing Date
CN201711302098.6A Withdrawn CN107888618A (en) 2014-12-17 2014-12-17 The DDoS for solving network security threatens the method for work of filtering SDN systems
CN201711302091.4A Withdrawn CN107786578A (en) 2014-12-17 2014-12-17 Suitable for solving the SDN frameworks and method of work of network security problem

Country Status (1)

Country Link
CN (4) CN107888619A (en)

Families Citing this family (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017035717A1 (en) * 2015-08-29 2017-03-09 华为技术有限公司 Distributed denial of service attack detection method and associated device
CN105610854B (en) * 2016-01-18 2019-08-06 上海交通大学 A Network Collaborative Defense System
CN105897750A (en) * 2016-06-03 2016-08-24 中国电子科技集团公司第三十研究所 Method and system for defending Dos attacks of SDN controller
JP6898846B2 (en) * 2017-12-28 2021-07-07 株式会社日立製作所 Abnormal cause identification support system and abnormal cause identification support method
CN108289104B (en) * 2018-02-05 2020-07-17 重庆邮电大学 An industrial SDN network DDoS attack detection and mitigation method
US10659484B2 (en) 2018-02-19 2020-05-19 Cisco Technology, Inc. Hierarchical activation of behavioral modules on a data plane for behavioral analytics
CN109508435A (en) * 2018-10-26 2019-03-22 张派瑞 A kind of anti-network bullying and humiliation method
CN109922048B (en) * 2019-01-31 2022-04-19 国网山西省电力公司长治供电公司 A serial distributed hidden threat intrusion attack detection method and system
CN111181910B (en) * 2019-08-12 2021-10-08 腾讯科技(深圳)有限公司 Protection method and related device for distributed denial of service attack
CN111885092A (en) * 2020-09-10 2020-11-03 中国联合网络通信集团有限公司 An edge node DDoS attack detection method, processing method and SDN
CN114726602A (en) * 2022-03-29 2022-07-08 中国工程物理研究院计算机应用研究所 Self-adaptive threat blocking method for enterprise intranet under network zero change condition

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102487339A (en) * 2010-12-01 2012-06-06 中兴通讯股份有限公司 Attack preventing method for network equipment and device
CN103561011A (en) * 2013-10-28 2014-02-05 中国科学院信息工程研究所 Method and system for preventing blind DDoS attacks on SDN controllers
CN104023034A (en) * 2014-06-25 2014-09-03 武汉大学 Security defensive system and defensive method based on software-defined network

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9392010B2 (en) * 2011-11-07 2016-07-12 Netflow Logic Corporation Streaming method and system for processing network metadata

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102487339A (en) * 2010-12-01 2012-06-06 中兴通讯股份有限公司 Attack preventing method for network equipment and device
CN103561011A (en) * 2013-10-28 2014-02-05 中国科学院信息工程研究所 Method and system for preventing blind DDoS attacks on SDN controllers
CN104023034A (en) * 2014-06-25 2014-09-03 武汉大学 Security defensive system and defensive method based on software-defined network

Also Published As

Publication number Publication date
CN104539595A (en) 2015-04-22
CN107888618A (en) 2018-04-06
CN107888619A (en) 2018-04-06
CN107786578A (en) 2018-03-09

Similar Documents

Publication Publication Date Title
CN104539594B (en) Merge DDoS and threaten filtering and SDN frameworks, system and the method for work of routing optimality
CN104660582B (en) The network architecture of the software definition of DDoS identifications, protection and path optimization
CN104539595B (en) It is a kind of to integrate the SDN frameworks and method of work for threatening processing and routing optimality
CN104539625B (en) Network security defense system based on software definition and working method thereof
CN104378380A (en) System and method for identifying and preventing DDoS attacks on basis of SDN framework
CN108737447B (en) User datagram protocol flow filtering method, device, server and storage medium
US20190132360A1 (en) Honeynet method, system and computer program for mitigating link flooding attacks of software defined network
US9166990B2 (en) Distributed denial-of-service signature transmission
KR100882809B1 (en) Distributed denial of service attack defense system and method based on flow-based packet processing
Rengaraju et al. Detection and prevention of DoS attacks in Software-Defined Cloud networks
WO2002021278A1 (en) Coordinated thwarting of denial of service attacks
WO2002021296A1 (en) Statistics collection for network traffic
CN104468636A (en) SDN structure for DDoS threatening filtering and link reallocating and working method
CN108028828B (en) A distributed denial of service DDoS attack detection method and related equipment
Jiang et al. BSD‐Guard: A Collaborative Blockchain‐Based Approach for Detection and Mitigation of SDN‐Targeted DDoS Attacks
Dang-Van et al. A multi-criteria based software defined networking system Architecture for DDoS-attack mitigation
CN105871773A (en) DDoS filtering method based on SDN network architecture
Huang et al. FSDM: Fast recovery saturation attack detection and mitigation framework in SDN
CN107864110A (en) Botnet main control end detection method and device
JP5178573B2 (en) Communication system and communication method
CN105871772A (en) Working method of SDN network architecture aimed at network attack
CN105871771A (en) SDN network architecture aimed at DDoS network attack
US8281400B1 (en) Systems and methods for identifying sources of network attacks
CN118432912A (en) A link flooding attack defense method based on selective real-time rerouting
KR100733830B1 (en) Distributed Denial of Service Attack Detection and Response in Broadband Networks

Legal Events

Date Code Title Description
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
CB03 Change of inventor or designer information
CB03 Change of inventor or designer information

Inventor after: Shi Yukai

Inventor after: Yang Zhongxue

Inventor after: Chen Fei

Inventor after: Zhang Jiahua

Inventor after: Wang Jiangping

Inventor after: Li Ying

Inventor after: Ou Jiahao

Inventor before: Shi Yukai

Inventor before: Zhang Jiahua

Inventor before: Yang Zhongxue

Inventor before: Wang Jiangping

Inventor before: Li Ying

GR01 Patent grant
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20180410

Termination date: 20201217