Dual-system architecture multi-channel automatic synchronization method and device and storage medium
The dual-system architecture multi-channel automatic synchronization method addresses the cumbersome configuration and low-performance transfer issues by using TCP connections, UDP protocol, and MD5 checks to ensure seamless and efficient data synchronization.
Patent Information
- Application Number
- CN202510095846.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-22
- Publication Date
- 2025-05-13
AI Technical Summary
Existing dual-system architecture single-channel communication systems require manual configuration in both sending and receiving ends, are cumbersome, and lack high-performance file transfer capabilities.
A dual-system architecture multi-channel automatic synchronization method utilizing TCP connections for client-web communication, UDP protocol for data transfer, and MD5 checks for data integrity, with automatic file selection and filtering based on pre-configured rules, ensuring seamless data transmission between isolated hardware boards.
Enables automatic, high-performance data synchronization across dual-system architectures without manual intervention, ensuring data integrity and efficient file transfer.
Smart Images

Figure CN119996426A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of network data security transmission, and in particular to a dual-system architecture multi-channel automatic synchronization method, device and storage medium. Background Art
[0002] With the widespread application of the Internet, facing the increasingly severe network security risks, the dual-system architecture one-way transmission system refers to two completely independent hardware motherboards, independently running two operating systems, and using a one-way transmission medium to communicate between the two systems. Data can only be transmitted from the sending end system to the receiving end system. The existing dual-system architecture one-way transmission system needs to be connected to the sending end and the receiving end system for configuration, which is cumbersome to operate and cannot automatically or efficiently transmit files. Therefore, a dual-system architecture multi-channel automatic synchronization method that can solve the above problems is needed. Summary of the invention
[0003] The main purpose of the present application is to provide a dual-system architecture multi-channel automatic synchronization method, device and storage medium, aiming to solve the problems mentioned in the background technology.
[0004] The present application provides a dual-system architecture multi-channel automatic synchronization method, wherein the optical gate external network corresponds to a first web, and the optical gate internal network corresponds to a second web, and the method includes: The first client and the first web establish a connection through TCP, the second client and the second web establish a connection through TCP, the first client sends data to the second client unidirectionally, and the transmission between the first client and the second client is based on the UDP protocol.
[0005] Further, a method for sending data applied to the first client specifically includes: Start the scanning thread, traverse all files in the monitoring directory and add them to the scanning queue; Get a list of occupied files; Screening the scanned files and / or folders according to the list of occupied files, and filtering out files if they are occupied or have a temporary file suffix; The screened file collection is put into a queue to be sent.
[0006] Furthermore, the “obtaining a list of occupied files” specifically involves obtaining the absolute paths of all files of the opened file descriptors of the system and adding them to a collection.
[0007] Furthermore, it also includes a configuration strategy method, and the configuration strategy method is specifically: by presetting rules for file size and / or file type and / or file content detection and / or virus filtering detection.
[0008] Furthermore, the scanned files and / or folders are screened according to the pre-configured policies, and if the files match the pre-configured policies, they are screened out.
[0009] Furthermore, the method also includes: performing an integrity check on the data during the transmission process.
[0010] Furthermore, the “checking the integrity of data during transmission” specifically includes: By comparing the MD5 values before and after transmission, if the MD5 values before and after transmission are different, the data is considered incomplete.
[0011] Further, a data receiving method applied to the second client is included, specifically comprising: Parse the receiving folder configured in the web management, receive the complete file stream, and decompress it to the configured path.
[0012] The present invention also provides a dual-system architecture multi-channel automatic synchronization device, the device includes an external network unit and an internal network unit, the external network unit includes an optical gate external network, a first web and a first client, the internal network unit includes an optical gate internal network, a second web and a second client, wherein a connection is established between the first client and the first web via TCP, a connection is established between the second client and the second web via TCP, the first client is used to establish a connection with the first web via TCP and send data to the second client, the second client is used to establish a connection with the second web via TCP and receive data from the first client, wherein the transmission between the first client and the second client is based on the UDP protocol.
[0013] The present invention also provides a storage medium, including a stored program, which controls the device where the computer-readable storage medium is located to execute the above-mentioned dual-system architecture multi-channel automatic synchronization method when the program is running. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0015] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0016] Figure 1It is a brief schematic diagram of an automatic synchronization method for multiple channels in a dual-system architecture according to an embodiment of the present invention.
[0017] Figure 2 It is a step flow chart of a method for sending data applied to the first client according to an embodiment of the present invention.
[0018] The purpose, features and advantages of this application will be further described in conjunction with the embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0019] In order to make the above-mentioned purposes, features and advantages of the present invention more obvious and easy to understand, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work belong to the scope of protection of the present invention.
[0020] See also Figure 1 The present application provides a dual-system architecture multi-channel automatic synchronization method, wherein the optical gate external network corresponds to a first web, and the optical gate internal network corresponds to a second web, and the method comprises: The first client and the first web establish a connection through TCP, the second client and the second web establish a connection through TCP, the first client sends data to the second client unidirectionally, and the transmission between the first client and the second client is based on the UDP protocol.
[0021] In the present invention, the client and the web establish a connection through TCP, which is mainly used to realize functions such as login, password modification, permission control, heartbeat, etc., and because the data direction of the optical gate can only be from outside to inside, the first client connected to the external network optical gate is used as the sender, and the second client connected to the internal network optical gate is used as the receiver; due to the unidirectionality of the optical gate, the UDP protocol is adopted to meet the performance requirements in special scenarios while ensuring synchronization without packet loss. The optical gate internal and external networks use protocol agents to establish rules for data transmission.
[0022] like Figure 2 As shown, in a specific implementation of the present invention, a method for sending data applied to the first client is included, specifically including: Start the scanning thread, traverse all files in the monitoring directory and add them to the scanning queue; Get a list of occupied files; Screening the scanned files and / or folders according to the list of occupied files, and filtering out files if they are occupied or have a temporary file suffix; The screened file collection is put into a queue to be sent.
[0023] In a preferred embodiment of the present invention, the "obtaining a list of occupied files" specifically involves obtaining the absolute paths of all files of the opened file descriptors of the system and adding them to a set.
[0024] Furthermore, it also includes a configuration strategy method, and the configuration strategy method is specifically: by presetting rules for file size and / or file type and / or file content detection and / or virus filtering detection.
[0025] In a preferred embodiment of the present invention, the "putting the screened file set into a queue to be sent" also includes a packaging and compression step, specifically including: determining whether to perform a packaging process according to file attributes.
[0026] Furthermore, the decision on whether to perform packaging and compression is made based on at least one of the file size and file attributes; and combined with the multi-channel transportation method, automatic file packaging and batch transmission can be achieved, and the data that has entered the waiting-to-send state can be packaged and transmitted in batches.
[0027] In a preferred embodiment of the present invention, the scanned files and / or folders are screened according to a pre-configured policy, and if the file matches the pre-configured policy, it is screened out.
[0028] Furthermore, the method further comprises: performing an integrity check on the data during the transmission process.
[0029] In a preferred embodiment of the present invention, the "integrity check of data during transmission" specifically includes: by comparing the MD5 values before and after the transmission, if the MD5 values before and after the transmission are different, the data is considered incomplete. In this embodiment, the method supports real-time monitoring of file changes, and the client monitors the path of the sent file. When there is a file to be sent, it is immediately added to the scanning queue and enters the waiting state.
[0030] In the present invention, the automatic synchronization method also includes a data receiving method applied to the second client, specifically including: parsing the receiving folder configured in the web management, and after receiving the file stream completely, decompressing it to the configured path. In this embodiment, open the client, enter the account and password added by the web to log in, and after the login is successful, the client automatically performs the following operations.
[0031] The present invention has mentioned the method and steps for implementing sending and receiving. Before implementing the method, the client information of the file exchange is configured in the WEB management interface, including the account, password, file transfer proxy port and advanced strategy (file size, file type, file content detection, virus filtering, etc.). Then, when data synchronization / data transmission is required, the first client or the second client is opened, and the account and password added by the web are entered to log in. After successful login, the first client or the second client automatically performs the method of sending and receiving.
[0032] In a specific implementation of the present invention, automatic policy synchronization is supported. After the relevant accounts and policies are configured in the optical gate external network, data transmission is realized through the aforementioned data transmission method and the data is automatically synchronized to the optical gate internal network without manual configuration.
[0033] In a specific implementation of the present invention, an auditing step is also included, including: automatically recording policy configuration, client login, logout, file sending, receiving, file size, type, content interception records, virus interception records and other information as logs.
[0034] The present invention also provides a dual-system architecture multi-channel automatic synchronization device, the device includes an external network unit and an internal network unit, the external network unit includes an optical gate external network, a first web and a first client, the internal network unit includes an optical gate internal network, a second web and a second client, wherein a connection is established between the first client and the first web via TCP, a connection is established between the second client and the second web via TCP, the first client is used to establish a connection with the first web via TCP and send data to the second client, the second client is used to establish a connection with the second web via TCP and receive data from the first client, wherein the transmission between the first client and the second client is based on the UDP protocol.
[0035] The present invention also provides a storage medium, including a stored program, which controls the device where the computer-readable storage medium is located to execute the above-mentioned dual-system architecture multi-channel automatic synchronization method when the program is running.
[0036] The above are only preferred embodiments of the present application, and are not intended to limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the contents of the present application specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent processing scope of the present application.
Claims
1. A dual-system architecture multi-channel automatic synchronization method, characterized in that: The optical gate external network corresponds to a first web, and the optical gate internal network corresponds to a second web. The method includes: The first client and the first web establish a connection through TCP, the second client and the second web establish a connection through TCP, the first client sends data to the second client unidirectionally, and the transmission between the first client and the second client is based on the UDP protocol.
2. The automatic synchronization method of dual-system architecture and multiple channels according to claim 1, characterized in that: The method for sending data applied to the first client specifically includes: Start the scanning thread, traverse all files in the monitoring directory and add them to the scanning queue; Get a list of occupied files; Screening the scanned files and / or folders according to the list of occupied files, and filtering out files if they are occupied or have a temporary file suffix; The screened file collection is put into a queue to be sent.
3. The automatic synchronization method of dual-system architecture and multiple channels according to claim 2, characterized in that: The "obtaining a list of occupied files" specifically involves obtaining the absolute paths of all files of the opened file descriptors of the system and adding them to the set.
4. The automatic synchronization method of dual-system architecture and multiple channels according to claim 2, characterized in that: It also includes a configuration strategy method, which specifically includes: presetting rules for file size and / or file type and / or file content detection and / or virus filtering detection.
5. The automatic synchronization method of dual-system architecture and multiple channels according to claim 4, characterized in that: Scanned files and / or folders are screened according to pre-configured policies. If a file matches a pre-configured policy, it is screened out.
6. The dual-system architecture multi-channel automatic synchronization method according to claim 1, characterized in that: The method further comprises: performing an integrity check on the data during the transmission process.
7. The automatic synchronization method of dual-system architecture and multiple channels according to claim 6, characterized in that: The "checking the integrity of data during transmission" specifically includes: comparing the MD5 values before and after the transmission. If the MD5 values before and after the transmission are different, the data is considered incomplete.
8. The automatic synchronization method of dual-system architecture and multiple channels according to claim 1, characterized in that: The method for receiving data applied to the second client includes: Parse the receiving folder configured in the web management, receive the complete file stream, and decompress it to the configured path.
9. A dual-system architecture multi-channel automatic synchronization device, characterized in that: The device includes an external network unit and an internal network unit, the external network unit includes an optical gate external network, a first web and a first client, and the internal network unit includes an optical gate internal network, a second web and a second client, wherein a connection is established between the first client and the first web via TCP, a connection is established between the second client and the second web via TCP, the first client is used to establish a connection with the first web via TCP and send data to the second client, the second client is used to establish a connection with the second web via TCP and receive data from the first client, wherein the transmission between the first client and the second client is based on the UDP protocol.
10. A storage medium, characterized in that: It includes a stored program, which controls the device where the computer-readable storage medium is located to execute the automatic synchronization method of dual-system architecture and multiple channels according to any one of claims 1 to 8 when the program is running.