CN109218224A - A kind of efficient and expansible IP data packet classification method - Google Patents

A kind of efficient and expansible IP data packet classification method Download PDF

Info

Publication number
CN109218224A
CN109218224A CN201811229945.5A CN201811229945A CN109218224A CN 109218224 A CN109218224 A CN 109218224A CN 201811229945 A CN201811229945 A CN 201811229945A CN 109218224 A CN109218224 A CN 109218224A
Authority
CN
China
Prior art keywords
data packet
expansible
efficient
packet classification
bit
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.)
Pending
Application number
CN201811229945.5A
Other languages
Chinese (zh)
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.)
Nanchang Career Academy
Original Assignee
王瑶生
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 王瑶生 filed Critical 王瑶生
Priority to CN201811229945.5A priority Critical patent/CN109218224A/en
Publication of CN109218224A publication Critical patent/CN109218224A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/24Traffic characterised by specific attributes, e.g. priority or QoS
    • H04L47/2441Traffic characterised by specific attributes, e.g. priority or QoS relying on flow classification, e.g. using integrated services [IntServ]

Abstract

It is disclosed by the invention to belong to Computer Science and Technology technical field, specially a kind of efficient and expansible IP data packet classification method, the efficient and expansible IP data packet classification method includes the following steps: S1: algorithm pretreatment: purpose/source IP, purpose/source port and protocol domain being connected into Bit String, totally 104 bit;S2: clash handle: establishing Hash bucket, then carries out the processing to conflict using zipper method;S3: the generation of pseudo random number the generation of random number: is realized using linear multiplicative congruential method, shift register method, mixing method or Fibonacci method;S4: packet classification emulation, it can ensure that IP data packet carries out wire speed classification, there is no update and structural rearrangements completely in update, only a small amount of incremental update, renewal speed is fast, reduces the time that classification needs, substantially increases classification effectiveness, it can extend to any number of sorting fields, meet classificating requirement.

Description

