CN114157435B - Document processing method and device based on blockchain technology and client - Google Patents

Document processing method and device based on blockchain technology and client Download PDF

Info

Publication number
CN114157435B
CN114157435B CN202111476897.1A CN202111476897A CN114157435B CN 114157435 B CN114157435 B CN 114157435B CN 202111476897 A CN202111476897 A CN 202111476897A CN 114157435 B CN114157435 B CN 114157435B
Authority
CN
China
Prior art keywords
client
account book
data
information
signature information
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
CN202111476897.1A
Other languages
Chinese (zh)
Other versions
CN114157435A (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.)
Guizhou Qianchi Information Co ltd
Original Assignee
Guizhou Qianchi Information 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 Guizhou Qianchi Information Co ltd filed Critical Guizhou Qianchi Information Co ltd
Priority to CN202111476897.1A priority Critical patent/CN114157435B/en
Publication of CN114157435A publication Critical patent/CN114157435A/en
Application granted granted Critical
Publication of CN114157435B publication Critical patent/CN114157435B/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
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1095Replication or mirroring of data, e.g. scheduling or transport for data synchronisation between network nodes
    • 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
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/141Setup of application sessions
    • 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/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3247Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials involving digital signatures

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Storage Device Security (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The embodiment of the application discloses a document processing method, a device and a client based on a blockchain technology, wherein the method applied to a first client side comprises the following steps: establishing network connection with a second client through a broadcasting mechanism; the second client is a client which is in an open state except the first client in the local area network; generating account book signature information according to first account book information in a first local account book file of the first client; transmitting a data request to a second client through a broadcasting mechanism; the data request comprises encrypted document data and account book signature information; and the second client receives the data request, verifies the account book signature information, and adopts a corresponding processing scheme for the document data according to the verification result. The embodiment scheme realizes the distributed storage of the document data at the client, the decentralization and the tamper resistance and non-repudiation of the document, improves the network security, has simple scheme and low cost, and provides a technical foundation for plug and play.

Description

Document processing method and device based on blockchain technology and client
Technical Field
The embodiment of the application relates to a document processing technology, in particular to a document processing method, a document processing device and a client based on a blockchain technology.
Background
The existing office products (such as WPS and other software) are mainly applied to the public field, the network office functions of the existing office products mainly realize collaborative editing and document sharing on an open network, and a server client mode is adopted, so that public cloud or a server needs to be established.
The network document collaborative editing technology or system of the traditional cloud mode or server client mode cannot meet the security requirement, cannot deploy applications or cannot realize bidirectional collaborative editing under the mechanism;
The security requirement of part of large or important enterprises on documents is high, and recorded information can be recorded, modified and downloaded in a tamper-proof and reliable manner; the simple logging mode adopted by the existing software cannot realize tamper resistance and non-repudiation of the document.
At present, enterprises are required to control office cost and realize efficient document editing sharing, the traditional server mode is complex to deploy, the construction and maintenance costs are high, once a server has a problem, collaborative office editing cannot be performed, and a new collaborative convenient technology with plug and play and high reliability is required.
Disclosure of Invention
The embodiment of the application provides a document processing method, a device and a client based on a blockchain technology, which can realize the distributed storage of document data in the client, realize the decentralization, realize the tamper resistance of a document and the non-repudiation of the document, improve the network security, have simple scheme and low cost and provide a technical basis for plug and play.
The embodiment of the application provides a document processing method based on a blockchain technology, which is applied to a first client side, wherein the first client is any client which needs to synchronize document data in a preset local area network; the method may include:
establishing network connection with one or more second clients in the local area network through a broadcasting mechanism; the second client is a client in an open state except the first client in the local area network;
Generating account book signature information according to first account book information in a first local account book file corresponding to the first client;
Transmitting a data request to a second client for establishing network connection through the broadcasting mechanism; the data request comprises encrypted document data and the account book signature information; and after each second client for establishing network connection receives the data request, verifying the account book signature information, and adopting a corresponding processing scheme for the document data according to a verification result.
In an exemplary embodiment of the present application, the establishing a network connection with one or more second clients in an on state in a preset local area network through a broadcast mechanism may include:
Traversing the IP address of a second client in the local area network, and sending a connection request to the traversed second client through the broadcasting mechanism;
And receiving return information of one or more second clients, wherein the return information comprises information that the second clients are in an open state, establishing network connection with the one or more second clients, and recording the IP addresses of the second clients which send the return information.
In an exemplary embodiment of the present application, the first ledger information may include any one or more of the following: saving a file name of the document data, a storage path of the document data, an update time of the document data and an IP address of the first client;
the generating ledger signature information according to the first ledger information in the first local ledger file corresponding to the first client may include: and carrying out encryption operation on the file name, the storage path, the updating time and the IP address of the second client through a preset encryption algorithm to obtain unique identification information serving as the account book signature information.
In an exemplary embodiment of the present application, the method may further include:
when an editable file containing the document data is uploaded to the first client, encrypting reading of file content of the editable file and conversion of a data stream, and compressing the editable file; and/or the number of the groups of groups,
And sending the data request to a second client for establishing network connection in a multi-process concurrency mode.
In an exemplary embodiment of the present application, the method may further include:
The local area network is built in advance, and a corresponding IP address is configured for each client in the local area network; the client is the first client or the second client.
In an exemplary embodiment of the present application, the method may further include:
When any client in the local area network starts a preset platform, and accesses a local IP address and a uniform resource locator Url address of a designated port through the preset platform, determining that the any client is in an open state.
The embodiment of the application also provides a document processing device based on the blockchain technology, which can comprise a first processor and a first computer readable storage medium, wherein the first computer readable storage medium stores first instructions, and when the first instructions are executed by the first processor, the document processing method based on the blockchain technology applied to the first client side is realized.
The embodiment of the application also provides a document processing method based on the blockchain technology, which is applied to a second client side, wherein the second client is a client in an open state except the first client in a preset local area network; the first client is any client which needs to synchronize document data in a preset local area network; the method may include:
Establishing network connection with a first client which sends a connection request through a broadcasting mechanism in the local area network;
Receiving a data request sent by the first client through the broadcasting mechanism; the data request comprises encrypted document data and account book signature information; the account book signature information is generated by the first client according to first account book information in a first local account book file corresponding to the first client;
and verifying the account book signature information extracted from the data request, and adopting a corresponding processing scheme for the document data according to a verification result.
In an exemplary embodiment of the present application, the verifying the ledger signature information extracted from the data request may include:
Comparing the ledger signature information extracted from the data request with locally stored ledger signature information;
determining a first verification result when the ledger signature information extracted from the data request is consistent with the locally stored ledger signature information;
And determining a second verification result when the account book signature information extracted from the data request is inconsistent with the locally stored account book signature information.
In an exemplary embodiment of the present application, the adopting a corresponding processing scheme for the document data according to the verification result may include:
When the verification result is the first verification result, the document data is saved as modified data;
and when the verification result is the second verification result, storing the document data as newly added data.
The embodiment of the application also provides a document processing device based on the blockchain technology, which can comprise a second processor and a second computer readable storage medium, wherein the second computer readable storage medium stores second instructions, and when the second instructions are executed by the second processor, the document processing method based on the blockchain technology applied to the second client side is realized.
The embodiment of the application also provides a client which can comprise the document processing device based on the blockchain technology.
Compared with the related art, the embodiment of the application can comprise the following steps: establishing network connection with one or more second clients in the local area network through a broadcasting mechanism; the second client is a client in an open state except the first client in the local area network; generating account book signature information according to first account book information in a first local account book file corresponding to the first client; transmitting a data request to a second client for establishing network connection through the broadcasting mechanism; the data request comprises encrypted document data and the account book signature information; and after each second client for establishing network connection receives the data request, verifying the account book signature information, and adopting a corresponding processing scheme for the document data according to a verification result. According to the embodiment scheme, distributed storage of each client is realized through a broadcasting mechanism, decentralization is realized, account book signature information realizes that the clients have independent account book management and unified verifiable signature records, so that tamper resistance of the document and non-repudiation of the document are realized, network safety is improved through a local area network, and the embodiment scheme is simple and low in cost, and provides a technical foundation for plug and play.
Additional features and advantages of the application will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by practice of the application. Other advantages of the application may be realized and attained by the structure particularly pointed out in the written description and drawings.
Drawings
The accompanying drawings are included to provide an understanding of the principles of the application, and are incorporated in and constitute a part of this specification, illustrate embodiments of the application and together with the description serve to explain, without limitation, the principles of the application.
FIG. 1 is a flowchart of a method for processing a blockchain technology-based document applied to a first client side in accordance with an embodiment of the present application;
fig. 2 is a schematic diagram of a network connection of a client in an on state in a lan according to an embodiment of the present application;
FIG. 3 is a schematic diagram illustrating file synchronization performed by each node in the same block according to an embodiment of the present application;
FIG. 4 is a schematic diagram of two requests performed by a broadcast mechanism between clients according to an embodiment of the present application;
FIG. 5 is a block diagram of a block chain technology based document processing device applied to a first client side in accordance with an embodiment of the present application;
FIG. 6 is a flowchart of a method for processing a blockchain technology-based document applied to a second client side in accordance with an embodiment of the present application;
FIG. 7 is a block diagram of a document processing device based on blockchain technology applied to a second client side in accordance with an embodiment of the present application;
Fig. 8 is a block diagram of a client according to an embodiment of the present application.
Detailed Description
The present application has been described in terms of several embodiments, but the description is illustrative and not restrictive, and it will be apparent to those of ordinary skill in the art that many more embodiments and implementations are possible within the scope of the described embodiments. Although many possible combinations of features are shown in the drawings and discussed in the detailed description, many other combinations of the disclosed features are possible. Any feature or element of any embodiment may be used in combination with or in place of any other feature or element of any other embodiment unless specifically limited.
The present application includes and contemplates combinations of features and elements known to those of ordinary skill in the art. The disclosed embodiments, features and elements of the present application may also be combined with any conventional features or elements to form a unique inventive arrangement as defined by the claims. Any feature or element of any embodiment may also be combined with features or elements from other inventive arrangements to form another unique inventive arrangement as defined in the claims. It is therefore to be understood that any of the features shown and/or discussed in the present application may be implemented alone or in any suitable combination. Accordingly, the embodiments are not to be restricted except in light of the attached claims and their equivalents. Further, various modifications and changes may be made within the scope of the appended claims.
Furthermore, in describing representative embodiments, the specification may have presented the method and/or process as a particular sequence of steps. However, to the extent that the method or process does not rely on the particular order of steps set forth herein, the method or process should not be limited to the particular sequence of steps described. Other sequences of steps are possible as will be appreciated by those of ordinary skill in the art. Accordingly, the particular order of the steps set forth in the specification should not be construed as limitations on the claims. Furthermore, the claims directed to the method and/or process should not be limited to the performance of their steps in the order written, and one skilled in the art can readily appreciate that the sequences may be varied and still remain within the spirit and scope of the embodiments of the present application.
The embodiment of the application provides a document processing method based on a blockchain technology, which is applied to a first client side, wherein the first client is any client which needs to synchronize document data in a preset local area network; as shown in fig. 1, the method may include steps S101-S103:
S101, establishing network connection with one or more second clients in the local area network through a broadcasting mechanism; the second client is a client in an open state except the first client in the local area network;
s102, generating account book signature information according to first account book information in a first local account book file corresponding to the first client;
S103, sending a data request to a second client for establishing network connection through the broadcasting mechanism; the data request comprises encrypted document data and the account book signature information; and after each second client for establishing network connection receives the data request, verifying the account book signature information, and adopting a corresponding processing scheme for the document data according to a verification result.
In the exemplary embodiment of the application, a broadcasting mechanism and a digital signature technology (such as account book signature information) are combined, so that the document synchronization method of the block chain mode of multi-client data transmission and authentication under the local area network is realized. The broadcasting mechanism realizes distributed storage of each client, decentralization and account book signature information, and the clients have independent account book management and unified verifiable signature records, so that document falsification prevention and document undeniability are realized, and network security is improved through a local area network.
In an exemplary embodiment of the present application, the method may further include:
Pre-constructing the local area network, and configuring a corresponding IP (Internet protocol) address for each client in the local area network; the client is the first client or the second client.
In an exemplary embodiment of the present application, there is also a need to test the communicable network environment of the client direct IP usage command PING, the designated port usage command TELNET within the local area network.
In an exemplary embodiment of the present application, the method may further include:
When any client in the local area network starts a preset platform, and accesses a local IP address and a uniform resource locator Url address of a designated port through the preset platform, determining that the any client is in an open state.
In an exemplary embodiment of the present application, the preset platform may be an APP, an applet, a web platform, etc., and the specific implementation of the preset platform is not limited herein.
In an exemplary embodiment of the present application, for example, after starting an APP application for each client in a lan, a browser may be used to access a native IP and a Url address of a designated port, and a browsing operation may be performed on a corresponding application interface (e.g., a Web interface of a Web page), so that the current client may be regarded as an independent node in an on state, as shown in fig. 2.
In an exemplary embodiment of the present application, a new client may be considered a new node joining when it changes from an off state to an on state. When a plurality of clients are all in an on state and are under the current network of the same local area network, the nodes formed by the clients can be regarded as being combined into a block, as shown in fig. 2. When any new node joins a block, data synchronization can be first performed with other nodes in the block by the document processing method according to the embodiment of the present application.
In the exemplary embodiment of the present application, as shown in fig. 3, any one node in an on state may combine with a digital signature to other clients in an on state in a local area network through a broadcast mechanism, verify the content of account book signature information between clients, and implement automatic update of data according to the verification result, so as to ensure that files of all nodes under a block are up to date and uniform.
In an exemplary embodiment of the present application, the method may further include:
when an editable file containing the document data is uploaded to the first client, reading of file content of the editable file and conversion of data stream are encrypted, and the editable file is compressed.
In the exemplary embodiment of the application, aiming at the editable file, when the file is uploaded to a client, the file content can be read, the data stream can be converted and compressed in an encrypted manner (pako. Min. Js), the file is stored as a text file of a ciphertext character string, and the file format can be obtained only by reading the file data based on an application interface and then decompressing, encrypting, displaying and downloading the file data, so that the safety of the data file is further ensured.
In the exemplary embodiment of the application, for example, in the transmission process of the table editable file in the block, the Web front end firstly encrypts and compresses the data stream of the table editable file, and then the data stream is subjected to multi-process concurrent request (including connection request and data request) through a broadcasting mechanism to the application back end, so that the efficiency of collaborative editing and updating is improved.
In an exemplary embodiment of the present application, the establishing a network connection with one or more second clients in an on state in a preset local area network through a broadcast mechanism may include:
Traversing the IP address of a second client in the local area network, and sending a connection request to the traversed second client through the broadcasting mechanism;
And receiving return information of one or more second clients, wherein the return information comprises information that the second clients are in an open state, establishing network connection with the one or more second clients, and recording the IP addresses of the second clients which send the return information.
In an exemplary embodiment of the present application, as shown in fig. 4, in the lan mode, the first client needs to send two requests, a first request to establish a connection (which may be referred to as a connection request) and a second request to transmit data (which may be referred to as a data request).
In the exemplary embodiment of the present application, when a first request is sent, the first client a may acquire a local IP address and a designated port, and send a connection request to other client addresses through a multi-process concurrency mode, the designated port, and traversing a lan address range; if one or more second clients B are in an open state, and after receiving the connection request, the open state is fed back to the first client A.
In the exemplary embodiment of the present application, the first client a takes the second clients B fed back the return information as communicable clients, and records the IP addresses of these second clients B.
In an exemplary embodiment of the application, the IP address of the second client B is used for the destination address when the first client a subsequently sends a data request.
In an exemplary embodiment of the present application, the first client a first generates and encrypts (MD 5) digital signature content (i.e., ledger signature information) about the current data request before broadcasting the second request (data request), and transmits the digital signature information attachment to each second client B after making a network connection in transmission data.
In an exemplary embodiment of the present application, the first ledger information may include any one or more of the following: saving a file name of the document data, a storage path of the document data, an update time of the document data and an IP address of the first client;
the generating ledger signature information according to the first ledger information in the first local ledger file corresponding to the first client a may include: and carrying out encryption operation on the file name, the storage path, the updating time and the IP address of the first client B through a preset encryption algorithm to obtain unique identification information serving as the account book signature information.
In an exemplary embodiment of the present application, after each first client a completes the data request, any client participating in the broadcast (including the first client a and the second client B) will update the ledger record in the local ledger file, and the ledger information may include: the method comprises the steps of generating unique identification information of a preset encryption algorithm (such as an irreversible encryption MD5 algorithm) according to information such as file names, storage paths, update time and client IP addresses, obtaining account signature information, and comparing and checking the account signature information after receiving a data request by a second client B in the steps, so that the problems of file information unification and client trust are solved.
In an exemplary embodiment of the present application, after the first client a generates the account signature information, a second request (data request) may be transmitted to the second client B that establishes the network connection. Specifically, the user may operate at the interface of the first client a, send data for transmission, and send a data request to the second client B in a multi-thread concurrency mode based on the IP address list of the second client B recorded in the foregoing solution.
In an exemplary embodiment of the present application, after receiving a data request, the second client B verifies the account signature information extracted from the data request, and adopts a corresponding processing scheme for the document data according to the verification result.
In an exemplary embodiment of the present application, verifying the ledger signature information extracted from the data request may include:
Comparing the ledger signature information extracted from the data request with locally stored ledger signature information;
determining a first verification result when the ledger signature information extracted from the data request is consistent with the locally stored ledger signature information;
And determining a second verification result when the account book signature information extracted from the data request is inconsistent with the locally stored account book signature information.
In an exemplary embodiment of the present application, the second client B receives the data request, extracts the ledger signature information in the data request, and compares it with the locally stored ledger signature information.
In an exemplary embodiment of the present application, the ledger signature information stored locally by the second client B is generated from the second ledger information in the second local ledger file corresponding to the second client B itself. The second ledger information may include any one or more of the following: and saving the file name of the document data, the storage path of the document data, the update time of the document data and the IP address of the second client B. And generating unique identification information of a preset encryption algorithm (such as an irreversible encryption MD5 algorithm) according to the information, and acquiring account book signature information locally stored by the second client B.
In an exemplary embodiment of the present application, the corresponding ledger signature information in the first client a and the second client B should be the same for the same document data. Therefore, when the second client B verifies the account book signature information in the data request sent by the first client a, the account book signature information extracted from the data request can be compared with the locally stored account book signature information.
In an exemplary embodiment of the present application, the adopting a corresponding processing scheme for the document data according to the verification result may include:
When the verification result is the first verification result, the document data is saved as modified data;
and when the verification result is the second verification result, storing the document data as newly added data.
In the exemplary embodiment of the present application, if the verification result is the first verification result (the two ledger wall signature information are identical), the description is for the update of the document data stored in the second client B (which can be regarded as modification to the document data), so that the document data extracted from the data request can be used as modification data for updating the corresponding document data in the second local ledger wall; if the verification result is the second verification result (the two account signature information are not identical), it is explained that the update is not for the document data stored in the second client B (the document data in the current data request is a newly added document may be regarded as the original document not stored in the second client B), and therefore the document data extracted in the data request may be used as the newly added data, which is added in the second local account file.
In an exemplary embodiment of the present application, after completing the document data processing operation, the second client B may modify the content of the second ledger information to update the second ledger information, and may generate the latest digital signature information (i.e., generate the latest ledger signature information from the updated second ledger information).
In the exemplary embodiment of the present application, after each second client B completes the above operation, the result may be fed back to the first client a, where the first client a updates the first ledger information and the digital signature information in the local machine at the same time (i.e., generates the latest ledger signature information according to the updated first ledger information), so as to ensure the unification of the digital signatures in the respective clients.
The embodiment of the present application further provides a document processing device 1 based on the blockchain technology, as shown in fig. 5, may include a first processor 11 and a first computer readable storage medium 12, where the first computer readable storage medium 12 stores first instructions, and when the first instructions are executed by the first processor 11, implement any one of the above-mentioned methods for processing a document based on the blockchain technology applied to a first client side.
In the exemplary embodiment of the present application, the foregoing embodiments of the method for processing a document based on a blockchain technique applied to the first client side are all applicable to the embodiment of the apparatus, and are not described herein in detail.
The embodiment of the application also provides a document processing method based on the blockchain technology, which is applied to a second client side, wherein the second client is a client in an open state except the first client in a preset local area network; the first client is any client which needs to synchronize document data in a preset local area network; as shown in fig. 6, the method may include S201-S203:
S201, establishing network connection with a first client side which sends a connection request through a broadcasting mechanism in the local area network;
S202, receiving a data request sent by the first client through the broadcasting mechanism; the data request comprises encrypted document data and account book signature information; the account book signature information is generated by the first client according to first account book information in a first local account book file corresponding to the first client;
s203, verifying the account book signature information extracted from the data request, and adopting a corresponding processing scheme for the document data according to a verification result.
In an exemplary embodiment of the present application, as shown in fig. 4, in the lan mode, the first client needs to send two requests, a first request to establish a connection (which may be referred to as a connection request) and a second request to transmit data (which may be referred to as a data request).
In the exemplary embodiment of the present application, when a first request is sent, the first client a may acquire a local IP address and a designated port, and send a connection request to other client addresses through a multi-process concurrency mode, the designated port, and traversing a lan address range; if one or more second clients B are in an open state, and after receiving the connection request, the open state is fed back to the first client A.
In the exemplary embodiment of the present application, the first client a takes the second clients B fed back the return information as communicable clients, and records the IP addresses of these second clients B.
In an exemplary embodiment of the application, the IP address of the second client B is used for the destination address when the first client a subsequently sends a data request.
In an exemplary embodiment of the present application, the first client a first generates and encrypts (MD 5) digital signature content (i.e., ledger signature information) about the current data request before broadcasting the second request (data request), and transmits the digital signature information attachment to each second client B after making a network connection in transmission data.
In an exemplary embodiment of the present application, the first ledger information may include any one or more of the following: saving a file name of the document data, a storage path of the document data, an update time of the document data and an IP address of the first client;
the generating ledger signature information according to the first ledger information in the first local ledger file corresponding to the first client a may include: and carrying out encryption operation on the file name, the storage path, the updating time and the IP address of the first client B through a preset encryption algorithm to obtain unique identification information serving as the account book signature information.
In an exemplary embodiment of the present application, after each first client a completes the data request, any client participating in the broadcast (including the first client a and the second client B) will update the ledger record in the local ledger file, and the ledger information may include: the method comprises the steps of generating unique identification information of a preset encryption algorithm (such as an irreversible encryption MD5 algorithm) according to information such as file names, storage paths, update time and client IP addresses, obtaining account signature information, and comparing and checking the account signature information after receiving a data request by a second client B in the steps, so that the problems of file information unification and client trust are solved.
In an exemplary embodiment of the present application, after the first client a generates the account signature information, a second request (data request) may be transmitted to the second client B that establishes the network connection. Specifically, the user may operate at the interface of the first client a, send data for transmission, and send a data request to the second client B in a multi-thread concurrency mode based on the IP address list of the second client B recorded in the foregoing solution.
In an exemplary embodiment of the present application, after receiving a data request, the second client B verifies the account signature information extracted from the data request, and adopts a corresponding processing scheme for the document data according to the verification result.
In an exemplary embodiment of the present application, verifying the ledger signature information extracted from the data request may include:
Comparing the ledger signature information extracted from the data request with locally stored ledger signature information;
determining a first verification result when the ledger signature information extracted from the data request is consistent with the locally stored ledger signature information;
And determining a second verification result when the account book signature information extracted from the data request is inconsistent with the locally stored account book signature information.
In an exemplary embodiment of the present application, the second client B receives the data request, extracts the ledger signature information in the data request, and compares it with the locally stored ledger signature information.
In an exemplary embodiment of the present application, the ledger signature information stored locally by the second client B is generated from the second ledger information in the second local ledger file corresponding to the second client B itself. The second ledger information may include any one or more of the following: and saving the file name of the document data, the storage path of the document data, the update time of the document data and the IP address of the second client B. And generating unique identification information of a preset encryption algorithm (such as an irreversible encryption MD5 algorithm) according to the information, and acquiring account book signature information locally stored by the second client B.
In an exemplary embodiment of the present application, the corresponding ledger signature information in the first client a and the second client B should be the same for the same document data. Therefore, when the second client B verifies the account book signature information in the data request sent by the first client a, the account book signature information extracted from the data request can be compared with the locally stored account book signature information.
In an exemplary embodiment of the present application, the adopting a corresponding processing scheme for the document data according to the verification result may include:
When the verification result is the first verification result, the document data is saved as modified data;
and when the verification result is the second verification result, storing the document data as newly added data.
In the exemplary embodiment of the present application, if the verification result is the first verification result (the two ledger wall signature information are identical), the description is for the update of the document data stored in the second client B (which can be regarded as modification to the document data), so that the document data extracted from the data request can be used as modification data for updating the corresponding document data in the second local ledger wall; if the verification result is the second verification result (the two account signature information are not identical), it is explained that the update is not for the document data stored in the second client B (the document data in the current data request is a newly added document may be regarded as the original document not stored in the second client B), and therefore the document data extracted in the data request may be used as the newly added data, which is added in the second local account file.
In an exemplary embodiment of the present application, after completing the document data processing operation, the second client B may modify the content of the second ledger information to update the second ledger information, and may generate the latest digital signature information (i.e., generate the latest ledger signature information from the updated second ledger information).
In the exemplary embodiment of the present application, after each second client B completes the above operation, the result may be fed back to the first client a, where the first client a updates the first ledger information and the digital signature information in the local machine at the same time (i.e., generates the latest ledger signature information according to the updated first ledger information), so as to ensure the unification of the digital signatures in the respective clients.
In the exemplary embodiment of the present application, other related operations in the block, such as establishment of a folder hierarchy, uploading of a file, etc., may be directly and asynchronously sent by an operation end (any client) as in the document processing method described above, so as to complete real-time synchronization of all clients in the block.
The embodiment of the present application further provides a blockchain technology-based document processing device 2, as shown in fig. 7, may include a second processor 21 and a second computer-readable storage medium 22, where the second computer-readable storage medium 22 stores second instructions, and when the second instructions are executed by the second processor 21, the blockchain technology-based document processing method applied to the second client side according to any one of the above is implemented.
In the exemplary embodiment of the present application, the foregoing embodiments of the method for processing a document based on a blockchain technique applied to the second client side are all applicable to the embodiment of the apparatus, and are not described herein in detail.
The embodiment of the application also provides a client 3, as shown in fig. 8, which can comprise the document processing device 1 based on the blockchain technology and the document processing device 2 based on the blockchain technology.
In the exemplary embodiment of the present application, the foregoing embodiments of the method for processing documents based on the blockchain technology applied to the first client side and the second client side are applicable to the embodiment of the apparatus, and are not described in detail herein.
In an exemplary embodiment of the application, at least the following advantages are included:
1. Block synchronization: and meanwhile, based on the block chain technology, the local distribution storage is realized under the enterprise internal local area network mode, the distributed account book is counted for each operation record, and each localization operation is broadcasted to other machines in an opening state in the local area network to carry out local file synchronization, so that the local file synchronization can be tamper-proof, and the document credibility and record modification trace are ensured.
2. Decentralizing-multimachine combination: each machine can be used independently and in combination, the master-slave relationship is not adopted among the machines, and when a new machine is started, account book records (namely account book signature information) are compared with other machines, and the local updating and synchronization of the data files are performed. The mode does not need a server, so that not only is investment saved, but also maintenance is avoided, plug and play is realized, the mode can be used only in a mode of terminal networking, and the reliability is high. And under the condition of no server mode, the cooperation of the office terminals in the same area can be well adapted to complex network and information security environments of enterprises.
3. On-line collaborative editing: and uploading the file according to the online checking and online editing functions of the business, so that the collaborative editing work of the file is realized, and the office mode is optimized.
4. Compression encryption and decryption: the data file adopts compression and encryption and decryption technology, so that the transmission speed is improved, the data security is ensured, and the enterprise data security requirement is met.
Those of ordinary skill in the art will appreciate that all or some of the steps, systems, functional modules/units in the apparatus, and methods disclosed above may be implemented as software, firmware, hardware, and suitable combinations thereof. In a hardware implementation, the division between the functional modules/units mentioned in the above description does not necessarily correspond to the division of physical components; for example, one physical component may have multiple functions, or one function or step may be performed cooperatively by several physical components. Some or all of the components may be implemented as software executed by a processor, such as a digital signal processor or microprocessor, or as hardware, or as an integrated circuit, such as an application specific integrated circuit. Such software may be distributed on computer readable media, which may include computer storage media (or non-transitory media) and communication media (or transitory media). The term computer storage media includes both volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data, as known to those skilled in the art. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital Versatile Disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other medium which can be used to store the desired information and which can be accessed by a computer. Furthermore, as is well known to those of ordinary skill in the art, communication media typically embodies computer readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism and includes any information delivery media.

Claims (5)

1. A document processing method based on a blockchain technology is characterized in that nodes formed by a plurality of clients in an on state under the same local area network are combined into a block, any one client in the on state is combined with a digital signature to other clients in the local area network in the on state through a broadcasting mechanism, the content of account book signature information among the clients is verified, automatic updating of data is realized according to a verification result, distributed storage of document data at the clients is realized, and the fact that files of all the nodes under the block are up-to-date and unified is ensured; the method comprises the following steps:
The first client establishes network connection with one or more second clients in the local area network through a broadcasting mechanism; the first client is any client which needs to synchronize document data in a preset local area network, the second client is a client which is in an open state except the first client in the local area network, and the document data are contained in an editable file;
Generating account book signature information according to first account book information in a first local account book file corresponding to the first client, wherein the first account book information comprises any one or more of the following: saving a file name of the document data, a storage path of the document data, an update time of the document data and an IP address of the first client;
the first client sends a data request to a second client for establishing network connection through the broadcasting mechanism; the data request comprises encrypted document data and the account book signature information;
After each second client establishing network connection receives the data request, comparing the account book signature information extracted from the data request with locally stored account book signature information; the locally stored account book signature information is generated by second account book information in a second local account book file corresponding to the second client, and the second account book information comprises any one or more of the following: saving a file name of the document data, a storage path of the document data, an update time of the document data and an IP address of the second client;
if the two account book signature information are consistent, the document data extracted from the data request are used as modification data to update the corresponding document data in the second local account book file;
If the signature information of the two accounts is inconsistent, taking the document data in the data request as newly added data, and adding the newly added data in the second local account file;
After the document data processing operation is completed, the second client updates the second account book information, generates the latest account book signature information according to the updated second account book information, and feeds back a result to the first client;
The first client side updates the first account book information in the local machine at the same time, and generates the latest account book signature information according to the updated first account book information so as to ensure the unification of digital signatures in all the client sides;
The local area network is an enterprise internal local area network, and the editable file is uploaded through an online editing function so as to realize collaborative editing work of the file and optimize an office mode.
2. The blockchain technology based document processing method of claim 1, wherein the first client establishes a network connection with one or more second clients within the local area network through a broadcast mechanism, comprising:
Traversing the IP address of a second client in the local area network, and sending a connection request to the traversed second client through the broadcasting mechanism;
and receiving return information of one or more second clients, wherein the return information comprises information that the second clients are in an open state, establishing network connection with the one or more second clients, and recording the IP addresses of the second clients which send the return information.
3. The blockchain technology-based document processing method of claim 1, further comprising:
when an editable file containing the document data is uploaded to the first client, encrypting reading of file content of the editable file and conversion of a data stream, and compressing the editable file; and/or the number of the groups of groups,
And sending the data request to a second client for establishing network connection in a multi-process concurrency mode.
4. A blockchain technology based document processing device comprising a processor and a computer readable storage medium having instructions stored therein that when executed by the processor implement the blockchain technology based document processing method of any of claims 1-3.
5. A client comprising the blockchain technology-based document processing device of claim 4.
CN202111476897.1A 2021-12-02 2021-12-02 Document processing method and device based on blockchain technology and client Active CN114157435B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111476897.1A CN114157435B (en) 2021-12-02 2021-12-02 Document processing method and device based on blockchain technology and client

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111476897.1A CN114157435B (en) 2021-12-02 2021-12-02 Document processing method and device based on blockchain technology and client

Publications (2)

Publication Number Publication Date
CN114157435A CN114157435A (en) 2022-03-08
CN114157435B true CN114157435B (en) 2024-05-17

Family

ID=80452908

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111476897.1A Active CN114157435B (en) 2021-12-02 2021-12-02 Document processing method and device based on blockchain technology and client

Country Status (1)

Country Link
CN (1) CN114157435B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115426208A (en) * 2022-11-03 2022-12-02 中孚信息股份有限公司 Decentralized document cooperation system and method

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109118223A (en) * 2018-08-21 2019-01-01 上海点融信息科技有限责任公司 For managing the method, apparatus and medium of electronic data in block chain
CN110719574A (en) * 2019-10-15 2020-01-21 腾讯科技(深圳)有限公司 Network access method and related equipment
CN111159100A (en) * 2019-11-21 2020-05-15 深圳壹账通智能科技有限公司 Block chain file access method and device, computer equipment and storage medium
CN112005236A (en) * 2018-04-24 2020-11-27 国际商业机器公司 Document access over blockchain networks
CN113128999A (en) * 2019-12-31 2021-07-16 航天信息股份有限公司 Block chain privacy protection method and device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109361734B (en) * 2018-09-18 2021-04-20 百度在线网络技术(北京)有限公司 Data processing method, device, equipment and medium for block chain

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112005236A (en) * 2018-04-24 2020-11-27 国际商业机器公司 Document access over blockchain networks
CN109118223A (en) * 2018-08-21 2019-01-01 上海点融信息科技有限责任公司 For managing the method, apparatus and medium of electronic data in block chain
CN110719574A (en) * 2019-10-15 2020-01-21 腾讯科技(深圳)有限公司 Network access method and related equipment
CN111159100A (en) * 2019-11-21 2020-05-15 深圳壹账通智能科技有限公司 Block chain file access method and device, computer equipment and storage medium
CN113128999A (en) * 2019-12-31 2021-07-16 航天信息股份有限公司 Block chain privacy protection method and device

Also Published As

Publication number Publication date
CN114157435A (en) 2022-03-08

Similar Documents

Publication Publication Date Title
Afanasyev et al. A brief introduction to named data networking
CN109889589B (en) System and method for realizing embedded hardware OTA (over the air) upgrading based on block chain
CN108681965B (en) Block chain network transaction processing method and device for offline node
CN101217431B (en) A method and system of photos in synchronous mobile terminal network TV and network album
US7937752B2 (en) Systems and methods for authenticating communications in a network medium
CN110601851B (en) Method, apparatus, medium, and device for replacing identity credentials in a blockchain network
CN112235420B (en) Data synchronization method, system and related equipment based on block chain
CN108093015B (en) File transmission system
CN104980482A (en) File transmitting method and device, file receiving method and device
CN110855760A (en) Block chain-based distributed secure storage system deployment method
CN104348848B (en) Manage method, terminal device and the server of picture
KR101429956B1 (en) Cloud storage server and system by use of virtual nas and method thereof
CN113726873A (en) Block chain-based file processing method, system, device and storage medium
CN114157435B (en) Document processing method and device based on blockchain technology and client
CN113129008B (en) Data processing method, device, computer readable medium and electronic equipment
CN112182009B (en) Block chain data updating method and device and readable storage medium
Presley et al. Hydra--A Federated Data Repository over NDN
CN108566421B (en) Network type distribution method and system based on network attached storage
CN113612811B (en) Method, system, equipment and medium for client mounting in multiple channels
Quinn et al. Forensic analysis and remote evidence recovery from syncthing: An open source decentralised file synchronisation utility
CN113766031A (en) Method and device for storing note resources and related equipment
JP2002318716A (en) System and method for delivery, server computer and client computer
US11943211B2 (en) Device monitoring in accessing network
CN113132409B (en) Data transmission method and device
CN115150314B (en) Method and device for transmitting data packets across network domains, storage medium and electronic equipment

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