WO2021102687A1 - Communication encryption method and system - Google Patents

Communication encryption method and system Download PDF

Info

Publication number
WO2021102687A1
WO2021102687A1 PCT/CN2019/120974 CN2019120974W WO2021102687A1 WO 2021102687 A1 WO2021102687 A1 WO 2021102687A1 CN 2019120974 W CN2019120974 W CN 2019120974W WO 2021102687 A1 WO2021102687 A1 WO 2021102687A1
Authority
WO
WIPO (PCT)
Prior art keywords
packet
data
scrambled
flag bit
counter
Prior art date
Application number
PCT/CN2019/120974
Other languages
French (fr)
Chinese (zh)
Inventor
韩性峰
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 PCT/CN2019/120974 priority Critical patent/WO2021102687A1/en
Publication of WO2021102687A1 publication Critical patent/WO2021102687A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols

Definitions

  • the present invention relates to the technical field of communication encryption, in particular to a communication encryption method and system.
  • the security of communication is also a standard to measure the pros and cons of a communication method, so it is particularly important to innovate the encryption method of communication protocol.
  • the more conventional communication method is to add any number of check codes or positive and negative codes on the basis of the custom data packet protocol, but through the comparison and decoding of big data, the security of this typical encryption method is not yet the best.
  • the present invention provides a communication encryption method, including a data sending step and a data receiving step,
  • the data sending step when sending a normal data packet, randomly send the scrambled packet according to the sending rules, the scrambled packet has a flag bit, the data format of the scrambled packet is the same as the data format of the normal data packet, but the instruction data of the scrambled packet is Incorrect;
  • the data receiving step detect the scrambled packet by identifying the flag bit of the scrambled packet, and determine whether the counter has reached the maximum value. If the counter has not reached the maximum value and the scrambled packet is received, the processing steps are executed and the counter is automatically cleared. ; If the counter reaches the maximum value, and there is still no interference packet detected, then the interference processing is performed; the counter matches the sending rule;
  • Processing steps processing the disturbed packet, so as to correctly identify the normal data.
  • the flag bit of the scrambled packet has the same level, but the level width of the two is different; in the data receiving step, the electrical level of the flag bit is judged. Flat width to identify disturbing packets.
  • the normal data packet state switching times are recorded by the transmitting end data state switching counter, and the scrambled packet is randomly sent within the set normal data packet state switching times, and the scrambled packet has a mark Bit, the data format of the scrambled packet is the same as the data format of the normal data packet, but the command data of the scrambled packet is wrong;
  • the counter is a data state switching counter at the receiving end
  • the scrambled packet is detected by identifying the flag bit of the scrambled packet, and it is judged whether the data state switching counter at the receiving end has reached the maximum value, if the data state switching at the receiving end
  • the processing steps are executed, and the data state switching counter at the receiving end is automatically cleared; if the data state switching counter at the receiving end reaches the maximum value, the scrambled packet is still not detected, then interference deal with;
  • the normal data packet state switching times set by the transmitting end data state switching counter are the same as the maximum value set by the receiving end data state switching counter.
  • the interference processing includes stopping or outputting an error instruction, and outputting an error instruction so as to cause confusion in operation.
  • the scrambled packet is deleted or the scrambled packet is not read.
  • the normal data packet is changed according to the set rule, thereby turning the normal data packet into a scrambled packet; in the processing step, the scrambled packet is changed according to the set rule Make changes to turn the disturbed packet into a normal data packet.
  • the encryption mode is determined by the flag bit width of the scrambled packet. Different flag bit widths of the scrambled packet represent different encryption methods, and the normal data packet is changed according to the corresponding encryption method.
  • the decryption mode is determined by the flag bit width of the scrambled packet, and the flag bit widths of different scrambled packets represent different decryption methods.
  • the scrambled packet is changed into Normal data packet.
  • the present invention also provides a communication encryption system, including a data sending module and a data receiving module.
  • the data sending module is used to randomly send a scrambled packet according to the sending rules when sending a normal data packet, and the scrambled packet has a flag bit.
  • the data format of the scrambled packet is the same as that of the normal data packet, but the command data of the scrambled packet is wrong;
  • the data receiving module is used to detect the scrambled packet by identifying the flag bit of the scrambled packet, and determine whether the counter has reached the maximum value. If the counter does not reach the maximum value and the scrambled packet is received, the processing module is executed and the counter is automatically Cleared to zero; if the counter reaches the maximum value and there is still no interference packet detected, then the interference processing is performed; the counter matches the sending rule;
  • Processing module used to process disturbed packets, so as to correctly identify normal data.
  • the flag bit of the scrambled packet has the same level, but the level width of the two is different; in the data receiving step, the electrical level of the flag bit is judged. Flat width to identify disturbing packets.
  • the encryption method is determined by the flag bit width of the scrambled packet. Different flag bit widths of the scrambled packet represent different encryption methods, and the normal data packet is changed according to the corresponding encryption method.
  • the decryption mode is determined by the flag bit width of the scrambled packet, and the flag bit widths of different scrambled packets represent different decryption methods.
  • the scrambled packet is changed into Normal data packet.
  • the present invention also provides a computer-readable storage medium that stores a computer program, and the computer program is configured to implement the steps of the communication encryption method of the present invention when called by a processor.
  • Figure 1 is a schematic diagram of the data of the present invention.
  • the invention discloses a communication encryption method, which includes a data sending step and a data receiving step.
  • the transmitting end executes the data sending step, and the receiving end executes the data receiving step.
  • the data sending step when sending a normal data packet, the transmitting end will randomly send the scrambled packet according to the sending rules.
  • the scrambled packet has a flag bit.
  • the data format of the scrambled packet is the same as that of the normal data packet, but the data format of the scrambled packet is the same as that of the normal data packet.
  • the instruction data is wrong;
  • the data receiving step the receiving end detects the scrambled packet by identifying the flag bit of the scrambled packet, and determines whether the counter has reached the maximum value. If the counter does not reach the maximum value and the scrambled packet is received, then the processing steps are executed, and the counter is automatically Cleared to zero; if the counter reaches the maximum value and there is still no interference packet detected, then the interference processing is performed; the counter matches the sending rule;
  • Processing steps processing the disturbed packet, so as to correctly identify the normal data.
  • the sending rule when sending a normal data packet, the sending rule is to randomly send a scrambled packet within a set time, for example, randomly send a scrambled packet every 10 seconds, then it is possible In the first 10 seconds, a scramble packet was sent in the second and sixth seconds; in the second 10 seconds, a scramble packet was sent in the third, seventh, and ninth seconds.
  • the maximum value of the counter is also 10 seconds. If the counter does not reach 10 seconds and the jamming packet is received, the processing steps are executed and the counter is automatically cleared; if the counter reaches 10 seconds, there is still no detection When the jamming packet is reached, then the jamming process is performed.
  • the sending rule when sending a normal data packet, is to randomly send a scrambled packet within the set normal data packet state switching times, for example, the set normal data packet state The number of switching times is 5, the first normal data packet is 0010, the second normal data packet is 0100, the third normal data packet is 0011, the fourth normal data packet is 0101, and the fifth normal data packet is 0110 , Because the states of the five normal data packets are not the same, it is considered that the normal data packet state has been switched 5 times.
  • the first normal data packet means that the remote control car is moving forward, and the second is normal
  • the data packet means that the remote control car is going back
  • the third normal data packet means the remote control car turns left
  • the fourth normal data packet means the remote control car turns right
  • the fifth normal data packet means the remote control car stops; in the normal data packet Within 5 times of state switching, a scrambled packet can be sent once or a scrambled packet can be sent twice, so it is a scrambled packet sent randomly.
  • the data receiving step it is judged whether the data state switching counter at the receiving end has reached the maximum value, that is, 5 times.
  • the data state switching counter at the receiving end does not reach the maximum value 5 times, and after receiving the jamming packet, then perform processing Step, and the data state switching counter at the receiving end is automatically cleared; if the data state switching counter at the receiving end reaches the maximum value 5 times and the jamming packet is still not detected, then interference processing is performed.
  • the interference processing includes stopping or outputting an error instruction, and outputting an error instruction so that operation disorder occurs.
  • the first processing method the receiving end deletes the scrambled packet or does not read the scrambled packet.
  • the second processing method in the data sending step, the normal data packet is changed according to the set rule, so that the normal data packet becomes a scrambled packet; in the processing step, the scrambled packet is processed according to the set rule Change, so as to turn the scrambled packet into a normal data packet; for example, if the normal data packet is 0100, then the transmitting end will reverse the normal data packet 0100 to 1011 according to the set rules, thereby turning the normal data packet into a scrambled packet, and then The transmitting end sends the normal data packet and the scrambled packet to the receiving end; after detecting the scrambled packet, the receiving end reverses all the scrambled packets 1011 to 0100 according to the set rules, thereby turning the scrambled packet into a normal data packet.
  • the second processing method can reduce the delay of reading data at the receiving end, and the effect is very good.
  • the setting rule can also be the inversion of a certain bit of the normal data packet. For example, if the last bit of 0100 is inverted for the normal data packet, then the scrambled packet is 0101.
  • the setting rules can be set according to customer needs. .
  • the flag bit of the scrambled packet of the present invention is not an easy-to-identify data.
  • the following is a detailed description: Compared with the flag bit of the normal data packet, the flag bit of the scrambled packet has the same level and shape, but the electrical The level width is different; in the data receiving step, the jammed packet is identified by judging the level width of the flag bit.
  • the flag bit of the scrambled packet has the same level and shape as the flag bit of the normal data packet, but the flag bit of the scrambled packet and the flag bit of the normal data packet have different level widths, so the flag of the scrambled packet Bits do not have outstanding different characteristics and cannot be easily identified by pirates. This is a very important feature.
  • the scrambled packet is identified by judging the level width of the flag bit. For example, the flag bit width of the normal data packet is 500us, and the flag bit width of the scrambled packet is 550us or 600us.
  • the width of the flag bit is 500 us, it is regarded as a normal data packet, and when it is detected that the width of the flag bit is 550 us or 600 us, it is regarded as a scrambled packet.
  • the flag bit of the scrambled packet, its width itself also carries encrypted information, such as:
  • the encryption method is determined by the flag bit width of the scrambled packet, and the flag bit widths of different scrambled packets represent different encryption methods, and the normal data packet is changed into a scrambled packet according to the corresponding encryption method;
  • the decryption mode is determined by the flag bit width of the scrambled packet, and the flag bit widths of different scrambled packets represent different decryption methods.
  • the scrambled packet is changed into Normal data packet.
  • the flag bit width of a normal data packet is: 500us
  • Example 1 The flag bit width of the scrambled packet is 550us.
  • the flag bit width 550us of the scrambled packet is used to determine that the encryption method is encryption method 1 (all data is reversed), and the normal data packet is changed to encryption method 1.
  • the scrambled packet for example, normal data: 10110010, encryption method one data: 01001101 (scrambling packet).
  • the flag bit width of the scrambled packet is 550us to determine that the decryption mode is decryption mode 1 (all data is reversed).
  • the scrambled data packet is transformed into a normal data packet according to the decryption mode 1, for example ,
  • the scrambled packet 01001101 becomes normal data 10110010.
  • Example 2 The flag bit width of the scrambled packet is 600us.
  • the flag bit width 600us of the scrambled packet is used to determine the encryption method as encryption method two (odd-bit data is reversed, even-bit data remains intact), according to the encryption method Second, the normal data packet is turned into a scrambled packet, for example, normal data: 10110010, encryption method two data: 00011001 (scrambling packet).
  • the decryption mode is determined to be decryption mode 2 by the flag bit width 600us of the scrambled packet (the odd-numbered data is inverted, and the even-numbered data is kept as it is).
  • the scrambled data packet will be scrambled according to the decryption mode 2 It becomes a normal data packet, for example, the scrambled packet 00011001 becomes normal data 10110010.
  • Example 3 The flag bit width of the scrambled packet is 450us.
  • the encryption method is determined by the flag bit width 450us of the scrambled packet as encryption method three (even-digit data is inverted, and odd-digit data remains intact), according to the encryption method Third, the normal data packet is turned into a scrambled packet, for example, normal data: 10110010, and encryption method three data: 11100111 (scrambling packet).
  • the decryption mode is determined to be decryption mode 3 (even-numbered data is inverted, and odd-numbered data is kept as it is) through the flag bit width 450us of the scrambled packet.
  • the data packet is scrambled according to decryption mode three. It becomes a normal data packet, for example, the scrambled packet 11100111 becomes normal data 10110010.
  • the communication encryption method of the present invention no longer focuses on the processing of data packets, but randomly sends disturbed packets when normal data changes. Such random and temporary data changes are difficult to pass through the oscilloscope or The logic analyzer captures valid data, and pirates often ignore this data.
  • the transmitter will have a data state switching counter, which will randomly send a scrambled packet after a certain number of data state switches, and the data format of the scrambled packet is the same as the normal data packet, the difference is that the command data of the scrambled packet is wrong.
  • the genuine decoding IC can filter out the disturbed packet by identifying the flag bit of the disturbed packet, while the pirated decoding IC will treat the instruction of the disturbed packet as normal data to process the operation disorder.
  • the remote control is the transmitter, and the remote control car is the receiver.
  • the transmitter will send forward code, backward code, and left turn code. If it is a genuine receiver, the forward and backward switching is quick and unresponsive. There will be other situations, and the receiving end of the pirated version will find that when the operation is moving forward and backward, the remote control car will suddenly turn left or right from time to time, and there is no pattern to find.
  • the present invention also discloses a communication encryption system, which includes a data sending module and a data receiving module.
  • the data sending module is used to randomly send a scrambled packet according to the sending rule when a normal data packet is sent, and the scrambled packet has a flag bit.
  • the data format of the scrambled packet is the same as that of the normal data packet, but the command data of the scrambled packet is wrong;
  • the data receiving module is used to detect the scrambled packet by identifying the flag bit of the scrambled packet, and determine whether the counter has reached the maximum value. If the counter does not reach the maximum value and the scrambled packet is received, the processing module is executed and the counter is automatically Cleared to zero; if the counter reaches the maximum value and there is still no interference packet detected, then the interference processing is performed; the counter matches the sending rule;
  • Processing module used to process disturbed packets, so as to correctly identify normal data.
  • the normal data packet state switching times are recorded by the transmitting end data state switching counter, and the scrambled packet is randomly sent within the set normal data packet state switching times.
  • the scrambled packet has a flag bit and the data format of the scrambled packet The data format of the normal data packet is the same, but the command data of the disturbed packet is wrong;
  • the counter is a data state switching counter at the receiving end.
  • the scrambled packet is detected by identifying the flag bit of the scrambled packet to determine whether the data state switching counter at the receiving end has reached the maximum value. After the counter has not reached the maximum value and the scrambled packet is received, the processing module is executed, and the data state switching counter at the receiving end is automatically cleared; if the data state switching counter at the receiving end reaches the maximum value, the scrambled packet is still not detected, then interference deal with;
  • the normal data packet state switching times set by the transmitting end data state switching counter are the same as the maximum value set by the receiving end data state switching counter.
  • the scrambled packet is deleted or the scrambled packet is not read.
  • the normal data packet is changed according to the set rule, thereby turning the normal data packet into a scrambled packet;
  • the scrambled packet is changed according to the set rule, so that the scrambled packet becomes a normal data packet.
  • the present invention also discloses a computer-readable storage medium, the computer-readable storage medium stores a computer program, and the computer program is configured to implement the steps of the communication encryption method of the present invention when called by a processor.