A kind of efficient and expansible IP data packet classification method
Technical field
The present invention relates to Computer Science and Technology technical field, specially a kind of efficient and expansible IP data packet point Class method.
Background technique
The fast development of Internet technology requires the network equipment, especially border networks equipment to support such as tactful road By, various Differentiated Services applications such as access control, virtual private network, network address translation, load balancing, authentication and accounting, this A little applications are all based on packet classifier technique.They require the network equipment that can be incited somebody to action according to certain fields in packet header Data packet is divided into the stream of different identification, to take different operations for different stream, that is, provides different services.Data The quality of packet classification method and the height of efficiency directly affect the performance of whole network equipment.One typical packet classification Example be IP route querying, with longest prefix match rule LPM (Longest Prefix Match) search routing table, root Next hop address is determined according to purpose IP address.There is cannot be to the data packet in high speed network for IP data packet classification method at present Wire speed classification is carried out, and can not accurately be classified, scalability is poor.For this purpose, it is proposed that a kind of efficient and expansible IP data packet classification method.
Summary of the invention
The purpose of the present invention is to provide a kind of efficient and expansible IP data packet classification methods, to solve above-mentioned background The current IP data packet classification method proposed in technology there is cannot to the data packet in high speed network carry out wire speed classification, and Can not accurately it classify, the problem of scalability difference.
To achieve the above object, the invention provides the following technical scheme: a kind of efficient and expansible IP packet classification Method, the efficient and expansible IP data packet classification method include the following steps:
S1: algorithm pretreatment: connecting into Bit String for purpose/source IP, purpose/source port and protocol domain, totally 104 bit, Then 110 bits are averagely divided into 5 blocks, every piece of 22 bits, by one piece of 22 bit map therein to another random space, Then index value that the random number in another random space is carried out to 22 bits that XOR operation obtains, is finally looked into this 22 bit It looks for;
S2: clash handle: establishing Hash bucket, then carries out the processing to conflict using zipper method;
S3: it the generation of random number: is realized using linear multiplicative congruential method, shift register method, mixing method or Fibonacci method The generation of pseudo random number;
S4: packet classification emulation: using random 01 bit stream of 104bit, 01 random bit stream is soft using WinHex Part generates, and is generated using the function that the random number of WinHex software fixed interval writes memory and generates filtering rule library and emulate defeated The data entered.
Preferably, the Hash bucket in the step S2 is used to store 22 bit random i lumbers in corresponding random space, bucket In for packet header Bit String mapping after 22bit random number.
Preferably, the zipper method in the step S2 is searched and the algorithm of insertion is as follows:
Preferably, in the step S3, using linear multiplicative congruential method, citation form is to any initial value integer X0, by Following recurrence formula determines:
Xi=(α Xi-1+c)modM
ξi=Xi/ M, i=1,2,3 ....
Compared with prior art, the beneficial effects of the present invention are: a kind of efficient and expansible IP number that the invention proposes According to packet classification method, it can be ensured that IP data packet carries out wire speed classification, and there is no update and structural rearrangements completely in update, only There is a small amount of incremental update, renewal speed is fast, reduces the time that classification needs, substantially increases classification effectiveness, can extend To any number of sorting fields, meet classificating requirement.
Detailed description of the invention
Fig. 1 is classification method flow chart of the present invention.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Site preparation description, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.It is based on Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts every other Embodiment shall fall within the protection scope of the present invention.
Referring to Fig. 1, the present invention provides a kind of technical solution: a kind of efficient and expansible IP data packet classification method, The efficient and expansible IP data packet classification method includes the following steps:
S1: algorithm pretreatment: connecting into Bit String for purpose/source IP, purpose/source port and protocol domain, totally 104 bit, Then 110 bits are averagely divided into 5 blocks, every piece of 22 bits, by one piece of 22 bit map therein to another random space, Then index value that the random number in another random space is carried out to 22 bits that XOR operation obtains, is finally looked into this 22 bit It looks for;
S2: clash handle: establishing Hash bucket, then carries out the processing to conflict using zipper method;
S3: it the generation of random number: is realized using linear multiplicative congruential method, shift register method, mixing method or Fibonacci method The generation of pseudo random number;
S4: packet classification emulation: using random 01 bit stream of 104bit, 01 random bit stream is soft using WinHex Part generates, and is generated using the function that the random number of WinHex software fixed interval writes memory and generates filtering rule library and emulate defeated The data entered.
Wherein, the Hash bucket in the step S2 is used to store 22 bit random i lumbers in corresponding random space, in bucket For the random number of the 22bit after the mapping of packet header Bit String;
Zipper method in the step S2 is searched and the algorithm of insertion is as follows:
In the step S3, using linear multiplicative congruential method, citation form is to any initial value integer X0, by following recursion Formula determines:
Xi=(α Xi-1+c)modM
ξi=Xi/ M, i=1,2,3 ....
It although an embodiment of the present invention has been shown and described, for the ordinary skill in the art, can be with A variety of variations, modification, replacement can be carried out to these embodiments without departing from the principles and spirit of the present invention by understanding And modification, the scope of the present invention is defined by the appended.

Claims (4)

1. a kind of efficient and expansible IP data packet classification method, it is characterised in that: the efficient and expansible IP data packet Classification method includes the following steps:
S1: algorithm pretreatment: purpose/source IP, purpose/source port and protocol domain are connected into Bit String, totally 104 bit, then 110 bits are averagely divided into 5 blocks, every piece of 22 bits, by one piece of 22 bit map therein to another random space, then The index value that the random number in another random space is carried out to 22 bits that XOR operation obtains, is finally searched with this 22 bit;
S2: clash handle: establishing Hash bucket, then carries out the processing to conflict using zipper method;
S3: the generation of random number: using linear multiplicative congruential method, shift register method, mixing method or Fibonacci method realize it is pseudo- with The generation of machine number;
S4: packet classification emulation: using random 01 bit stream of 104bit, 01 random bit stream is produced using WinHex software It is raw, it is generated using the function that the random number of WinHex software fixed interval writes memory and generates filtering rule library and emulation input Data.
2. the efficient and expansible IP data packet classification method of one kind according to claim 1, it is characterised in that: the step Suddenly the Hash bucket in S2 is used to store 22 bit random i lumbers in corresponding random space, after mapping in bucket for packet header Bit String The random number of 22bit.
3. the efficient and expansible IP data packet classification method of one kind according to claim 1, it is characterised in that: the step Zipper method in rapid S2 is searched and the algorithm of insertion is as follows:
4. the efficient and expansible IP data packet classification method of one kind according to claim 1, it is characterised in that: the step In rapid S3, using linear multiplicative congruential method, citation form is to any initial value integer X0, it is determined by following recurrence formula:
Xi=(α Xi-1+c)modM
ξi=Xi/ M, i=1,2,3 ....
CN201811229945.5A 2018-10-22 2018-10-22 A kind of efficient and expansible IP data packet classification method Pending CN109218224A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811229945.5A CN109218224A (en) 2018-10-22 2018-10-22 A kind of efficient and expansible IP data packet classification method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811229945.5A CN109218224A (en) 2018-10-22 2018-10-22 A kind of efficient and expansible IP data packet classification method

