CN117811837B - Unidirectional data transmission system with high privacy security - Google Patents

Unidirectional data transmission system with high privacy security Download PDF

Info

Publication number
CN117811837B
CN117811837B CN202410224103.XA CN202410224103A CN117811837B CN 117811837 B CN117811837 B CN 117811837B CN 202410224103 A CN202410224103 A CN 202410224103A CN 117811837 B CN117811837 B CN 117811837B
Authority
CN
China
Prior art keywords
data
decoding
dimensional code
fragment
ary
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.)
Active
Application number
CN202410224103.XA
Other languages
Chinese (zh)
Other versions
CN117811837A (en
Inventor
荣杰
蔡俊彬
欧文杰
张梓昊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangzhou Tianjing Intelligent Technology Co ltd
Original Assignee
Guangzhou Tianjing Intelligent Technology Co ltd
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 Guangzhou Tianjing Intelligent Technology Co ltd filed Critical Guangzhou Tianjing Intelligent Technology Co ltd
Priority to CN202410224103.XA priority Critical patent/CN117811837B/en
Publication of CN117811837A publication Critical patent/CN117811837A/en
Application granted granted Critical
Publication of CN117811837B publication Critical patent/CN117811837B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/04Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks
    • H04L63/0428Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks wherein the data content is protected, e.g. by encrypting or encapsulating the payload
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06KGRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
    • G06K19/00Record carriers for use with machines and with at least a part designed to carry digital markings
    • G06K19/06Record carriers for use with machines and with at least a part designed to carry digital markings characterised by the kind of the digital marking, e.g. shape, nature, code
    • G06K19/06009Record carriers for use with machines and with at least a part designed to carry digital markings characterised by the kind of the digital marking, e.g. shape, nature, code with optically detectable marking
    • G06K19/06037Record carriers for use with machines and with at least a part designed to carry digital markings characterised by the kind of the digital marking, e.g. shape, nature, code with optically detectable marking multi-dimensional coding
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06KGRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
    • G06K7/00Methods or arrangements for sensing record carriers, e.g. for reading patterns
    • G06K7/10Methods or arrangements for sensing record carriers, e.g. for reading patterns by electromagnetic radiation, e.g. optical sensing; by corpuscular radiation
    • G06K7/14Methods or arrangements for sensing record carriers, e.g. for reading patterns by electromagnetic radiation, e.g. optical sensing; by corpuscular radiation using light without selection of wavelength, e.g. sensing reflected white light
    • G06K7/1404Methods for optical code recognition
    • G06K7/1408Methods for optical code recognition the method being specifically adapted for the type of code
    • G06K7/14172D bar codes
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/004Arrangements for detecting or preventing errors in the information received by using forward error control
    • H04L1/0056Systems characterized by the type of code used
    • H04L1/0061Error detection codes
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/04Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks
    • H04L63/0428Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks wherein the data content is protected, e.g. by encrypting or encapsulating the payload
    • H04L63/0442Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks wherein the data content is protected, e.g. by encrypting or encapsulating the payload wherein the sending and receiving network entities apply asymmetric encryption, i.e. different keys for encryption and decryption
    • 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
    • H04L9/40Network security protocols
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L2463/00Additional details relating to network architectures or network communication protocols for network security covered by H04L63/00
    • H04L2463/062Additional details relating to network architectures or network communication protocols for network security covered by H04L63/00 applying encryption of the keys

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Artificial Intelligence (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Toxicology (AREA)
  • General Health & Medical Sciences (AREA)
  • Electromagnetism (AREA)
  • Health & Medical Sciences (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)
  • Detection And Prevention Of Errors In Transmission (AREA)

Abstract

The invention discloses a unidirectional data transmission system with high privacy security, which comprises: the device comprises a coding end, a screen display end, an image acquisition end, a decoding end and a data processing end; the method comprises the steps that a coding end segments transmission data and carries out hash value processing, a first coding rule is adopted for segment data and hash values to generate first two-dimensional code data, a screen display end displays the two-dimensional codes frame by frame, an image acquisition end captures and transmits the two-dimensional codes to a decoding end for decoding, segment check data and decoding content are obtained, a data processing end judges whether decoding is successful or not according to a check result, and decoding data are gradually integrated to restore original information. If decoding fails, the encoding end generates a second two-dimensional code with larger code element size by using a second encoding rule. According to the invention, the redundant module is abandoned and the check code is combined, so that the efficient and accurate coding of the data fragments is realized, and the code element size of the two-dimensional code is increased only when verification fails, thereby improving the data storage capacity while ensuring the data accuracy.

Description

Unidirectional data transmission system with high privacy security
Technical Field
The invention relates to the technical field of data ferry transmission, in particular to a unidirectional data transmission system with high privacy security.
Background
In the current network information security field, particularly in the process of realizing data unidirectional transmission among networks with different security levels, a two-dimensional code ferrying system is gradually and widely focused and applied as an innovative security isolation technical solution. Traditional data exchange methods often face data transmission bottlenecks and potential security risks caused by physical isolation of internal and external networks.
The existing two-dimensional code ferrying system generally adopts a QR two-dimensional code as a data carrier, the QR two-dimensional code has a fine structure design, and a plurality of functional modules are included to ensure accurate transmission and decoding of information. The detection graph (FINDER PATTERNS) is used for determining the position and the direction of the two-dimensional code; the time sequence graph (TIMING PATTERNS) is used for assisting the pixel comparison in the calibration and reading process of the scanning equipment; meanwhile, the built-in error correction module (Error Correction Codes, ECC) enables original information content to be successfully restored even if the two-dimensional code is damaged or polluted to a certain extent, and fault tolerance of the system is enhanced.
However, in a specific professional application scenario, such as a two-dimensional code ferrying system designed specially for internal data transmission, the problem of the conventional use scenario such as outdoor illumination change, partial shielding and the like is not faced. In such a professional environment, the functional modules included in the conventional QR two-dimensional code are not all applicable, and even functional redundancy may occur. For example, for a stable and controlled professional ferry system, highly complex error correction mechanisms may appear relatively superfluous as there is no serious light impact and physical damage risk, while the data space occupied by the excessive error correction and auxiliary positioning patterns may instead limit the storage capacity of the effective information.
Disclosure of Invention
In order to solve at least one technical problem, the invention provides a unidirectional data transmission system with high privacy security, which solves the problem that the transmission efficiency is low under the condition that the transmission accuracy of the traditional two-dimensional code system is ensured.
In one aspect, a unidirectional data transmission system with high privacy security is provided, including: the device comprises a coding end, a screen display end, an image acquisition end, a decoding end and a data processing end;
The encoding end is used for carrying out slicing processing on the data to be transmitted to obtain a plurality of original sliced data, carrying out hash value processing on each original sliced data to obtain original sliced check data, and carrying out encoding processing on the original sliced data and the original sliced check data by adopting a first encoding rule to obtain first two-dimensional code data;
The screen display end receives and displays the first two-dimensional code data frame by frame, and displays at least one piece of the first two-dimensional code data per frame;
the image acquisition end is used for acquiring the first two-dimensional code data displayed by the screen display end, transmitting the first two-dimensional code data to the decoding end for decoding to obtain first fragment checking data and fragment decoding data, and transmitting the first fragment checking data and the fragment decoding data to the data processing end;
The data processing end is used for judging whether the decoding is successful or not according to the first fragment checking data and the fragment decoding data; if the decoding is successful, integrating the currently obtained sliced decoding data with the spliced result at the previous moment until the sliced decoding data are integrated, and obtaining final decoding data; if decoding fails, the encoding end is controlled to encode the current original sliced data by adopting a second encoding rule to obtain second two-dimensional code data, and the code element size of the second two-dimensional code data is larger than that of the first two-dimensional code data;
The screen display end receives and displays the second two-dimensional code data frame by frame, the image acquisition end acquires the second two-dimensional code data and transmits the second two-dimensional code data to the decoding end for decoding, the data processing end judges whether decoding is successful or not according to a decoding result, if the decoding is successful, the decoding result is integrated and transmitted at the next moment, and if the decoding is failed, a transmission pause mechanism is triggered and an early warning mechanism is started.
Preferably, the method for determining whether decoding is successful according to the first slice checking data and the slice decoding data includes:
The hash value processing is carried out on the piece of decoding data to obtain second piece of checking data;
Judging whether the first piece of check data is consistent with the second piece of check data, if so, determining that the decoding is successful, and if not, determining that the decoding is failed.
Preferably, if the decoding fails, the controlling the encoding end to encode the current original slice data by using a second encoding rule to obtain second two-dimensional code data includes:
if decoding fails, the data processing end sends a secondary coding instruction to the coding end, wherein the secondary coding instruction carries the first fragment verification data;
The coding end determines original fragment data to be secondarily coded according to the first fragment verification data;
and the encoding end re-encodes the original fragment data by adopting a second encoding rule to obtain the second two-dimensional code data.
Preferably, the encoding processing is performed on the original slice data and the original slice verification data by using a first encoding rule to obtain first two-dimensional code data, including:
Performing M-ary encoding processing on the original fragment verification data and the original fragment data respectively to obtain fragment verification M-ary data and fragment M-ary data, wherein M is a natural number larger than 2;
And splicing the fragment checking M-ary data and the fragment M-ary data, and coloring the spliced result by adopting a preset M-ary color comparison table to obtain the first two-dimensional code data, wherein M colors respectively correspond to one value in M-ary in the preset M-ary color comparison table.
Preferably, before the concatenating the fragment verification M-ary data and the fragment M-ary data, the method further includes: performing redundancy processing on the fragment checking M-ary data, wherein the redundancy processing specifically comprises the following steps:
and performing N times expansion processing on each data unit of the fragment check M-ary data, and converting each data unit into N repeated data units, wherein N is a natural number larger than 1.
Preferably, the decoding process of the decoding end is as follows:
carrying out code element color recognition on the first two-dimensional code data to obtain a code element RGB color matrix ,/>Representation/>Row of linesRGB color values of the columns;
For the said Performing RGB Euclidean distance calculation and comparison with the colors in the M-ary color comparison table, and determining M-ary coding data corresponding to the color with the minimum RGB Euclidean distance as the/>M-ary coded data of the code pattern to obtain an M-ary data matrix;
And determining the size of the first fragmentation verification data according to the hash value processing, and splitting the M-ary data matrix according to the size of the first fragmentation verification data to obtain the first fragmentation verification data and the fragmentation decoding data.
Preferably, the RGB euclidean distance calculation is expressed as:
,
Wherein, Representing RGB Euclidean distance,/>、/>And/>Respectively express/>/>, In RGB color valuesValues,/>Value sum/>Value/>、/>And/>Respectively represent the/>, in the M-ary color comparison table/>, Of individual coloursValues,/>Value sum/>Value/>
Preferably, the system further comprises an encrypting end and a decrypting end,
The encryption terminal user performs asymmetric encryption on the data to be transmitted, and determines the encrypted data as the data to be transmitted;
and the decryption end decrypts the final decoded data by adopting a corresponding private key to obtain the final decoded data.
Preferably, the data processing end records the decoding failure times, and when the decoding failure times exceed a preset maximum decoding failure times threshold, triggers a transmission pause mechanism and starts an early warning mechanism.
Preferably, the decoding end further includes a preprocessing step before decoding the first two-dimensional code data or the second two-dimensional code data, and the preprocessing step includes:
and carrying out image enhancement processing on the acquired first two-dimensional code data, wherein the image enhancement processing comprises denoising, contrast enhancement, brightness adjustment and sharpening.
The invention has the beneficial effects that:
(1) By discarding the redundant module and combining the check code, the efficient and accurate coding of the data fragments is realized, the code element size of the two-dimensional code is increased only when verification fails, and the data storage capacity is improved while the data accuracy is ensured under most normal decoding conditions.
(2) At the encoding end, original sliced data and check data are respectively subjected to M-ary encoding by innovatively adopting a multicolor two-dimensional code technology, multicolor splicing is realized by utilizing a preset M-ary color comparison table, the data carrying capacity of each two-dimensional code is remarkably improved, the information storage density is greatly improved, and meanwhile, the high efficiency and the accuracy of data transmission and display are ensured.
(3) The redundancy processing is carried out on the check data pertinently, and the reliability and the robustness of the check data are obviously enhanced by expanding each unit of the fragmented check M-ary data into N times repeated data units; the strategy ensures that the problem can be quickly and accurately identified and corresponding measures can be taken when the verification fails, thereby effectively ensuring the decoding success rate and the data transmission accuracy of the whole system.
(4) According to the method, the color code elements of the first two-dimensional code data are efficiently converted into the M-ary data matrix through RGB Euclidean distance calculation, so that the decoding speed and accuracy of the multicolor two-dimensional code are effectively improved; meanwhile, the system intelligently determines the size of the check data according to the preset hash value and accurately splits the M-ary data matrix, so that the first sliced check data and the sliced decoding data are ensured to be rapidly separated, and the reliability and efficiency of the whole decoding process are greatly enhanced.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
In order to more clearly describe the embodiments of the present invention or the technical solutions in the background art, the following description will describe the drawings that are required to be used in the embodiments of the present invention or the background art.
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the disclosure and together with the description, serve to explain the principles of the disclosure.
Fig. 1 is a schematic flow chart of a unidirectional data transmission system with high privacy security according to an embodiment of the present invention;
FIG. 2 is a diagram illustrating a first two-dimensional code data structure according to an embodiment of the present invention;
fig. 3 is a schematic diagram of a second two-dimensional code data structure according to an embodiment of the present invention;
fig. 4 is a schematic diagram of a decoding success determination flow according to another embodiment of the present invention.
Detailed Description
In order that those skilled in the art will better understand the present invention, a technical solution in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
The terms first, second and the like in the description and in the claims and in the above-described figures are used for distinguishing between different objects and not necessarily for describing a sequential or chronological order. Furthermore, the terms "comprise" and "have," as well as any variations thereof, are intended to cover a non-exclusive inclusion. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those listed steps or elements but may include other steps or elements not listed or inherent to such process, method, article, or apparatus.
The term "and/or" is herein merely an association relationship describing an associated object, meaning that there may be three relationships, e.g., a and/or B, may represent: a exists alone, A and B exist together, and B exists alone. In addition, the term "at least one" herein means any one of a plurality or any combination of at least two of a plurality, for example, including at least one of A, B, C, may mean including any one or more elements selected from the group consisting of A, B and C.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment may be included in at least one embodiment of the invention. The appearances of such phrases in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those of skill in the art will explicitly and implicitly appreciate that the embodiments described herein may be combined with other embodiments.
Furthermore, in the following detailed description, numerous specific details are set forth in order to provide a better illustration of the invention. It will be understood by those skilled in the art that the present invention may be practiced without some of these specific details. In some instances, well known methods, procedures, components, and circuits have not been described in detail so as not to obscure the present invention.
At present, the conventional QR two-dimensional code data ferrying scheme has certain limitations. On the one hand, in order to ensure the integrity of data in the transmission process, even if the data is transmitted between internal networks in a controlled environment, a powerful error correction code mechanism is built in a standard QR two-dimensional code, and the error reading generated in the partial physical damage or scanning process can be effectively resisted, but the data redundancy is also caused to a certain extent, so that the actual storage capacity of each two-dimensional code is affected. On the other hand, since professional application scenarios generally have more stringent requirements on the security and efficiency of data exchange, such error correction redundancy may limit the payload size of each data ferry, thereby indirectly reducing the data transmission rate of the whole system. Especially in cases where a large number of files or large data blocks are required to be transferred frequently, relying too much on error correction codes to ensure data integrity may not meet the requirements of efficient, large capacity data migration.
Examples
There is provided a unidirectional data transmission system of high privacy security, referring to fig. 1, comprising: the device comprises a coding end, a screen display end, an image acquisition end, a decoding end and a data processing end;
the encoding end is used for carrying out slicing processing on the data to be transmitted to obtain a plurality of original sliced data, carrying out hash value processing on each original sliced data to obtain original sliced check data, and carrying out encoding processing on the original sliced data and the original sliced check data by adopting a first encoding rule to obtain first two-dimensional code data;
The screen display end receives and displays the first two-dimensional code data frame by frame, and the screen display end displays at least one first two-dimensional code data per frame;
the image acquisition end is used for acquiring the first two-dimensional code data displayed by the screen display end, transmitting the first two-dimensional code data to the decoding end for decoding to obtain first fragment checking data and fragment decoding data, and transmitting the first fragment checking data and the fragment decoding data to the data processing end;
the data processing end is used for judging whether the decoding is successful or not according to the first fragment checking data and the fragment decoding data; if the decoding is successful, integrating the currently obtained sliced decoded data with the spliced result at the previous moment until the sliced decoded data are integrated, and obtaining final decoded data; if decoding fails, the control encoding end adopts a second encoding rule to encode the current original sliced data to obtain second two-dimensional code data, and the code element size of the second two-dimensional code data is larger than that of the first two-dimensional code data;
The screen display end receives and displays the second two-dimensional code data frame by frame, the image acquisition end acquires the second two-dimensional code data and transmits the second two-dimensional code data to the decoding end for decoding, the data processing end judges whether the decoding is successful according to the decoding result, if the decoding is successful, the decoding result is integrated and transmitted at the next time, and if the decoding is failed, the transmission pause mechanism is triggered and the early warning mechanism is started.
The encoding end has the functions of data cutting, hash operation, data encoding and the like. In the data cutting stage, the coding end divides the whole data to be transmitted into a plurality of data blocks according to a preset size, and each data block is regarded as an independent data unit. And carrying out hash value calculation on each data unit and taking the hash value as check data, wherein the hash value is used for subsequently verifying the integrity and correctness of the data. In the encoding stage, the encoding end adopts a specific algorithm (such as an M-ary encoding rule) to convert the original data block and the corresponding hash check value thereof into first two-dimensional code data. For example, the file to be transferred is divided into hundreds of small data packets, each containing 1024 bytes of data. The encoding end adopts SHA-256 algorithm to generate a hash value with fixed length for each data packet. The encoding side then encodes the original data packet and its corresponding hash value into first two-dimensional code data using a particular encoding rule (e.g., M-ary encoding rule).
The screen presentation end may be a Liquid Crystal Display (LCD), an Organic Light Emitting Diode (OLED) screen, or any other type of display screen. The display screen can keep each first two-dimensional code data to appear for a time sufficient for the image acquisition end to accurately capture the image. The image acquisition end high-speed camera or special code scanning equipment is positioned right in front of the screen display end and is used for acquiring the two-dimensional code displayed on the screen, converting the captured two-dimensional code image into electronic information data and transmitting the data to the decoding end. The decoding end uses a decoding algorithm (such as M-ary decoding rule) and a checking mechanism matched with the encoding end to confirm the data integrity, and transmits the decoding result to the data processing end.
And the data processing end performs consistency verification according to the received first fragment verification data and fragment decoding data. And if the verification is successful, immediately splicing the current decoded segmented decoded data to the integrated data segment, and repeating the process until all segmented data are decoded and integrated into complete original data. If a certain slice is found to fail decoding in the decoding process, the data processing end immediately feeds back to the encoding end to request to re-encode the original slice data. At this time, the encoding end uses a second encoding rule to perform reinforcement encoding on the sliced data, and generates second two-dimensional code data with larger code element size so as to enhance the recognition degree and the fault tolerance. The subsequent transmission, display, collection and decoding flow of the second two-dimensional code data is consistent with the first two-dimensional code data.
In this embodiment, referring to fig. 2 and fig. 3, the symbol size of the second two-dimensional code data is increased to reduce the data storage amount of the single two-dimensional code, so that the decoding end can decode the original fragmented data more easily and successfully, while maintaining the unidirectional transmission high privacy security characteristic, the anti-interference capability and the error correction capability are improved remarkably, and under the condition of error transmission, the original data can be captured and restored accurately through recoding, thereby greatly improving the robustness and the practical application value of the system.
Preferably, for determining whether decoding is successful based on the first fragment verification data and the fragment decoding data, referring to fig. 4, the method includes:
Carrying out hash value processing on the fragment decoding data to obtain second fragment checking data;
judging whether the first piece of check data is consistent with the second piece of check data, if so, determining that the decoding is successful, and if not, determining that the decoding is failed.
In this embodiment, hash value calculation (MD 5) is performed on the decoded original binary data stream to generate corresponding second fragment verification data, where the data is a hash value with a fixed length and can uniquely represent the original data content, and the first fragment verification data obtained by decoding and the second fragment verification data obtained by re-hash value calculation are compared, and if the two are the same, decoding is correct, and if the two are different, decoding is failed. The successful decoding judgment is carried out by comparing the consistency of the first piece of check data and the second piece of check data, so that an error detection mechanism is simplified, the working efficiency of the whole system is improved, and efficient and accurate decoding and verification under a large data volume piece transmission scene are ensured.
Preferably, if decoding fails, the control encoding end adopts a second encoding rule to encode the current original slice data to obtain second two-dimensional code data, including:
If decoding fails, the data processing end sends a secondary coding instruction to the coding end, wherein the secondary coding instruction carries first fragment verification data;
the coding end determines the original fragment data to be secondarily coded according to the first fragment verification data;
And the encoding end recodes the original fragment data by adopting a second encoding rule to obtain second two-dimensional code data.
In this embodiment, when the data processing end receives and tries to decode the first two-dimensional code data, if it is determined that decoding fails according to the hash check process, a secondary encoding instruction including the first slice check data is immediately sent to the encoding end, and the first slice check data generated by the first encoding is transmitted to the encoding end together as reference information. After receiving the secondary coding instruction from the data processing end, the coding end firstly locates and extracts the corresponding original fragment data according to the carried first fragment verification data. Since the first fragment verification data is a unique identifier obtained by performing hash operation on the original fragment data content, it is possible to ensure that the data block to be secondarily encoded is found accurately. The encoding end is switched to a preset second encoding rule to recode the determined original sliced data, and second two-dimensional code data aiming at the same original sliced data are generated. The second coding rule is reduced from high-density coding to low-density coding and enables the code element size of the generated two-dimensional code to be further increased so as to improve the anti-interference capability. By automatically triggering the secondary coding flow when decoding fails, the problem of data loss caused by decoding errors is avoided, and the fault tolerance performance and the data communication efficiency of the whole system are greatly improved by flexibly selecting different coding rules to adapt to the data transmission requirements under different scenes.
Preferably, the encoding processing is performed on the original slice data and the original slice verification data by adopting a first encoding rule to obtain first two-dimensional code data, including:
Respectively carrying out M-ary encoding processing on the original fragment verification data and the original fragment data to obtain fragment verification M-ary data and fragment M-ary data, wherein M is a natural number larger than 2;
And splicing the fragment checking M-ary data and the fragment M-ary data, and coloring the spliced result by adopting a preset M-ary color comparison table to obtain first two-dimensional code data, wherein M colors respectively correspond to one value in M-ary in the preset M-ary color comparison table.
In this embodiment, M-ary encoding is performed on the sliced data and the corresponding hash check data, where M represents a natural number greater than 2, and may be selected, for example, from 4, 8, 16, etc., according to the color coding requirements. The M-ary code uses richer color information, thereby improving the data density. After encoding, the fragment verification data and the original fragment data are integrated together, and a preset M-ary color comparison table is used for coloring the combined data to form first two-dimensional code data. Each color in the M-ary color comparison table uniquely corresponds to one value of the M-ary digital code, so that each color block of the two-dimensional code can carry more information than the traditional black-and-white two-dimensional code. For example, if 16-ary encoding is chosen, there will be 16 different colors, each of which maps to a 16-ary number from 0 to F. The encoded data are presented on the screen in these colors, captured by the image acquisition side and transmitted to the decoding side where they are decoded back into M-ary numbers and further converted back into the original data. If the decoding is successful, the data processing end starts to reorganize the fragment data, if decoding errors occur in the decoding process, an error recovery flow is triggered, and the fragment data is recoded by using a second coding rule which is easier to identify. More data are contained through different colors, so that the data transmission efficiency is improved, and meanwhile, the data transmission is more robust, and the method is convenient to adapt to various capturing conditions.
Preferably, referring to fig. 2, before concatenating the fragment check M-ary data and the fragment M-ary data, the method further includes: performing redundancy processing on the fragment checking M-ary data, wherein the redundancy processing comprises the following steps of:
And performing N times expansion processing on each data unit of the fragment check M-ary data, and converting each data unit into N repeated data units, wherein N is a natural number larger than 1.
In this embodiment, an additional data security measure is adopted, and before the multicolor two-dimensional code is generated, redundancy processing is applied to the fragmented parity data to enhance the robustness of the parity data. Specifically, N-fold expansion is performed on each of the fragment parity data units in M-ary, that is, each of the fragment parity data units is replicated N times to form N identical redundant data units, where N is a natural number greater than 1. For example, if an M-ary data unit of the original check data is "5" and the selected N value is 3, the data unit is expanded to "5-5-5" after redundancy processing. Similarly, each cell in the entire sliced parity M-ary data is subjected to such processing. After the N times of expansion processing is completed, the redundant check data and the M-ary coded original fragment data are spliced together according to a preset format. For another example, if one of the fragment parity data units is an M-ary number "3" and N is selected to be 4, then "3" would be redundantly processed as "3-3-3-3". When the decoding process occurs, the receiving end checks the redundant data units, and if one or more errors occur in the set of "3-3-3-3" (e.g., decoded as "3-3-2-3"), the error detection mechanism can still determine that the correct data unit value is "3" through the majority voting strategy, and determine the accuracy of the original fragmented data accordingly.
The reason for performing redundancy processing only on the check data is mainly to avoid unnecessary large-scale data duplication while ensuring data transmission reliability, thereby saving bandwidth and storage space. The method utilizes the importance and smaller volume of the check data to effectively detect and correct errors, reduces the extra burden brought by full data redundancy, and realizes the balance of data transmission efficiency and accuracy.
Preferably, the decoding process at the decoding end is as follows:
Carrying out code element color recognition on the first two-dimensional code data to obtain a code element RGB color matrix ,/>Representation/>Line/>RGB color values of the columns;
For a pair of Performing RGB Euclidean distance calculation and comparison with colors in an M-ary color comparison table, and determining M-ary coding data corresponding to the color with the minimum RGB Euclidean distance as/>M-ary coded data of the code pattern to obtain an M-ary data matrix;
And determining the size of the first fragmentation verification data according to the hash value processing, and splitting the M-ary data matrix according to the size of the first fragmentation verification data to obtain the first fragmentation verification data and the fragmentation decoding data.
Preferably, the RGB euclidean distance calculation is expressed as:
,
Wherein, Representing RGB Euclidean distance,/>、/>And/>Respectively express/>/>, In RGB color values of (c)Values,/>Value sum/>Value/>、/>And/>Respectively represent the/>, in the M-ary color comparison table/>, Of individual coloursValues,/>Value sum/>Value/>
In this embodiment, the decoding end performs symbol color recognition operation on the captured first two-dimensional code data, and by analyzing the two-dimensional code image, the color of each symbol is accurately detected and stored in the form of an RGB color matrix Z in which the elements in the matrixRefer to the RGB color values of the symbols located in the ith row and jth column in the first two-dimensional code. Decoding side for each/>And executing the calculation of the RGB Euclidean distance, and comparing the RGB Euclidean distance with the colors in a preset M-ary color comparison table. The look-up table associates color values with corresponding M-ary encoded data. By finding and/>The color with the minimum RGB Euclidean distance between the two can determine the corresponding M-ary coded data. This step allows a more accurate conversion of color into encoded data during decoding, resulting in a matrix of M-ary encoded data. Further, according to the hash value processing logic, the decoding end calculates the size of the first fragmentation checking data, and divides the M-ary data matrix according to the size of the first fragmentation checking data, so that the first fragmentation checking data and the rest fragmentation decoding data are obtained, and the data integrity and accuracy are effectively verified in the decoding process.
Preferably, the system further comprises an encrypting end and a decrypting end;
the encryption terminal user performs asymmetric encryption on the data to be transmitted, and determines the encrypted data as the data to be transmitted;
And the decryption end decrypts the final decoded data by adopting a corresponding private key to obtain the final decoded data.
In the embodiment, the MD5 algorithm is adopted, so that the hash abstract with fixed length can be rapidly generated due to high processing speed, and the data processing efficiency is improved; the algorithm implementation is popular and easy to integrate, and helps to reduce the cost of system implementation and development.
Preferably, the data processing end records the decoding failure times, and when the decoding failure times exceed a preset maximum decoding failure times threshold, triggers a transmission pause mechanism and starts an early warning mechanism.
In one possible embodiment, the data processing side presets a maximum decoding failure number threshold, which is determined based on the system performance requirements, network stability, or fault tolerance level of the application. When the cumulative failure number reaches the preset threshold, the data processing end automatically activates a transmission pause mechanism which instructs the system to stop the current data transmission process. At the same time, an early warning mechanism is started, and the mechanism comprises various types of alarms, such as visual or audible signals, sends error notification to system operation and maintenance personnel, or automatically triggers the system-level error diagnosis and recovery flow. The purpose of this mechanism is to prevent consecutive decoding errors from affecting overall data integrity and reliability of system operation, and to provide real-time problem feedback to system administrators or automation tools to facilitate prompt corrective action to maintain the system in its normal operating state.
Preferably, the decoding end further includes a preprocessing step before decoding the first two-dimensional code data or the second two-dimensional code data, and the preprocessing step includes:
and performing image enhancement processing on the acquired first two-dimensional code data, wherein the image enhancement processing comprises denoising, contrast enhancement, brightness adjustment and sharpening.
When preprocessing starts, firstly, a denoising algorithm is applied to the acquired first two-dimensional code image so as to remove noise introduced in the image capturing or transmitting process. After that, contrast enhancement processing is performed to highlight information features in the two-dimensional code image, so that boundaries and internal modes are more obvious. And then, adjusting the brightness to adapt to the recognition requirements under different illumination conditions, and ensuring that the dark area and the bright area of the two-dimensional code are in a proper brightness range. And finally, sharpening processing is carried out, so that the definition of details in the image, in particular the definition of positioning points and coding areas of the two-dimensional code, is enhanced. The series of enhancement processing steps can significantly improve the image quality, provide higher quality and easily identifiable image input for the subsequent decoding process, thereby improving the decoding success rate. In this way, the decoding end can more effectively process the first two-dimensional code and the second two-dimensional code data, and can maintain high-efficiency and accurate decoding performance even when the image acquisition condition is poor.
The foregoing is only a specific embodiment of the invention to enable those skilled in the art to understand or practice the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (6)

1. A high privacy security unidirectional data transmission system, comprising: the device comprises a coding end, a screen display end, an image acquisition end, a decoding end and a data processing end;
The encoding end is used for carrying out slicing processing on the data to be transmitted to obtain a plurality of original sliced data, carrying out hash value processing on each original sliced data to obtain original sliced check data, and carrying out encoding processing on the original sliced data and the original sliced check data by adopting a first encoding rule to obtain first two-dimensional code data;
The method comprises the steps of adopting a first coding rule to code original fragment data and the original fragment verification data to obtain first two-dimensional code data, and comprising the following steps:
Performing M-ary encoding processing on the original fragment verification data and the original fragment data respectively to obtain fragment verification M-ary data and fragment M-ary data, wherein M is a natural number larger than 2;
performing redundancy processing on the fragment checking M-ary data, wherein the redundancy processing specifically comprises the following steps:
Performing N times expansion processing on each data unit of the fragment check M-ary data, and converting each data unit into N repeated data units, wherein N is a natural number greater than 1;
Splicing the fragment checking M-ary data and the fragment M-ary data, and coloring the spliced result by adopting a preset M-ary color comparison table to obtain the first two-dimensional code data, wherein M colors respectively correspond to one value in M-ary in the preset M-ary color comparison table;
The screen display end receives and displays the first two-dimensional code data frame by frame, and displays at least one piece of the first two-dimensional code data per frame;
the image acquisition end is used for acquiring the first two-dimensional code data displayed by the screen display end, transmitting the first two-dimensional code data to the decoding end for decoding to obtain first fragment checking data and fragment decoding data, and transmitting the first fragment checking data and the fragment decoding data to the data processing end;
the decoding process of the decoding end is as follows:
carrying out code element color recognition on the first two-dimensional code data to obtain a code element RGB color matrix ,/>Representation/>Line/>RGB color values of the columns;
For the said Performing RGB Euclidean distance calculation and comparison with the colors in the M-ary color comparison table, and determining M-ary coding data corresponding to the color with the minimum RGB Euclidean distance as the/>M-ary coded data of the code pattern to obtain an M-ary data matrix;
determining the size of the first fragmentation verification data according to the hash value processing, and splitting the M-ary data matrix according to the size of the first fragmentation verification data to obtain the first fragmentation verification data and the fragmentation decoding data;
The RGB euclidean distance calculation is expressed as:
,
Wherein, Representing RGB Euclidean distance,/>、/>And/>Respectively express/>/>, In RGB color valuesValues,/>Value sum/>Value/>、/>And/>Respectively represent the/>, in the M-ary color comparison table/>, Of individual coloursValues,/>Value sum/>The value of the sum of the values,
The data processing end is used for judging whether the decoding is successful or not according to the first fragment checking data and the fragment decoding data; if the decoding is successful, integrating the currently obtained sliced decoding data with the spliced result at the previous moment until the sliced decoding data are integrated, and obtaining final decoding data; if decoding fails, the encoding end is controlled to encode the current original sliced data by adopting a second encoding rule to obtain second two-dimensional code data, and the code element size of the second two-dimensional code data is larger than that of the first two-dimensional code data;
The screen display end receives and displays the second two-dimensional code data frame by frame, the image acquisition end acquires the second two-dimensional code data and transmits the second two-dimensional code data to the decoding end for decoding, the data processing end judges whether decoding is successful or not according to a decoding result, if the decoding is successful, the decoding result is integrated and transmitted at the next moment, and if the decoding is failed, a transmission pause mechanism is triggered and an early warning mechanism is started.
2. The high privacy security unidirectional data transmission system of claim 1, wherein said means for determining whether decoding was successful based on said first sliced parity data and said sliced decoded data comprises:
The hash value processing is carried out on the piece of decoding data to obtain second piece of checking data;
Judging whether the first piece of check data is consistent with the second piece of check data, if so, determining that the decoding is successful, and if not, determining that the decoding is failed.
3. The unidirectional data transmission system of claim 2, wherein if decoding fails, the encoding end is controlled to encode the current original slice data by using a second encoding rule to obtain second two-dimensional code data, comprising:
if decoding fails, the data processing end sends a secondary coding instruction to the coding end, wherein the secondary coding instruction carries the first fragment verification data;
The coding end determines original fragment data to be secondarily coded according to the first fragment verification data;
and the encoding end re-encodes the original fragment data by adopting a second encoding rule to obtain the second two-dimensional code data.
4. The high privacy security unidirectional data transmission system of claim 1, further comprising an encryption side and a decryption side;
the encryption terminal user performs asymmetric encryption on the data to be transmitted, and determines the encrypted data as the data to be transmitted;
and the decryption end decrypts the final decoded data by adopting a corresponding private key to obtain the final decoded data.
5. The unidirectional data transmission system of claim 1, wherein the data processing terminal records a number of decoding failures, and when the number of decoding failures exceeds a preset maximum threshold of decoding failures, triggers a transmission suspension mechanism and starts an early warning mechanism.
6. The high privacy security unidirectional data transmission system of claim 1, wherein said decoding side further comprises a preprocessing step before decoding said first two-dimensional code data or said second two-dimensional code data, said preprocessing step comprising:
and carrying out image enhancement processing on the acquired first two-dimensional code data, wherein the image enhancement processing comprises denoising, contrast enhancement, brightness adjustment and sharpening.
CN202410224103.XA 2024-02-29 2024-02-29 Unidirectional data transmission system with high privacy security Active CN117811837B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410224103.XA CN117811837B (en) 2024-02-29 2024-02-29 Unidirectional data transmission system with high privacy security

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410224103.XA CN117811837B (en) 2024-02-29 2024-02-29 Unidirectional data transmission system with high privacy security

Publications (2)

Publication Number Publication Date
CN117811837A CN117811837A (en) 2024-04-02
CN117811837B true CN117811837B (en) 2024-05-28

Family

ID=90434861

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410224103.XA Active CN117811837B (en) 2024-02-29 2024-02-29 Unidirectional data transmission system with high privacy security

Country Status (1)

Country Link
CN (1) CN117811837B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007042054A (en) * 2005-06-27 2007-02-15 Systec:Kk Recoding one-dimensional/two-dimensional code, recoding one-dimensional/two-dimensional code system, recoding one-dimensional/two-dimensional code encoder and recoding one-dimensional/two-dimensional code decoder
JP2008084455A (en) * 2006-09-28 2008-04-10 Matsushita Electric Ind Co Ltd Error correcting method
CN106529633A (en) * 2015-09-10 2017-03-22 阿里巴巴集团控股有限公司 Two-dimensional code generation method and decoding method and device
CN110011993A (en) * 2019-03-25 2019-07-12 浩云科技股份有限公司 A kind of two dimensional code big data safe transmission device based on dynamic multi-level encryption and decryption
CN116405252A (en) * 2023-03-09 2023-07-07 无锡中盾科技有限公司 Two-dimensional code data unidirectional transmission method

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100511271C (en) * 2006-11-16 2009-07-08 深圳市天朗时代科技有限公司 Two-dimensional decoding method
US11861906B2 (en) * 2014-02-28 2024-01-02 Genius Sports Ss, Llc Data processing systems and methods for enhanced augmentation of interactive video content
US20220197652A1 (en) * 2020-12-22 2022-06-23 Intel Corporation Processors, methods, systems, and instructions to merge portions of two source two-dimensional arrays without explicit per-portion control

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007042054A (en) * 2005-06-27 2007-02-15 Systec:Kk Recoding one-dimensional/two-dimensional code, recoding one-dimensional/two-dimensional code system, recoding one-dimensional/two-dimensional code encoder and recoding one-dimensional/two-dimensional code decoder
JP2008084455A (en) * 2006-09-28 2008-04-10 Matsushita Electric Ind Co Ltd Error correcting method
CN106529633A (en) * 2015-09-10 2017-03-22 阿里巴巴集团控股有限公司 Two-dimensional code generation method and decoding method and device
CN110011993A (en) * 2019-03-25 2019-07-12 浩云科技股份有限公司 A kind of two dimensional code big data safe transmission device based on dynamic multi-level encryption and decryption
CN116405252A (en) * 2023-03-09 2023-07-07 无锡中盾科技有限公司 Two-dimensional code data unidirectional transmission method

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
公安信息网与互联网数据双向安全交换研究;廖楷炜;伍健勇;蒋海平;王季光;;广东公安科技;20170930(第03期);全文 *
基于光纤通信技术的数据单向传输可靠性研究;邵旭东;蒋海平;张菡;;信息网络安全;20161010(第10期);全文 *

Also Published As

Publication number Publication date
CN117811837A (en) 2024-04-02

Similar Documents

Publication Publication Date Title
Zhang et al. Fragile watermarking with error-free restoration capability
EP3907643A1 (en) Detection of video tampering
CN111860730A (en) Different network information transmission system based on image processing
WO2018002944A1 (en) Converting binary data to images
CN102932650B (en) Video data integrity protection and verification method, equipment and system
US7747087B2 (en) Apparatus, method, and article of manufacture used to encode information into an image and to decode information from a captured image
CN111510752A (en) Data transmission method, device, server and storage medium
CN110011993A (en) A kind of two dimensional code big data safe transmission device based on dynamic multi-level encryption and decryption
CN117811837B (en) Unidirectional data transmission system with high privacy security
He et al. A semi-fragile object based video authentication system
EP1678677A4 (en) Method and system for protecting and authenticating a digital image
WO2021190031A1 (en) Wdm-based data transmission method, apparatus, and system, and storage medium
JP4642854B2 (en) Decoding device
CN109525845A (en) A kind of built-in Information hiding verification method suitable for video
CN112203117A (en) Video source tracing and tamper-proof method based on video coder/decoder
CN116738450A (en) Method and device for long-term safe lossless storage and restoration of digital resources
CN110730277B (en) Information coding and method and device for acquiring coded information
CN107680608B (en) Fountain code-based fragile watermark self-recovery method
CN113242107B (en) Two-dimensional code transmission protocol
CN115378931A (en) Large-capacity data transmission method and system based on two-dimension code
CN109120648B (en) A kind of anti-tamper verifying system of real-time monitoring data
CN113873328A (en) Method for splitting multi-camera fusion video file into multiple single-camera video files
Shapiro et al. Improved ECC-based Phase Watermarking Method for Video Copyright Protection
CN109639414B (en) Fingerprint key generation method based on characteristic distance and generation interval
CN110781185A (en) Text file content pixelation conversion and restoration method

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
GR01 Patent grant
GR01 Patent grant