Abstract

Provided are a communication encryption method and system. The communication encryption method comprises: a data sending step: when a normal data packet is sent, randomly sending a scramble packet according to a sending rule, wherein the scramble packet has a flag bit, the data format of the scramble packet is the same as the data format of the normal data packet, but instruction data of the scramble packet is erroneous; and a data receiving step: detecting the scramble packet by means of identifying the flag bit of the scramble packet; if a counter does not reach the maximum value and after the scramble packet is received, executing a processing step and the counter automatically resetting to zero; and if the counter reaches the maximum value and the scramble packet is still not detected, performing interference processing. The beneficial effects of the present invention involve: a pirate generally focuses on the structure of each packet of data, while overlooking the situation when the state of each packet of data is switched, and takes a scramble packet as normal data; moreover, the scramble packet is random and fast, thereby greatly increasing the privacy of encryption and greatly disrupting the pirate.

Description

一种通信加密方法、系统Communication encryption method and system 技术领域Technical field
本发明涉及通信加密技术领域,尤其涉及一种通信加密方法、系统。The present invention relates to the technical field of communication encryption, in particular to a communication encryption method and system.
背景技术Background technique
现在无线技术应用发展迅猛,未来有可能取代有线通信成为主流,而通信的安全性也是衡量一种通信方式优劣的一个标准,所以创新通信协议的加密方式尤为重要。目前比较常规的通信方式只是在自定义的数据包协议的基础上加上任意位数的校验码或者正反码等等,但是通过大数据比较解码,这种典型的加密方式安全性还不是最好的。Nowadays, the application of wireless technology is developing rapidly, and it may replace wired communication as the mainstream in the future. The security of communication is also a standard to measure the pros and cons of a communication method, so it is particularly important to innovate the encryption method of communication protocol. At present, the more conventional communication method is to add any number of check codes or positive and negative codes on the basis of the custom data packet protocol, but through the comparison and decoding of big data, the security of this typical encryption method is not yet the best.
发明概述Summary of the invention
技术问题technical problem
问题的解决方案The solution to the problem
技术解决方案Technical solutions
本发明提供了一种通信加密方法,包括数据发送步骤和数据接收步骤,The present invention provides a communication encryption method, including a data sending step and a data receiving step,
所述数据发送步骤:在发送正常数据包的时候,按照发送规则进行随机发送扰乱包,扰乱包具有标志位,扰乱包的数据格式和正常数据包的数据格式相同,但扰乱包的指令数据是错误的;The data sending step: when sending a normal data packet, randomly send the scrambled packet according to the sending rules, the scrambled packet has a flag bit, the data format of the scrambled packet is the same as the data format of the normal data packet, but the instruction data of the scrambled packet is Incorrect;
所述数据接收步骤:通过识别扰乱包的标志位检测扰乱包,判断计数器是否达到了最大值,若在计数器没有达到最大值,且收到扰乱包后,那么执行处理步骤,并且计数器自动清零;如果计数器达到最大值,仍然没有检测到扰乱包,那么进行干扰处理;计数器与发送规则相匹配;The data receiving step: detect the scrambled packet by identifying the flag bit of the scrambled packet, and determine whether the counter has reached the maximum value. If the counter has not reached the maximum value and the scrambled packet is received, the processing steps are executed and the counter is automatically cleared. ; If the counter reaches the maximum value, and there is still no interference packet detected, then the interference processing is performed; the counter matches the sending rule;
处理步骤:对扰乱包进行处理,从而对正常数据进行正确识别。Processing steps: processing the disturbed packet, so as to correctly identify the normal data.
作为本发明的进一步改进,扰乱包的标志位与正常数据包的标志位相比,二者的电平相同,但是,二者的电平宽度不同;在数据接收步骤中,通过判断标志位的电平宽度来识别扰乱包。As a further improvement of the present invention, compared with the flag bit of the normal data packet, the flag bit of the scrambled packet has the same level, but the level width of the two is different; in the data receiving step, the electrical level of the flag bit is judged. Flat width to identify disturbing packets.
作为本发明的进一步改进,在所述数据发送步骤中,通过发射端数据状态切换 计数器记录正常数据包状态切换次数,在设定的正常数据包状态切换次数内随机发送扰乱包,扰乱包具有标志位,扰乱包的数据格式和正常数据包的数据格式相同,但扰乱包的指令数据是错误的;As a further improvement of the present invention, in the data sending step, the normal data packet state switching times are recorded by the transmitting end data state switching counter, and the scrambled packet is randomly sent within the set normal data packet state switching times, and the scrambled packet has a mark Bit, the data format of the scrambled packet is the same as the data format of the normal data packet, but the command data of the scrambled packet is wrong;
在所述数据接收步骤中,所述计数器为接收端数据状态切换计数器,通过识别扰乱包的标志位检测扰乱包,判断接收端数据状态切换计数器是否达到了最大值,若在接收端数据状态切换计数器没有达到最大值,且收到扰乱包后,那么执行处理步骤,并且接收端数据状态切换计数器自动清零;如果接收端数据状态切换计数器达到最大值,仍然没有检测到扰乱包,那么进行干扰处理;In the data receiving step, the counter is a data state switching counter at the receiving end, the scrambled packet is detected by identifying the flag bit of the scrambled packet, and it is judged whether the data state switching counter at the receiving end has reached the maximum value, if the data state switching at the receiving end After the counter has not reached the maximum value and the scrambled packet is received, the processing steps are executed, and the data state switching counter at the receiving end is automatically cleared; if the data state switching counter at the receiving end reaches the maximum value, the scrambled packet is still not detected, then interference deal with;
其中,发射端数据状态切换计数器设定的正常数据包状态切换次数与接收端数据状态切换计数器设定的最大值相同。Among them, the normal data packet state switching times set by the transmitting end data state switching counter are the same as the maximum value set by the receiving end data state switching counter.
作为本发明的进一步改进,在所述数据接收步骤中,干扰处理包括停机或者输出错误指令,输出错误指令以至于出现操作混乱。As a further improvement of the present invention, in the data receiving step, the interference processing includes stopping or outputting an error instruction, and outputting an error instruction so as to cause confusion in operation.
作为本发明的进一步改进,在所述处理步骤中,将扰乱包删除或者不读取扰乱包。As a further improvement of the present invention, in the processing step, the scrambled packet is deleted or the scrambled packet is not read.
作为本发明的进一步改进,在所述数据发送步骤中,将正常数据包按照设定规则进行变化,从而将正常数据包变成扰乱包;在所述处理步骤中,将扰乱包按照设定规则进行变化,从而将扰乱包变成正常数据包。As a further improvement of the present invention, in the data sending step, the normal data packet is changed according to the set rule, thereby turning the normal data packet into a scrambled packet; in the processing step, the scrambled packet is changed according to the set rule Make changes to turn the disturbed packet into a normal data packet.
作为本发明的进一步改进,在所述数据发送步骤中,通过扰乱包的标志位宽度确定加密方式,不同的扰乱包的标志位宽度代表不同的加密方式,根据对应的加密方式将正常数据包变成扰乱包;As a further improvement of the present invention, in the data sending step, the encryption mode is determined by the flag bit width of the scrambled packet. Different flag bit widths of the scrambled packet represent different encryption methods, and the normal data packet is changed according to the corresponding encryption method. Into a scrambled packet;
在所述数据接收步骤中,通过扰乱包的标志位宽度确定解密方式,不同的扰乱包的标志位宽度代表不同的解密方式,在所述处理步骤中,根据对应的解密方式将扰乱包变成正常数据包。In the data receiving step, the decryption mode is determined by the flag bit width of the scrambled packet, and the flag bit widths of different scrambled packets represent different decryption methods. In the processing step, the scrambled packet is changed into Normal data packet.
本发明还提供了一种通信加密系统,包括数据发送模块和数据接收模块,所述数据发送模块:用于在发送正常数据包的时候,按照发送规则进行随机发送扰乱包,扰乱包具有标志位,扰乱包的数据格式和正常数据包的数据格式相同,但扰乱包的指令数据是错误的;The present invention also provides a communication encryption system, including a data sending module and a data receiving module. The data sending module is used to randomly send a scrambled packet according to the sending rules when sending a normal data packet, and the scrambled packet has a flag bit. , The data format of the scrambled packet is the same as that of the normal data packet, but the command data of the scrambled packet is wrong;
所述数据接收模块:用于通过识别扰乱包的标志位检测扰乱包,判断计数器是 否达到了最大值,若在计数器没有达到最大值,且收到扰乱包后,那么执行处理模块,并且计数器自动清零;如果计数器达到最大值,仍然没有检测到扰乱包,那么进行干扰处理;计数器与发送规则相匹配;The data receiving module is used to detect the scrambled packet by identifying the flag bit of the scrambled packet, and determine whether the counter has reached the maximum value. If the counter does not reach the maximum value and the scrambled packet is received, the processing module is executed and the counter is automatically Cleared to zero; if the counter reaches the maximum value and there is still no interference packet detected, then the interference processing is performed; the counter matches the sending rule;
处理模块:用于对扰乱包进行处理,从而对正常数据进行正确识别。Processing module: used to process disturbed packets, so as to correctly identify normal data.
作为本发明的进一步改进,扰乱包的标志位与正常数据包的标志位相比,二者的电平相同,但是,二者的电平宽度不同;在数据接收步骤中,通过判断标志位的电平宽度来识别扰乱包。As a further improvement of the present invention, compared with the flag bit of the normal data packet, the flag bit of the scrambled packet has the same level, but the level width of the two is different; in the data receiving step, the electrical level of the flag bit is judged. Flat width to identify disturbing packets.
作为本发明的进一步改进,在所述数据发送模块中,通过扰乱包的标志位宽度确定加密方式,不同的扰乱包的标志位宽度代表不同的加密方式,根据对应的加密方式将正常数据包变成扰乱包;As a further improvement of the present invention, in the data sending module, the encryption method is determined by the flag bit width of the scrambled packet. Different flag bit widths of the scrambled packet represent different encryption methods, and the normal data packet is changed according to the corresponding encryption method. Into a scrambled packet;
在所述数据接收模块中,通过扰乱包的标志位宽度确定解密方式,不同的扰乱包的标志位宽度代表不同的解密方式,在所述处理模块中,根据对应的解密方式将扰乱包变成正常数据包。In the data receiving module, the decryption mode is determined by the flag bit width of the scrambled packet, and the flag bit widths of different scrambled packets represent different decryption methods. In the processing module, the scrambled packet is changed into Normal data packet.
本发明还提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序配置为由处理器调用时实现本发明所述的通信加密方法的步骤。The present invention also provides a computer-readable storage medium that stores a computer program, and the computer program is configured to implement the steps of the communication encryption method of the present invention when called by a processor.
发明的有益效果The beneficial effects of the invention
有益效果Beneficial effect
本发明的有益效果是:盗版者一般会把注意力放在每一包数据的结构上,而忽视了每包数据状态切换时情况,把扰乱包当成正常数据使用,而且扰乱包还是随机性、快速性的,极大地增加了加密的隐秘性,对盗版者造成了极大干扰。对附图的简要说明The beneficial effects of the present invention are: pirates generally pay attention to the structure of each packet of data, and ignore the situation when the state of each packet is switched, treat the disturbed packet as normal data, and the disturbed packet is still random, It is fast, which greatly increases the privacy of encryption and causes great interference to pirates. Brief description of the drawings
附图说明Description of the drawings
图1是本发明的数据示意图。Figure 1 is a schematic diagram of the data of the present invention.
发明实施例Invention embodiment
本发明的实施方式Embodiments of the present invention
本发明公开了一种通信加密方法,包括数据发送步骤和数据接收步骤,发射端 执行数据发送步骤,接收端执行数据接收步骤。The invention discloses a communication encryption method, which includes a data sending step and a data receiving step. The transmitting end executes the data sending step, and the receiving end executes the data receiving step.
所述数据发送步骤:发射端在发送正常数据包的时候,会按照发送规则进行随机发送扰乱包,扰乱包具有标志位,扰乱包的数据格式和正常数据包的数据格式相同,但扰乱包的指令数据是错误的;The data sending step: when sending a normal data packet, the transmitting end will randomly send the scrambled packet according to the sending rules. The scrambled packet has a flag bit. The data format of the scrambled packet is the same as that of the normal data packet, but the data format of the scrambled packet is the same as that of the normal data packet. The instruction data is wrong;
所述数据接收步骤:接收端通过识别扰乱包的标志位检测扰乱包,判断计数器是否达到了最大值,若在计数器没有达到最大值,且收到扰乱包后,那么执行处理步骤,并且计数器自动清零;如果计数器达到最大值,仍然没有检测到扰乱包,那么进行干扰处理;计数器与发送规则相匹配;The data receiving step: the receiving end detects the scrambled packet by identifying the flag bit of the scrambled packet, and determines whether the counter has reached the maximum value. If the counter does not reach the maximum value and the scrambled packet is received, then the processing steps are executed, and the counter is automatically Cleared to zero; if the counter reaches the maximum value and there is still no interference packet detected, then the interference processing is performed; the counter matches the sending rule;
处理步骤:对扰乱包进行处理,从而对正常数据进行正确识别。Processing steps: processing the disturbed packet, so as to correctly identify the normal data.
作为本发明的实施例,在数据发送步骤中,在发送正常数据包的时候,发送规则是在设定时间内随机发送扰乱包,例如在每隔10秒随机发送扰乱包,那么就有可能在第1个10秒内,在第2秒和第6秒各发送了一次扰乱包;在第2个10秒内,在第3秒、第7秒、第九秒各发送了一次扰乱包。在数据接收步骤中,计数器的最大值也同样是10秒,若计数器没有达到10秒,且收到扰乱包后,那么执行处理步骤,并且计数器自动清零;如果计数器达到10秒,仍然没有检测到扰乱包,那么进行干扰处理。As an embodiment of the present invention, in the data sending step, when sending a normal data packet, the sending rule is to randomly send a scrambled packet within a set time, for example, randomly send a scrambled packet every 10 seconds, then it is possible In the first 10 seconds, a scramble packet was sent in the second and sixth seconds; in the second 10 seconds, a scramble packet was sent in the third, seventh, and ninth seconds. In the data receiving step, the maximum value of the counter is also 10 seconds. If the counter does not reach 10 seconds and the jamming packet is received, the processing steps are executed and the counter is automatically cleared; if the counter reaches 10 seconds, there is still no detection When the jamming packet is reached, then the jamming process is performed.
作为本发明的优选实施例,在数据发送步骤中,在发送正常数据包的时候,发送规则是在设定的正常数据包状态切换次数内随机发送扰乱包,例如,设定的正常数据包状态切换次数为5次,第一个正常数据包是0010、第二个正常数据包是0100、第三个正常数据包是0011、第四个正常数据包是0101、第五个正常数据包是0110,由于五个正常数据包的状态都不相同,所以认为是正常数据包状态切换了5次,若具体应用到遥控车中,那么第一个正常数据包就表示遥控车前进,第二个正常数据包就表示遥控车后退,第三个正常数据包就表示遥控车左转,第四个正常数据包就表示遥控车右转,第五个正常数据包就表示遥控车停止;在正常数据包状态切换5次内,可以发送一次扰乱包,也可以发送两次扰乱包,所以是随机发送的扰乱包。在所述数据接收步骤中,判断接收端数据状态切换计数器是否达到了最大值也就是5次,若在接收端数据状态切换计数器没有达到最大值5次,且收到扰乱包后,那么执行处理步骤,并且接收端数据状态切 换计数器自动清零;如果接收端数据状态切换计数器达到最大值5次,仍然没有检测到扰乱包,那么进行干扰处理。As a preferred embodiment of the present invention, in the data sending step, when sending a normal data packet, the sending rule is to randomly send a scrambled packet within the set normal data packet state switching times, for example, the set normal data packet state The number of switching times is 5, the first normal data packet is 0010, the second normal data packet is 0100, the third normal data packet is 0011, the fourth normal data packet is 0101, and the fifth normal data packet is 0110 , Because the states of the five normal data packets are not the same, it is considered that the normal data packet state has been switched 5 times. If it is specifically applied to the remote control car, then the first normal data packet means that the remote control car is moving forward, and the second is normal The data packet means that the remote control car is going back, the third normal data packet means the remote control car turns left, the fourth normal data packet means the remote control car turns right, and the fifth normal data packet means the remote control car stops; in the normal data packet Within 5 times of state switching, a scrambled packet can be sent once or a scrambled packet can be sent twice, so it is a scrambled packet sent randomly. In the data receiving step, it is judged whether the data state switching counter at the receiving end has reached the maximum value, that is, 5 times. If the data state switching counter at the receiving end does not reach the maximum value 5 times, and after receiving the jamming packet, then perform processing Step, and the data state switching counter at the receiving end is automatically cleared; if the data state switching counter at the receiving end reaches the maximum value 5 times and the jamming packet is still not detected, then interference processing is performed.
在所述数据接收步骤中,干扰处理包括停机或者输出错误指令,输出错误指令以至于出现操作混乱。In the data receiving step, the interference processing includes stopping or outputting an error instruction, and outputting an error instruction so that operation disorder occurs.
当出现扰乱包时,有两种处理方式:When there is a disturbed packet, there are two ways to deal with it:
第一种处理方式:接收端将扰乱包删除或者不读取扰乱包。The first processing method: the receiving end deletes the scrambled packet or does not read the scrambled packet.
第二种处理方式:在所述数据发送步骤中,将正常数据包按照设定规则进行变化,从而将正常数据包变成扰乱包;在所述处理步骤中,将扰乱包按照设定规则进行变化,从而将扰乱包变成正常数据包;例如,正常数据包是0100,那么发射端将正常数据包0100按照设定规则进行全部取反为1011,从而将正常数据包变成扰乱包,然后发射端将正常数据包和扰乱包一起发给接收端;接收端检测到扰乱包后,按照设定规则将扰乱包1011全部取反为0100,从而将扰乱包变成正常数据包。采用第二种处理方式,可以降低接收端读取数据的延时,效果非常好。当然,设定规则也可以是对正常数据包的某一位取反,例如,对正常数据包是0100的最后一位取反,那么扰乱包就是0101,设定规则可以根据客户需要自行设定。The second processing method: in the data sending step, the normal data packet is changed according to the set rule, so that the normal data packet becomes a scrambled packet; in the processing step, the scrambled packet is processed according to the set rule Change, so as to turn the scrambled packet into a normal data packet; for example, if the normal data packet is 0100, then the transmitting end will reverse the normal data packet 0100 to 1011 according to the set rules, thereby turning the normal data packet into a scrambled packet, and then The transmitting end sends the normal data packet and the scrambled packet to the receiving end; after detecting the scrambled packet, the receiving end reverses all the scrambled packets 1011 to 0100 according to the set rules, thereby turning the scrambled packet into a normal data packet. The second processing method can reduce the delay of reading data at the receiving end, and the effect is very good. Of course, the setting rule can also be the inversion of a certain bit of the normal data packet. For example, if the last bit of 0100 is inverted for the normal data packet, then the scrambled packet is 0101. The setting rules can be set according to customer needs. .
本发明扰乱包的标志位不是一个很容易识别的数据,下面进行详细说明:扰乱包的标志位与正常数据包的标志位相比,二者的电平相同、形状相似,但是,二者的电平宽度不同;在数据接收步骤中,通过判断标志位的电平宽度来识别扰乱包。The flag bit of the scrambled packet of the present invention is not an easy-to-identify data. The following is a detailed description: Compared with the flag bit of the normal data packet, the flag bit of the scrambled packet has the same level and shape, but the electrical The level width is different; in the data receiving step, the jammed packet is identified by judging the level width of the flag bit.
也就是说扰乱包的标志位与正常数据包的标志位的电平相同、形状相似,但是扰乱包的标志位与正常数据包的标志位的电平宽度是不同的,所以,扰乱包的标志位不具有突出的不同特征,不容易被盗版者轻易识别,这是一个很重要的特点。本发明中,在数据接收步骤中,通过判断标志位的电平宽度来识别扰乱包,例如正常数据包的标志位宽度是500us,扰乱包的标志位宽度是550us或600us,那么,在数据接收步骤中,当检测到标志位宽度是500us时则认定是正常数据包,当检测到标志位宽度是550us或600us则认定是扰乱包。That is to say, the flag bit of the scrambled packet has the same level and shape as the flag bit of the normal data packet, but the flag bit of the scrambled packet and the flag bit of the normal data packet have different level widths, so the flag of the scrambled packet Bits do not have outstanding different characteristics and cannot be easily identified by pirates. This is a very important feature. In the present invention, in the data receiving step, the scrambled packet is identified by judging the level width of the flag bit. For example, the flag bit width of the normal data packet is 500us, and the flag bit width of the scrambled packet is 550us or 600us. Then, in the data receiving In the step, when it is detected that the width of the flag bit is 500 us, it is regarded as a normal data packet, and when it is detected that the width of the flag bit is 550 us or 600 us, it is regarded as a scrambled packet.
扰乱包的标志位,其宽度本身也携带了加密信息,比如:The flag bit of the scrambled packet, its width itself also carries encrypted information, such as:
在所述数据发送步骤中,通过扰乱包的标志位宽度确定加密方式,不同的扰乱包的标志位宽度代表不同的加密方式,根据对应的加密方式将正常数据包变成扰乱包;In the data sending step, the encryption method is determined by the flag bit width of the scrambled packet, and the flag bit widths of different scrambled packets represent different encryption methods, and the normal data packet is changed into a scrambled packet according to the corresponding encryption method;
在所述数据接收步骤中,通过扰乱包的标志位宽度确定解密方式,不同的扰乱包的标志位宽度代表不同的解密方式,在所述处理步骤中,根据对应的解密方式将扰乱包变成正常数据包。In the data receiving step, the decryption mode is determined by the flag bit width of the scrambled packet, and the flag bit widths of different scrambled packets represent different decryption methods. In the processing step, the scrambled packet is changed into Normal data packet.
例如:正常数据包的标志位宽度是:500us;For example: the flag bit width of a normal data packet is: 500us;
例1:扰乱包的标志位宽度是550us,在数据发送步骤中,通过扰乱包的标志位宽度550us确定加密方式为加密方式一(全部数据取反),根据加密方式一将正常数据包变成扰乱包,例如,正常数据:10110010,加密方式一数据:01001101(扰乱包)。在数据接收步骤中,通过扰乱包的标志位宽度550us确定解密方式为解密方式一(全部数据取反),在所述处理步骤中,根据解密方式一将扰乱数据包变成正常数据包,例如,将扰乱包01001101变成正常数据10110010。Example 1: The flag bit width of the scrambled packet is 550us. In the data sending step, the flag bit width 550us of the scrambled packet is used to determine that the encryption method is encryption method 1 (all data is reversed), and the normal data packet is changed to encryption method 1. The scrambled packet, for example, normal data: 10110010, encryption method one data: 01001101 (scrambling packet). In the data receiving step, the flag bit width of the scrambled packet is 550us to determine that the decryption mode is decryption mode 1 (all data is reversed). In the processing step, the scrambled data packet is transformed into a normal data packet according to the decryption mode 1, for example , The scrambled packet 01001101 becomes normal data 10110010.
例2:扰乱包的标志位宽度是600us,在数据发送步骤中,通过扰乱包的标志位宽度600us确定加密方式为加密方式二(奇数位数据取反,偶数位数据保持原状),根据加密方式二将正常数据包变成扰乱包,例如,正常数据:10110010,加密方式二数据:00011001(扰乱包)。在数据接收步骤中,通过扰乱包的标志位宽度600us确定解密方式为解密方式二(奇数位数据取反,偶数位数据保持原状),在所述处理步骤中,根据解密方式二将扰乱数据包变成正常数据包,例如,将扰乱包00011001变成正常数据10110010。Example 2: The flag bit width of the scrambled packet is 600us. In the data transmission step, the flag bit width 600us of the scrambled packet is used to determine the encryption method as encryption method two (odd-bit data is reversed, even-bit data remains intact), according to the encryption method Second, the normal data packet is turned into a scrambled packet, for example, normal data: 10110010, encryption method two data: 00011001 (scrambling packet). In the data receiving step, the decryption mode is determined to be decryption mode 2 by the flag bit width 600us of the scrambled packet (the odd-numbered data is inverted, and the even-numbered data is kept as it is). In the processing step, the scrambled data packet will be scrambled according to the decryption mode 2 It becomes a normal data packet, for example, the scrambled packet 00011001 becomes normal data 10110010.
例3:扰乱包的标志位宽度是450us,在数据发送步骤中,通过扰乱包的标志位宽度450us确定加密方式为加密方式三(偶数位数据取反,奇数位数据保持原状),根据加密方式三将正常数据包变成扰乱包,例如,正常数据:10110010,加密方式三数据:11100111(扰乱包)。在数据接收步骤中,通过扰乱包的标志位宽度450us确定解密方式为解密方式三(偶数位数据取反,奇数位数据保持原状),在所述处理步骤中,根据解密方式三将扰乱数据包变成正常数据包,例如,将扰乱包11100111变成正常数据10110010。Example 3: The flag bit width of the scrambled packet is 450us. In the data transmission step, the encryption method is determined by the flag bit width 450us of the scrambled packet as encryption method three (even-digit data is inverted, and odd-digit data remains intact), according to the encryption method Third, the normal data packet is turned into a scrambled packet, for example, normal data: 10110010, and encryption method three data: 11100111 (scrambling packet). In the data receiving step, the decryption mode is determined to be decryption mode 3 (even-numbered data is inverted, and odd-numbered data is kept as it is) through the flag bit width 450us of the scrambled packet. In the processing step, the data packet is scrambled according to decryption mode three. It becomes a normal data packet, for example, the scrambled packet 11100111 becomes normal data 10110010.
通过上述实施例可以看出,按照这种方式,可以延伸很多种加密手段,增加破 解的难度系数。It can be seen from the above embodiments that, in this way, many encryption methods can be extended to increase the difficulty coefficient of the decryption.
综上,本发明的通信加密方法不再把重点放在对数据包的处理上,而是在正常数据变化时随机附加发送扰乱包,这种随机的、暂时性的数据变化很难通过示波器或者逻辑分析仪捕捉到有效数据,盗版者往往会忽略掉这个数据。发射端会有一个数据状态切换计数器,会在一定数量的数据状态切换后随机发送扰乱包,而且扰乱包的数据格式是和正常数据包是一致的,区别在于扰乱包的指令数据是错误的。正版的解码IC,通过识别扰乱包标志位可以把扰乱包过滤掉,而盗版的解码IC就会把扰乱包的指令当正常的数据来处理而出现操作紊乱的现象。例如,一个遥控车产品,遥控器就是发射端,遥控车就是接收端,发射端会发送前进码、后退码、左转码,如果是正版的接收端,那么前进后退的切换是反应迅速且不会出现其他情况,而盗版的接收端就会发现在操作前进后退时,会不时的出现遥控车突然左拐或者右拐的现象,没有规律可寻。To sum up, the communication encryption method of the present invention no longer focuses on the processing of data packets, but randomly sends disturbed packets when normal data changes. Such random and temporary data changes are difficult to pass through the oscilloscope or The logic analyzer captures valid data, and pirates often ignore this data. The transmitter will have a data state switching counter, which will randomly send a scrambled packet after a certain number of data state switches, and the data format of the scrambled packet is the same as the normal data packet, the difference is that the command data of the scrambled packet is wrong. The genuine decoding IC can filter out the disturbed packet by identifying the flag bit of the disturbed packet, while the pirated decoding IC will treat the instruction of the disturbed packet as normal data to process the operation disorder. For example, for a remote control car product, the remote control is the transmitter, and the remote control car is the receiver. The transmitter will send forward code, backward code, and left turn code. If it is a genuine receiver, the forward and backward switching is quick and unresponsive. There will be other situations, and the receiving end of the pirated version will find that when the operation is moving forward and backward, the remote control car will suddenly turn left or right from time to time, and there is no pattern to find.
本发明还公开了一种通信加密系统,包括数据发送模块和数据接收模块,所述数据发送模块:用于在发送正常数据包的时候,按照发送规则进行随机发送扰乱包,扰乱包具有标志位,扰乱包的数据格式和正常数据包的数据格式相同,但扰乱包的指令数据是错误的;The present invention also discloses a communication encryption system, which includes a data sending module and a data receiving module. The data sending module is used to randomly send a scrambled packet according to the sending rule when a normal data packet is sent, and the scrambled packet has a flag bit. , The data format of the scrambled packet is the same as that of the normal data packet, but the command data of the scrambled packet is wrong;
所述数据接收模块:用于通过识别扰乱包的标志位检测扰乱包,判断计数器是否达到了最大值,若在计数器没有达到最大值,且收到扰乱包后,那么执行处理模块,并且计数器自动清零;如果计数器达到最大值,仍然没有检测到扰乱包,那么进行干扰处理;计数器与发送规则相匹配;The data receiving module is used to detect the scrambled packet by identifying the flag bit of the scrambled packet, and determine whether the counter has reached the maximum value. If the counter does not reach the maximum value and the scrambled packet is received, the processing module is executed and the counter is automatically Cleared to zero; if the counter reaches the maximum value and there is still no interference packet detected, then the interference processing is performed; the counter matches the sending rule;
处理模块:用于对扰乱包进行处理,从而对正常数据进行正确识别。Processing module: used to process disturbed packets, so as to correctly identify normal data.
在所述数据发送模块中,通过发射端数据状态切换计数器记录正常数据包状态切换次数,在设定的正常数据包状态切换次数内随机发送扰乱包,扰乱包具有标志位,扰乱包的数据格式和正常数据包的数据格式相同,但扰乱包的指令数据是错误的;In the data sending module, the normal data packet state switching times are recorded by the transmitting end data state switching counter, and the scrambled packet is randomly sent within the set normal data packet state switching times. The scrambled packet has a flag bit and the data format of the scrambled packet The data format of the normal data packet is the same, but the command data of the disturbed packet is wrong;
在所述数据接收模块中,所述计数器为接收端数据状态切换计数器,通过识别扰乱包的标志位检测扰乱包,判断接收端数据状态切换计数器是否达到了最大值,若在接收端数据状态切换计数器没有达到最大值,且收到扰乱包后,那么 执行处理模块,并且接收端数据状态切换计数器自动清零;如果接收端数据状态切换计数器达到最大值,仍然没有检测到扰乱包,那么进行干扰处理;In the data receiving module, the counter is a data state switching counter at the receiving end. The scrambled packet is detected by identifying the flag bit of the scrambled packet to determine whether the data state switching counter at the receiving end has reached the maximum value. After the counter has not reached the maximum value and the scrambled packet is received, the processing module is executed, and the data state switching counter at the receiving end is automatically cleared; if the data state switching counter at the receiving end reaches the maximum value, the scrambled packet is still not detected, then interference deal with;
其中,发射端数据状态切换计数器设定的正常数据包状态切换次数与接收端数据状态切换计数器设定的最大值相同。Among them, the normal data packet state switching times set by the transmitting end data state switching counter are the same as the maximum value set by the receiving end data state switching counter.
在所述处理模块中,将扰乱包删除或者不读取扰乱包。In the processing module, the scrambled packet is deleted or the scrambled packet is not read.
在所述数据发送模块中,将正常数据包按照设定规则进行变化,从而将正常数据包变成扰乱包;In the data sending module, the normal data packet is changed according to the set rule, thereby turning the normal data packet into a scrambled packet;
在所述处理模块中,将扰乱包按照设定规则进行变化,从而将扰乱包变成正常数据包。In the processing module, the scrambled packet is changed according to the set rule, so that the scrambled packet becomes a normal data packet.
本发明还公开了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序配置为由处理器调用时实现本发明所述的通信加密方法的步骤。The present invention also discloses a computer-readable storage medium, the computer-readable storage medium stores a computer program, and the computer program is configured to implement the steps of the communication encryption method of the present invention when called by a processor.
本发明的技术优势:盗版者一般会把注意力放在每一包数据的结构上,而忽视了每包数据状态切换时情况,把扰乱包当成正常数据使用,而且扰乱包还是随机性、快速性的,极大地增加了加密的隐秘性,对盗版者造成了极大干扰。The technical advantages of the present invention: pirates generally pay attention to the structure of each packet of data, and ignore the situation when the state of each packet is switched, and use the disturbed packet as normal data, and the disturbed packet is still random and fast Sexual, greatly increasing the privacy of encryption and causing great interference to pirates.
以上内容是结合具体的优选实施方式对本发明所作的进一步详细说明,不能认定本发明的具体实施只局限于这些说明。对于本发明所属技术领域的普通技术人员来说,在不脱离本发明构思的前提下,还可以做出若干简单推演或替换,都应当视为属于本发明的保护范围。The above content is a further detailed description of the present invention in combination with specific preferred embodiments, and it cannot be considered that the specific implementation of the present invention is limited to these descriptions. For those of ordinary skill in the technical field to which the present invention belongs, a number of simple deductions or substitutions can be made without departing from the concept of the present invention, which should be regarded as falling within the protection scope of the present invention.