Publications (1)

Publication Number Publication Date
CN109218224A true CN109218224A (en) 2019-01-15

Family

ID=64979909

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811229945.5A Pending CN109218224A (en) 2018-10-22 2018-10-22 A kind of efficient and expansible IP data packet classification method

Country Status (1)

Country Link
CN (1) CN109218224A (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101753445A (en) * 2009-12-23 2010-06-23 重庆邮电大学 Fast flow classification method based on keyword decomposition hash algorithm
CN102437950A (en) * 2011-11-08 2012-05-02 西安电子科技大学 High efficient and extensible IP data packet classification method
CN104182393A (en) * 2013-05-21 2014-12-03 中兴通讯股份有限公司 Processing method and processing device for keyword mapping based on hash table
CN104518984A (en) * 2014-12-22 2015-04-15 北京航空航天大学 SDN controller for carrying out traffic classification on data package based on multiple classifiers

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101753445A (en) * 2009-12-23 2010-06-23 重庆邮电大学 Fast flow classification method based on keyword decomposition hash algorithm
CN102437950A (en) * 2011-11-08 2012-05-02 西安电子科技大学 High efficient and extensible IP data packet classification method
CN104182393A (en) * 2013-05-21 2014-12-03 中兴通讯股份有限公司 Processing method and processing device for keyword mapping based on hash table
CN104518984A (en) * 2014-12-22 2015-04-15 北京航空航天大学 SDN controller for carrying out traffic classification on data package based on multiple classifiers

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
尚凤军,潘英俊: "基于XOR Hash的快速IP数据包分类算法研究", 《计算机工程与应用》 *

Similar Documents

Publication Publication Date Title
US7668160B2 (en) Methods for performing packet classification
US6985483B2 (en) Methods and systems for fast packet forwarding
US7684400B2 (en) Logarithmic time range-based multifield-correlation packet classification
JP2004517519A (en) Apparatus and method for performing high-speed Internet protocol route lookup and managing routing / forwarding table
Pao et al. Efficient hardware architecture for fast IP address lookup
CN102333039A (en) Method for forwarding message, and method and device for generating table entry
Wuu et al. A longest prefix first search tree for IP lookup
US20120287946A1 (en) Hash-Based Load Balancing with Flow Identifier Remapping
US20180083921A1 (en) String search and matching for gate functionality
CN103457855B (en) Classless inter-domain routing table is established and the method and apparatus of message forwarding
Lim et al. Two-dimensional packet classification algorithm using a quad-tree
Hsieh et al. A classified multisuffix trie for IP lookup and update
CN109218224A (en) A kind of efficient and expansible IP data packet classification method
US20190280959A1 (en) System and method for fib aggregation
CN111163077A (en) System and method for realizing multidimensional continuous mask based on network processor
Vijay et al. Implementation of memory-efficient linear pipelined IPv6 lookup and its significance in smart cities
Yang et al. Scalable forwarding tables for supporting flexible policies in enterprise networks
KR100686732B1 (en) Method for foriming database for routing data packet from plural prefix and method for routing and router using the method
Chang et al. Grid of segment trees for packet classification
Chung et al. A fast and updatable IP address lookup scheme
Liu et al. Obf: a guaranteed ip lookup performance scheme for flexible ip using one bloom filter
Poh et al. IPv6 packet classification based on flow label, source and destination addresses
Dai et al. An advanced TCAM-sram architecture for ranges towards minimizing packet classifiers
Hsieh et al. A novel dynamic router-tables design for IP lookup and update
Sahni et al. IP router tables

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right

Effective date of registration: 20190701

Address after: 330500 No. 8 Qianjin East Road, Fenghuang Development Zone, Anyi County, Nanchang City, Jiangxi Province

Applicant after: Nanchang Career Academy

Address before: 330500 No. 8 Qianjin East Road, Fenghuang Development Zone, Anyi County, Nanchang City, Jiangxi Province

Applicant before: Wang Yaosheng

TA01 Transfer of patent application right
RJ01 Rejection of invention patent application after publication

Application publication date: 20190115

RJ01 Rejection of invention patent application after publication