Summary of the invention
The object of this invention is to provide a kind of mapping buffer memory DoS attack defence method based on identifier separating mapping network, it can prevent from accessing overflowing of switch router mapping buffer memory, ensure the continuity of validated user communication, malice map information in identification and filtration access switch router mapping buffer memory, ensure the availability that accesses switch router in identifier separating mapping network, guarantee to access the authenticity of map information entry in switch router mapping buffer memory, thus the fail safe that has improved identifier separating mapping network.
For this reason, the invention provides a kind of mapping buffer memory DoS attack defence method based on identifier separating mapping network, it is characterized in that, comprise the following steps:
1) when access switch router is received after the packet that user terminal sends, if while there is no the map information of packet rs destination address in its mapping buffer memory, access switch router is inquired about corresponding map information to mapping server, map information is stored in mapping buffer memory simultaneously, and sets timer;
2) the map information entry number in mapping buffer memory is increased to after thresholding 1, access switch router triggers puzzle mechanism, in the mapping buffer memory sending for user terminal, there is not each new data packets of its map information, access switch router is utilized the unique puzzle of puzzle algorithm construction, and puzzle is sent to this user terminal;
3) user terminal is received after the puzzle of access switch router transmission, utilizes the suitable CPU time to search the answer of puzzle, and the answer of puzzle is sent to access switch router;
4) access switch router is received after the answer of user terminal transmission, and if the correctness of Validation Answer Key, correct, accesses the switch router inquiry map information of packet rs destination address before; If incorrect, access switch router and simply abandon previous packet;
5) after the map information entry in mapping buffer memory is increased to the thresholding 2 that is greater than thresholding 1, access switch router is calculated the confidence value of the map information that belongs to same user terminal, if the confidence value of map information is less than the limits value of setting, access switch router and delete all map information entries of this user terminal in mapping buffer memory, and filter out this user terminal all packets afterwards.
Preferably, described in be filtered into immediately the malice map entry of removing in mapping buffer memory, or utilize legal map entry to override the map entry of malice.
Preferably, first user terminal must carry out prime factor decomposition computation, then carries out the answer that module exponent interative computation draws puzzle.
Preferably, between each puzzle, be incoherent.
Preferably, large several K, the iterations n that access switch router is decomposed from prime factor, seek scope nonnegative integer l and tetra-aspects of modulus q regulate the difficulty of puzzle mechanism.
According to the present invention, in mapping, two thresholdings are set in buffer memory, when in mapping buffer memory, map information entry number reaches thresholding 1, access switch router triggers puzzle mechanism and slows down advancing the speed of map information entry in mapping buffer memory; When in mapping buffer memory, map information entry number reaches thresholding 2, access switch router is calculated the reliability discriminant of map information and filtering fallacious map information.
The present invention has prevented mapping cache overflow, has ensured the continuity of validated user communication.
Meanwhile, for the mapping buffer memory DoS attack of malicious attacker, the present invention can identify and filter the map information of malice in mapping buffer memory, thereby has ensured the availability of access switch router.
The present invention is directed in identifier separating mapping network and connect the design feature as switch router, utilize the confidence level algorithm of puzzle mechanism and map information, resisted the mapping buffer memory DoS attack that may exist, improved the security reliability of identifier separating mapping network.
Embodiment
As shown in Figure 1, the present invention sets two threshold values in the mapping buffer memory of access switch router, and thresholding 1 is less than thresholding 2.When the map information entry number in mapping buffer memory reaches thresholding 1, access switch router employing puzzle mechanism slows down the query rate of map information, thereby in reduction mapping buffer memory, map entry advances the speed; When the map entry in mapping buffer memory continues to be increased to thresholding 2, access switch router adopts map information confidence level algorithm to differentiate and filtering fallacious map information entry, prevents from shining upon overflowing of buffer memory, ensures the uninterrupted communication of validated user.
The puzzle mechanism of the method combines prime factor by iterative algorithm decomposes and discrete logarithm problem, is a kind of puzzle algorithm of CPU restricted type, solves the CPU time that puzzle needs right quantity.This puzzle mechanism has following characteristic:
(1) this puzzle algorithm has good calculating guarantee, and first user terminal must carry out prime factor decomposition computation, then carries out the answer that module exponent interative computation draws puzzle, does not have the shortcut that obtains puzzle answer;
(2) easily checking, access switch router only needs once to contrast the checking that can complete puzzle answer; And between each puzzle, be incoherent, can not guess and another puzzle from a puzzle;
(3) controllability of difficulty, has fine and smooth difficulty granularity, and access switch router can regulate the difficulty of puzzle mechanism from four aspects, be respectively large several K, iterations n, seek scope---nonnegative integer l and the modulus q that prime factor decomposes.
The main implementation of puzzle mechanism is as follows:
Step 1: when the entry number of map information reaches thresholding 1 in mapping buffer memory, access switch router is analyzed each newly arrived packet, if do not have the map information of this packet rs destination address in mapping buffer memory, access switch router structure puzzle { K, q, r, l, y
n, Sum} retains the answer x of this puzzle simultaneously
1, then this puzzle is sent to the source host of this packet;
Step 2: source host is received puzzle { K, q, r, l, y
n, after Sum}, by suitable calculating, obtain the answer x ' of puzzle, then the answer of puzzle is sent to corresponding access switch router;
Step 3: when access switch router is received after x ', contrast x
1with x ', if equate, access the map information of switch router inquiry corresponding data bag destination address; If etc., do not access switch router, abandon corresponding data bag.
Access switch router is differentiated the legitimacy of user terminal by calculating the confidence level algorithm of map information, whether shining upon buffer memory DoS attack.If the confidence level that belongs to the map information of a certain user terminal in mapping buffer memory is less than the decision content of prior setting, think that this user terminal is malice; If the confidence level that belongs to the map information of a certain user terminal in mapping buffer memory is greater than the decision content of prior setting, think that this user terminal is legal.The confidence level algorithm of map information is theoretical based on binomial event posterior probability, and it is mainly defined as follows:
Wherein, TV is the confidence value of map information, u is for belonging to the legal map information entry number of a certain user terminal in access switch router mapping buffer memory, v is for belonging to the map information entry number of the malice of same user terminal in access switch router mapping buffer memory.
In access switch router mapping buffer memory, the legitimacy of map information is judged by following principle:
If the timer timing time of a certain map information entry is less than predefined limit value t in mapping buffer memory
mR, think that this map information entry is legal map information entry; If the timer timing time of a certain map information entry is greater than predefined limit value t in mapping buffer memory
mR, think that this map information entry is for map information entry maliciously.
Embodiment 1: as shown in Figure 2, the groundwork flow process of the mapping buffer memory DoS attack defence method based on identifier separating mapping network is as follows:
Step 1: when access switch router is received after the packet that user terminal sends, if while there is no the map information of packet rs destination address in its mapping buffer memory, access switch router is inquired about corresponding map information to mapping server, map information is stored in mapping buffer memory simultaneously, and sets timer;
Step 2: the map information entry number in mapping buffer memory is increased to after thresholding 1, access switch router triggers puzzle mechanism, each new data packets sending for user terminal (not having its map information in mapping buffer memory), access switch router is utilized the unique puzzle of puzzle algorithm construction, and puzzle is sent to this user terminal;
Step 3: user terminal is received after the puzzle of access switch router transmission, utilized the suitable CPU time to search the answer of puzzle, and the answer of puzzle is sent to access switch router;
Step 4: access switch router is received after the answer of user terminal transmission, the correctness of Validation Answer Key, if correct, accesses the switch router inquiry map information of packet rs destination address before; If incorrect, access switch router and simply abandon previous packet;
Step 5: the map information entry in mapping buffer memory is increased to after thresholding 2, access switch router is calculated the confidence value of the map information that belongs to same user terminal, if the confidence value of map information is less than the limits value of setting, access switch router and delete all map information entries of this user terminal in mapping buffer memory, and filter out this user terminal all packets afterwards.
Embodiment 2: it is as described below that the puzzle of the mapping buffer memory DoS attack defence method based on identifier separating mapping network produces algorithm:
First access switch router chooses a series of prime number a
1a
n, by formula (1), calculate large number K.
Choose a large prime number q, at [0, q-1], select a random number r simultaneously.X
1be a random puzzle answer of selecting in [r, (r+l) mod (q-1)] is interval, wherein, l is the variable number of access switch router appointment.
Then, access switch router is by being used formula (2) to calculate y
n.
Formula (2) has successfully used iterative algorithm, the end a of each iteration
ibe a prime factor counting greatly K, wherein, all prime factors of K are pressed ascending sequence and are arranged, for example, if e≤f, so a
e≤ a
f.Iterations i in formula (2) can ensure at sequence x
1to x
nin there is not loop cycle.Reason is as follows: iff using discrete logarithm equation
due to modulo operation, at sequence x
1to x
nin just may there is the circulation in cycle, i.e. x
l=x
l+c.Therefore,, when malicious attacker is found the circulation law of iterative process, just may find shortcut and escape a large amount of calculating consumption.
In addition, owing to having introduced modular arithmetic, at interval [r, (r+l) mod (q-1)], may there is different x
1after equation (2), obtain same y
n.In order to address this problem, access switch router utilizes formula (3) to calculate all x
iand Sum:
So far, puzzle produces algorithm and finishes, and corresponding puzzle collection is { K, q, r, l, y
n, Sum}.
Embodiment 3: in the mapping buffer memory DoS attack defence method based on identifier separating mapping network, puzzle verification method is as described below:
When a user terminal receives that, after the puzzle of access switch router, first the prime factor of calculating K decomposes, and obtains all prime factor a
1a
n.Then, according to equation (2) and (3), user terminal is carried out Brute Force and is searched candidate's puzzle answer x ' at interval [r, (r+l) mod (q-1)], and calculates y
n' and Sum '.If y
n'=y
nand Sum '=Sum, user terminal thinks that x ' is the answer of puzzle, then sends to x ' access switch router.
When access switch router, receive the puzzle answer x ' that user terminal calculates, only need the x that contrasts x ' and oneself retain
1.If both are consistent, access the map information of switch router inquiry corresponding data bag destination address; If both are inconsistent, access switch router and abandon corresponding data bag.
Embodiment 4: Fig. 3 has described the reciprocal process of puzzle mechanism in the mapping buffer memory DoS attack defence method based on identifier separating mapping network, specific as follows:
Step 1: when the entry number of map information reaches thresholding 1 in mapping buffer memory, access switch router is analyzed each newly arrived packet, if do not have the map information of this packet rs destination address in mapping buffer memory, access switch router structure puzzle { K, q, r, l, y
n, Sum} retains the answer x of this puzzle simultaneously
1, then this puzzle is sent to the source host of this packet;
Step 2: user terminal is received puzzle { K, q, r, l, y
n, after Sum}, by the calculating of Brute Force, obtain the answer x ' of puzzle, then the answer of puzzle is sent to corresponding access switch router;
Step 3: when access switch router is received after x ', contrast x
1with x ', if equate, access the map information of switch router inquiry corresponding data bag destination address; If etc., do not access switch router, abandon corresponding data bag.
Embodiment 5: when the map information entry number in mapping buffer memory is increased to thresholding 2, the confidence level algorithm of access switch router triggering map information is differentiated the confidence level of the map information that belongs to same user terminal, and specific algorithm is as described below:
In the mapping buffer memory of access switch router, each map information all has its time-out time of timer record, thereby judges whether delete corresponding entry.Generally, normal communication behavior is continuous two-way, and its information interaction time delay is average packet round-trip delay Round Trip Time (RTT).Therefore, the timing time of a legal map entry should change within 0 to maximum RTT time.On the contrary, mapping buffer memory DoS attack is unidirectional discontinuous behavior, and its main purpose is to utilize a large amount of useless map information entries to occupy mapping spatial cache, causes mapping cache overflow.Therefore, the timing time of these map information entries will increase until Time-to-Live value always.Based on this basic principle, the present invention defines map information confidence level and calculates as described in formula (4).
Formula (4) is theoretical based on binomial event posterior probability.Wherein, TV is the confidence value of map information, u is for belonging to the legal map information entry number of a certain user terminal in access switch router mapping buffer memory, v is for belonging to the map information entry number of the malice of same user terminal in access switch router mapping buffer memory.
In access switch router mapping buffer memory, the legitimacy of map information entry is judged by following principle:
If the timer timing time of a certain map information entry is less than predefined limit value t in mapping buffer memory
mR, think that this map information entry is legal map information entry; If the timer timing time of a certain map information entry is greater than predefined limit value t in mapping buffer memory
mR, think that this map information entry is for map information entry maliciously.
Consider situation below: if a legal user terminal has a large amount of map information entries, the timing time scope of these map information entries is at t
mRand between Time-to-Live value, having map information entry seldom simultaneously, the timing time scope of these map information entries is 0 to t
mRbetween.Therefore, if the map information confidence value of calculating according to formula (4) may be very low.In order to reduce this rate of false alarm, the present invention's regulation surpasses a limit value N when belonging to the map information entry number of same user terminal
ttime, access switch router is just calculated the confidence value of this user terminal map information.
For the access switch router mapping buffer memory DoS attack that prevents from may existing in identifier separating mapping network, the invention provides a kind of mapping buffer memory DoS attack defence method based on identifier separating mapping network, the method combines the feature of identity and position separation system structure in identifier separating mapping network, in the mapping buffer memory of access switch router, double threshold mechanism is set and prevents from shining upon overflowing of buffer memory.Thresholding 1 triggers the query rate that puzzle mechanism slows down map information, thereby reduces the recruitment of map information entry in mapping buffer memory; Thresholding 2 triggers the filtering fallacious map entry that map information confidence level algorithm is differentiated.
The present invention has ensured the availability that accesses switch router in identifier separating mapping network, guaranteed the authenticity of map entry in access switch router mapping buffer memory, prevent mapping buffer memory DoS attack, improved the safety and reliability of identifier separating mapping network.
According to the present invention, puzzle mechanism can replace by other puzzle mechanism, can reach equally the object of the query rate that slows down map information.
According to the present invention, filtering technique can be both the malice map entry of removing immediately in mapping buffer memory, can be also to utilize legal map entry to override the map entry of malice.
The present invention, in conjunction with the feature separated with position of identity in identifier separating mapping network, adopts double threshold mechanism to prevent from shining upon overflowing of buffer memory in the mapping buffer memory of access switch router.When the map entry number in mapping buffer memory reaches thresholding 1, access switch router adopts puzzle mechanism to slow down the query rate of map information, thereby reduces the recruitment of map entry in mapping buffer memory; When the map information entry number in mapping buffer memory reaches thresholding 2, access switch router adopts map information confidence level algorithm to differentiate and filtering fallacious map information entry.
The present invention sets two thresholdings in the mapping buffer memory of access switch router, and thresholding 1 value is less than thresholding 2 values.
Puzzle mechanism of the present invention is decomposed quality factor and discrete logarithm perfect adaptation by iterative algorithm, is a kind of CPU restricted type puzzle algorithm, needs the CPU time of right quantity to calculate puzzle answer.
Puzzle mechanism of the present invention has following characteristic:
(1) this puzzle algorithm has good calculating guarantee, does not have the shortcut that obtains puzzle answer;
(2) easily checking, and between puzzle, be incoherent;
(3) controllability of difficulty, has fine and smooth difficulty granularity.
In the design of puzzle mechanism, access switch router can regulate the difficulty of puzzle mechanism from four aspects, be respectively large several K, iterations n, seek scope---nonnegative integer l and the modulus q that prime factor decomposes.
Access switch router is differentiated the legitimacy of user terminal by calculating the confidence level algorithm of map information, whether shining upon buffer memory DoS attack, specific as follows: if belong to the decision content that the confidence level of the map information of a certain user terminal is less than prior setting in mapping buffer memory, to think that this user terminal is malice; If the confidence level that belongs to the map information of a certain user terminal in mapping buffer memory is greater than the decision content of prior setting, think that this user terminal is legal.
The confidence level computational methods of map information are theoretical based on binomial event posterior probability, considered to belong to the legal map information entry number of a certain user terminal and the map information entry number of malice in access switch router mapping buffer memory simultaneously.
In access switch router mapping buffer memory, the legitimacy of map information is judged by following principle: if the timer timing time of a certain map information entry is less than predefined limit value t in mapping buffer memory
mR, think that this map information entry is legal map information entry; If the timer timing time of a certain map information entry is greater than predefined limit value t in mapping buffer memory
mR, think that this map information entry is for map information entry maliciously.