Claims (10)

  1. 一种通信加密方法,其特征在于,包括数据发送步骤和数据接收步骤,所述数据发送步骤:在发送正常数据包的时候,按照发送规则进行随机发送扰乱包,扰乱包具有标志位,扰乱包的数据格式和正常数据包的数据格式相同,但扰乱包的指令数据是错误的;A communication encryption method, characterized in that it includes a data sending step and a data receiving step. The data sending step: when sending a normal data packet, randomly sending a scrambled packet according to a sending rule, the scrambled packet has a flag bit, and the scrambled packet The data format of is the same as the data format of the normal data packet, but the command data of the disturbed packet is wrong;
    所述数据接收步骤:通过识别扰乱包的标志位检测扰乱包,判断计数器是否达到了最大值,若在计数器没有达到最大值,且收到扰乱包后,那么执行处理步骤,并且计数器自动清零;如果计数器达到最大值,仍然没有检测到扰乱包,那么进行干扰处理;计数器与发送规则相匹配;The data receiving step: detect the scrambled packet by identifying the flag bit of the scrambled packet, and determine whether the counter has reached the maximum value. If the counter has not reached the maximum value and the scrambled packet is received, the processing steps are executed and the counter is automatically cleared. ; If the counter reaches the maximum value, and there is still no interference packet detected, then the interference processing is performed; the counter matches the sending rule;
    处理步骤:对扰乱包进行处理,从而对正常数据进行正确识别。Processing steps: processing the disturbed packet, so as to correctly identify the normal data.
  2. 根据权利要求1所述的通信加密方法,其特征在于,扰乱包的标志位与正常数据包的标志位相比,二者的电平相同,但是,二者的电平宽度不同;在数据接收步骤中,通过判断标志位的电平宽度来识别扰乱包。The communication encryption method according to claim 1, wherein the flag bit of the scrambled packet has the same level as the flag bit of the normal data packet, but the level width of the two is different; in the data receiving step In, by judging the level width of the flag bit to identify the disturbed packet.
  3. 根据权利要求1所述的通信加密方法,其特征在于,在所述数据发送步骤中,通过发射端数据状态切换计数器记录正常数据包状态切换次数,在设定的正常数据包状态切换次数内随机发送扰乱包,扰乱包具有标志位,扰乱包的数据格式和正常数据包的数据格式相同,但扰乱包的指令数据是错误的;The communication encryption method according to claim 1, characterized in that, in the data sending step, the number of normal packet state switching is recorded by the transmitting end data state switching counter, and the number of normal packet state switching is random within the set number of normal packet state switching. Send a scrambled packet, the scrambled packet has a flag bit, the data format of the scrambled packet is the same as the data format of the normal data packet, but the command data of the scrambled packet is wrong;
    在所述数据接收步骤中,所述计数器为接收端数据状态切换计数器,通过识别扰乱包的标志位检测扰乱包,判断接收端数据状态切换计数器是否达到了最大值,若在接收端数据状态切换计数器没有达到最大值,且收到扰乱包后,那么执行处理步骤,并且接收端数据状态切换计数器自动清零;如果接收端数据状态切换计数器达到最大值,仍然没有检测到扰乱包,那么进行干扰处理;其中,发射端数据状态切换计数器设定的正常数据包状态切换次 数与接收端数据状态切换计数器设定的最大值相同。In the data receiving step, the counter is a data state switching counter at the receiving end, the scrambled packet is detected by identifying the flag bit of the scrambled packet, and it is judged whether the data state switching counter at the receiving end has reached the maximum value, if the data state switching at the receiving end After the counter has not reached the maximum value and the scrambled packet is received, the processing steps are executed, and the data state switching counter at the receiving end is automatically cleared; if the data state switching counter at the receiving end reaches the maximum value, the scrambled packet is still not detected, then interference Processing: Among them, the normal data packet state switching times set by the transmitting end data state switching counter are the same as the maximum value set by the receiving end data state switching counter.
  4. 根据权利要求1所述的通信加密方法,其特征在于,在所述数据接收步骤中,干扰处理包括停机或者输出错误指令,输出错误指令以至于出现操作混乱。The communication encryption method according to claim 1, characterized in that, in the data receiving step, the interference processing includes stopping or outputting an error instruction, outputting an error instruction so that operation disorder occurs.
  5. 根据权利要求1至4任一项所述的通信加密方法,其特征在于,在所述处理步骤中,将扰乱包删除或者不读取扰乱包。The communication encryption method according to any one of claims 1 to 4, wherein in the processing step, the scrambled packet is deleted or the scrambled packet is not read.
  6. 根据权利要求2至4任一项所述的通信加密方法,其特征在于,在所述数据发送步骤中,将正常数据包按照设定规则进行变化,从而将正常数据包变成扰乱包;The communication encryption method according to any one of claims 2 to 4, characterized in that, in the data sending step, the normal data packet is changed according to a set rule, thereby turning the normal data packet into a scrambled packet;
    在所述处理步骤中,将扰乱包按照设定规则进行变化,从而将扰乱包变成正常数据包。In the processing steps, the scrambled packet is changed according to the set rule, so that the scrambled packet is changed into a normal data packet.
  7. 根据权利要求6所述的通信加密方法,其特征在于:The communication encryption method according to claim 6, characterized in that:
    在所述数据发送步骤中,通过扰乱包的标志位宽度确定加密方式,不同的扰乱包的标志位宽度代表不同的加密方式,根据对应的加密方式将正常数据包变成扰乱包;In the data sending step, the encryption method is determined by the flag bit width of the scrambled packet, and the flag bit widths of different scrambled packets represent different encryption methods, and the normal data packet is changed into a scrambled packet according to the corresponding encryption method;
    在所述数据接收步骤中,通过扰乱包的标志位宽度确定解密方式,不同的扰乱包的标志位宽度代表不同的解密方式,在所述处理步骤中,根据对应的解密方式将扰乱包变成正常数据包。In the data receiving step, the decryption mode is determined by the flag bit width of the scrambled packet, and the flag bit widths of different scrambled packets represent different decryption methods. In the processing step, the scrambled packet is changed into Normal data packet.
  8. 一种通信加密系统,其特征在于,包括数据发送模块和数据接收模块,所述数据发送模块:用于在发送正常数据包的时候,按照发送规则进行随机发送扰乱包,扰乱包具有标志位,扰乱包的数据格式和正常数据包的数据格式相同,但扰乱包的指令数据是错误的;A communication encryption system, characterized by comprising a data sending module and a data receiving module, the data sending module is used to randomly send a scrambled packet according to the sending rules when sending a normal data packet, and the scrambled packet has a flag bit, The data format of the scrambled packet is the same as that of the normal data packet, but the command data of the scrambled packet is wrong;
    所述数据接收模块:用于通过识别扰乱包的标志位检测扰乱包,判断计数器是否达到了最大值,若在计数器没有达到最大值,且收到扰乱包后,那么执行处理模块,并且计数器自动清零;如果计数器达到最大值,仍然没有检测到扰乱包,那么进行干扰处理;计数器与发送规则相匹配;The data receiving module is used to detect the scrambled packet by identifying the flag bit of the scrambled packet, and determine whether the counter has reached the maximum value. If the counter does not reach the maximum value and the scrambled packet is received, the processing module is executed and the counter is automatically Cleared to zero; if the counter reaches the maximum value and there is still no interference packet detected, then the interference processing is performed; the counter matches the sending rule;
    处理模块:用于对扰乱包进行处理,从而对正常数据进行正确识别。Processing module: used to process disturbed packets, so as to correctly identify normal data.
  9. 根据权利要求8所述的通信加密系统,其特征在于,扰乱包的标志位与正常数据包的标志位相比,二者的电平相同,但是,二者的电平宽度不同;在数据接收步骤中,通过判断标志位的电平宽度来识别扰乱包。The communication encryption system according to claim 8, wherein the flag bit of the scrambled packet has the same level as the flag bit of the normal data packet, but the level width of the two is different; in the data receiving step In, by judging the level width of the flag bit to identify the disturbed packet.
  10. 根据权利要求9所述的通信加密系统,其特征在于,在所述数据发送模块中,通过扰乱包的标志位宽度确定加密方式,不同的扰乱包的标志位宽度代表不同的加密方式,根据对应的加密方式将正常数据包变成扰乱包;The communication encryption system according to claim 9, characterized in that, in the data sending module, the encryption method is determined by the flag bit width of the scrambled packet, and the flag bit width of different scrambled packets represents different encryption methods. The encryption method turns normal data packets into scrambled packets;
    在所述数据接收模块中,通过扰乱包的标志位宽度确定解密方式,不同的扰乱包的标志位宽度代表不同的解密方式,在所述处理模块中,根据对应的解密方式将扰乱包变成正常数据包。In the data receiving module, the decryption mode is determined by the flag bit width of the scrambled packet, and the flag bit widths of different scrambled packets represent different decryption methods. In the processing module, the scrambled packet is changed into Normal data packet.
PCT/CN2019/120974 2019-11-26 2019-11-26 Communication encryption method and system WO2021102687A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/CN2019/120974 WO2021102687A1 (en) 2019-11-26 2019-11-26 Communication encryption method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2019/120974 WO2021102687A1 (en) 2019-11-26 2019-11-26 Communication encryption method and system

Publications (1)

Publication Number Publication Date
WO2021102687A1 true WO2021102687A1 (en) 2021-06-03

Family

ID=76129076

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/120974 WO2021102687A1 (en) 2019-11-26 2019-11-26 Communication encryption method and system

Country Status (1)

Country Link
WO (1) WO2021102687A1 (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1522069A (en) * 2003-02-14 2004-08-18 清华大学 A method for preventing illegal broadcasting in cable digital TV broadcasting
CN101572795A (en) * 2002-01-02 2009-11-04 索尼电子有限公司 Partial encryption and PID mapping
CN105516021A (en) * 2015-12-23 2016-04-20 北京广密华安科技有限公司 Communication method avoiding p2p traffic identification
EP3154217A1 (en) * 2015-10-08 2017-04-12 The Boeing Company Scrambled tweak mode of block ciphers for differential power analysis resistant encryption

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101572795A (en) * 2002-01-02 2009-11-04 索尼电子有限公司 Partial encryption and PID mapping
CN1522069A (en) * 2003-02-14 2004-08-18 清华大学 A method for preventing illegal broadcasting in cable digital TV broadcasting
EP3154217A1 (en) * 2015-10-08 2017-04-12 The Boeing Company Scrambled tweak mode of block ciphers for differential power analysis resistant encryption
CN105516021A (en) * 2015-12-23 2016-04-20 北京广密华安科技有限公司 Communication method avoiding p2p traffic identification

Similar Documents

Publication Publication Date Title
US9251549B2 (en) Watermark extractor enhancements based on payload ranking
US7133534B2 (en) Copy protection via redundant watermark encoding
CN1189036C (en) Use of a watermark for the purpose of copy protection
KR101334240B1 (en) System for transferring data only in one direction
JP2000242491A (en) Computer and program recording medium
JPWO2004105308A1 (en) Encrypted data receiving apparatus and decryption key updating method
WO2021102687A1 (en) Communication encryption method and system
KR102095911B1 (en) Digital content protection over audio return data link
WO2017076325A1 (en) Code stream playing method and apparatus
JP5148190B2 (en) Receiving method and receiving apparatus
US8140858B2 (en) Data processing apparatus
US20050160266A1 (en) Data retransmission device and method
CN104184746A (en) Method and device for processing data through gateway
US10705898B2 (en) Transmitting surreptitious data on an existing communication channel
WO2010120645A2 (en) Method and apparatus for secure configuration of electronic devices
JP4410217B2 (en) Digital watermark method
JP5201057B2 (en) Video transmission apparatus, authentication method, authentication program, and video transmission system
KR101679471B1 (en) Methods and apparatus for error rate estimation
US20200120132A1 (en) Method for an object to communicate with a connected objects network to report that a clone may be impersonating the object in the network
CN103201794A (en) Detection of watermarks in signals
WO2014128840A1 (en) Data relay device, network system and data relay method
US20030159049A1 (en) Copy-protection by alteration of control signals
EP2329451B1 (en) Method for constructing inner codes for anti-collusion forensic code for watermarking digital content
JP3467216B2 (en) Image decoding device
JP5053014B2 (en) Reception device and stream transmission device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19953993

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19953993

Country of ref document: EP

Kind code of ref document: A1

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 23.09.2022)

122 Ep: pct application non-entry in european phase

Ref document number: 19953993

Country of ref document: EP

Kind code of ref document: A1