CN112835854A - File storage method and device, electronic equipment and storage medium - Google Patents

File storage method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN112835854A
CN112835854A CN202110138638.1A CN202110138638A CN112835854A CN 112835854 A CN112835854 A CN 112835854A CN 202110138638 A CN202110138638 A CN 202110138638A CN 112835854 A CN112835854 A CN 112835854A
Authority
CN
China
Prior art keywords
file
consensus
node
preparation information
initiating node
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.)
Pending
Application number
CN202110138638.1A
Other languages
Chinese (zh)
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.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and 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 Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202110138638.1A priority Critical patent/CN112835854A/en
Publication of CN112835854A publication Critical patent/CN112835854A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/13File access structures, e.g. distributed indices
    • G06F16/137Hash-based
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/14Details of searching files based on file metadata
    • G06F16/148File search processing
    • G06F16/152File search processing using file content signatures, e.g. hash values
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/64Protecting data integrity, e.g. using checksums, certificates or signatures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/542Event management; Broadcasting; Multicasting; Notifications

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Computer Security & Cryptography (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Multimedia (AREA)
  • Library & Information Science (AREA)
  • Health & Medical Sciences (AREA)
  • Bioethics (AREA)
  • General Health & Medical Sciences (AREA)
  • Computer Hardware Design (AREA)
  • Storage Device Security (AREA)

Abstract

The application discloses a file storage method, a file storage device, electronic equipment and a storage medium, and relates to the technical field of block chains, wherein the method comprises the following steps: the file initiating node broadcasts the target file to the block chain; the target file carries signature information of the file initiating node; in response to the target file being verified as a legitimate file, the file originating node storing the target file in a first block; responding to the file initiating node to send consensus preparation information, and verifying the consensus preparation information by a consensus node of the file initiating node, wherein the consensus preparation information is used for modifying the target file. The method and the device can ensure that the file is not illegally tampered, and the technology of the method and the device is applied to storage of judicial evidence, so that the anti-tampering performance of the judicial evidence can be ensured.

Description

File storage method and device, electronic equipment and storage medium
Technical Field
The present application relates to the field of block chain technology, and in particular, to a file storage method and apparatus, an electronic device, and a storage medium.
Background
Currently, information technology is driving human society to achieve electronization and digitization, for example, in the judicial field, the traditional evidence form is gradually replaced by electronic evidence. However, electronic evidence is more susceptible to tampering than traditional evidence.
Disclosure of Invention
The application provides a file storage method, a file storage device, an electronic device, a storage medium and a computer program product.
According to a first aspect, the present application provides a file storage method, comprising:
the file initiating node broadcasts the target file to the block chain; the target file carries signature information of the file initiating node;
in response to the target file being verified as a legitimate file, the file originating node storing the target file in a first block;
responding to the file initiating node to send consensus preparation information, and verifying the consensus preparation information by a consensus node of the file initiating node, wherein the consensus preparation information is used for modifying the target file.
According to a second aspect, the present application provides a file storage apparatus comprising:
the first broadcasting module is used for broadcasting the target file to the block chain by the file initiating node; the target file carries signature information of the file initiating node;
a storage module, configured to, in response to the target file being verified as a legitimate file, store, by the file originating node, the target file in a first chunk;
and the verification module is used for responding to the sending of consensus preparation information by the file initiating node, the consensus node of the file initiating node verifies the consensus preparation information, and the consensus preparation information is used for modifying the target file.
According to a third aspect, the present application provides an electronic device comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform any one of the methods of the first aspect.
According to a fourth aspect, the present application provides a non-transitory computer readable storage medium having stored thereon computer instructions for causing a computer to perform any of the methods of the first aspect.
According to a fifth aspect, the present application provides a computer program product comprising a computer program which, when executed by a processor, implements any of the methods of the first aspect.
According to the technology, the file can be prevented from being illegally tampered, and the technology is applied to storage of judicial evidence, so that the anti-tampering performance of the judicial evidence can be ensured.
It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present application, nor do they limit the scope of the present application. Other features of the present application will become apparent from the following description.
Drawings
The drawings are included to provide a better understanding of the present solution and are not intended to limit the present application. Wherein:
FIG. 1 is a schematic flow chart diagram of a file storage method according to a first embodiment of the present application;
FIG. 2 is a schematic diagram of a basic principle of a blockchain credentialing technique according to a first embodiment of the present application;
FIG. 3 is a block chain technology-based electronic evidence system architecture model schematic diagram according to a first embodiment of the present application;
FIG. 4 is a schematic structural diagram of a file storage device according to a second embodiment of the present application;
fig. 5 is a block diagram of an electronic device for implementing a file storage method according to an embodiment of the present application.
Detailed Description
The following description of the exemplary embodiments of the present application, taken in conjunction with the accompanying drawings, includes various details of the embodiments of the application for the understanding of the same, which are to be considered exemplary only. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the present application. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
At present, electronic evidence is increasingly adopted in the field of justice, but the electronic evidence generally has a characteristic of being capable of being tampered, and when the electronic evidence is taken as the judicial evidence, the electronic evidence can be damaged, polluted and modified, so that the proving efficacy of the electronic evidence is low.
The block chain technology has the characteristics of anonymity, tamper resistance, high safety performance, open source and the like due to decentralization and distrust, and can realize the storage of electronic evidence by utilizing the block chain technology.
Before describing the present application, the following is a brief introduction to the related art of blockchains:
distributed storage: the core of the method is that data is divided into a plurality of small blocks, and then a distributed database is established by opening the storage space of nodes. Complete data information cannot be acquired through any single node, and independent accounting cannot be completed; the distributed storage can store data information by utilizing the free space of each node, and can solve the problems that data in a database is easy to be tampered, lost and recovered and the like.
A consensus mechanism: in the distributed storage space, multiple nodes form a network cluster in an asynchronous communication mode, and a reliable consensus state between different hosts is ensured by means of a fault-tolerant rule in an asynchronous network so as to avoid error information propagation which may occur. The consensus mechanism can be used for solving the problems of consistency and effectiveness of evidence-stored data on different nodes among individuals without trust, and can better meet the storage requirement of judicial evidence.
And (3) encryption algorithm: by adopting a common Hash algorithm, the input data information with any length can be converted into output with a fixed length in a reasonable time, has the properties of collision resistance, confidentiality and the like, and can be used for digital signature, integrity check of the certificate and consistency verification of the certificate.
Point-to-point transmission: the nodes with the same grade are used as a central server and a client, interaction can be carried out between any two nodes, and after the interaction is finished, each node in the whole network can synchronize the interaction, which is the characteristic of the maximum point-to-point transmission. The transmission mode is beneficial to avoiding the condition that the evidence storage result is inaccurate or incomplete due to the fault of a single server, and can better meet the storage requirement of judicial evidence.
The present application mainly improves on the blockchain consensus mechanism, and the following describes exemplary embodiments of the present application.
As shown in fig. 1, the file storage method includes the following steps:
step 101: the file initiating node broadcasts the target file to the block chain; the target file carries signature information of the file initiating node;
step 102: in response to the target file being verified as a legitimate file, the file originating node storing the target file in a first block;
step 103: responding to the file initiating node to send consensus preparation information, and verifying the consensus preparation information by a consensus node of the file initiating node, wherein the consensus preparation information is used for modifying the target file.
In the present application, the target document may be any document, such as a web page, a photograph, a sound recording, a video/audio, an email, an electronic signature, and other electronic evidence. The file originating node may be referred to as a master node and the consensus node of the file originating node may be referred to as a child node or a slave node.
In the block chain technology, when a file initiating node initiates a transaction, a signature of the file initiating node needs to be attached and then broadcast to the whole network, and all the common nodes of the file initiating node independently monitor the whole network transaction and verify the legality of the transaction.
In a blockchain, files may exist in the form of blocks and are permanently recorded and saved in the blockchain. Before generating the block, the validity of the file needs to be checked, and if the file is legal, the file is written into the block in batch. The file validity may be determined by considering the following conditions: (1) whether the file already exists or not is judged, if yes, the file is an illegal file, and if not, the file is a legal file; (2) whether the file accords with the file writing rule or not, if not, the file is an illegal file, and if so, the file is a legal file; (3) if the previous block to the current block is the end of the blockchain, if not, the blockchain may diverge, possibly resulting in double payment, and if so, a legal file. When the above conditions (1) to (3) are simultaneously satisfied, the file is determined to be a legitimate file.
In step 101, the file initiating node broadcasts the target file to the block chain, which may be understood as the file initiating node initiating a transaction. Accordingly, all the common nodes of the file initiating node can verify the validity of the target file. In step 102, in response to the target file being verified as a legitimate file, the file originating node may store the target file in the first chunk. After the file initiating node stores the target file in the first block, the file initiating node may modify the target file, and if the file initiating node needs to modify the target file, may send consensus preparation information, which is information for modifying the target file. In step 103, in response to the consensus preparation information sent by the file initiating node, the consensus node of the file initiating node may verify the consensus preparation information.
In the application, the consensus preparation information is sent by the file initiating node, so that the file initiating node can modify the target file, and compared with the prior art that data in a block chain cannot be modified, the method and the device have higher flexibility. On the other hand, the consensus node verifies the consensus preparation information through the consensus node of the file initiating node, so that the file initiating node cannot randomly tamper the target file, and the target file can be prevented from being illegally tampered.
According to the technology of the embodiment of the application, the file can be prevented from being illegally tampered, and the technology of the application is applied to storage of judicial evidence, so that the anti-tampering performance of the judicial evidence can be ensured.
Optionally, after the responding to the file initiating node sending the consensus preparation information and the consensus node of the file initiating node verifying the consensus preparation information, the method further includes:
and if the first consensus node of the file initiating node verifies that the consensus preparation information is true, the first consensus node broadcasts a consensus confirmation message.
In this embodiment, after receiving the consensus preparation information, the consensus node of the file initiating node may check the consensus preparation information, and if the check result is true, send the consensus confirmation information to the other nodes, that is, the first consensus node broadcasts the consensus confirmation message.
Therefore, the consensus preparation information sent by the file initiating node can be verified by other consensus nodes, and the verification result is broadcasted to all the consensus nodes, so that the file initiating node cannot randomly tamper the target file, and the target file can be prevented from being illegally tampered.
Optionally, after the responding to the file initiating node sending the consensus preparation information and the consensus node of the file initiating node verifying the consensus preparation information, the method further includes:
and if the second consensus node of the file initiating node verifies that the consensus preparation information is false, the second consensus node broadcasts a change message.
In this embodiment, after receiving the consensus preparation information, the consensus node of the file initiating node may check the consensus preparation information, and if the check result is false, the consensus node suspects the file initiating node and may send a change message to another node, that is, the second consensus node broadcasts the change message.
Therefore, the consensus preparation information sent by the file initiating node can be verified by other consensus nodes, and the verification result is broadcasted to all the consensus nodes, so that the file initiating node cannot randomly tamper the target file, and the target file can be prevented from being illegally tampered.
Optionally, the method further includes:
and in response to the number of the consensus confirmation messages received by the file initiating node reaching a first threshold, the file initiating node modifies the target file based on the consensus preparation information.
If the number of the received consensus confirmation messages reaches the first threshold, the file initiating node indicates that the consensus preparation information is verified by at least the first threshold of the consensus nodes, where the first threshold may be half of the total number of the consensus nodes or one third of the total number of the consensus nodes, and the application does not limit this.
In this embodiment, through the above consensus process, the file initiating node may modify the target file when the consensus is completed, so that the application has greater flexibility than the case where data in the block chain cannot be modified in the prior art.
Optionally, the method further includes:
and in response to the number of the consensus confirmation messages received by the file initiating node being smaller than the first threshold, prohibiting the file initiating node from modifying the target file based on the consensus preparation information.
In this embodiment, through the above consensus process, the file originating node is prohibited from modifying the target file based on the consensus preparation information under the condition that the consensus is not completed, so that the file originating node cannot randomly tamper with the target file, and thus the target file can be prevented from being illegally tampered.
Optionally, after the responding to the file initiating node sending the consensus preparation information and the consensus node of the file initiating node verifying the consensus preparation information, the method further includes:
and in response to detecting that the third consensus node of the file initiating node is abnormal, deleting the third consensus node from the set of consensus nodes of the file initiating node.
This embodiment can implement dynamic change of the node state, and is briefly described as follows:
in the existing block chain technology, a POW (Proof Of Work) consensus algorithm is generally adopted for implementation Of a bottom-layer algorithm for file storage. Considering that the coalition chain does not need the high Fault Tolerance of the POW consensus algorithm, the present application can combine the advantages of the PBFT (physical Byzantine Fault Tolerance system) consensus algorithm with the block chain to adapt to the application of the block chain to judicial evidence. And in consideration of the defect that the PBFT consensus algorithm billing node cannot be modified once being determined, the node state dynamic change method is improved, so that the node state dynamic change can be realized.
Assuming that the maximum number of fault nodes tolerated in the system is f, according to the byzantine fault tolerance, it is assumed that there are 3f +1 nodes in the blockchain system.
State change is introduced in the algorithm, different states are granted to different nodes, and within a period of time, if a node is a node with poor consensus performance, the node is degraded, for example, the node is deleted from a consensus node set of the file initiating node, and for example, for some abnormal nodes (for example, when the node is abnormal), the file initiating node can not calculate the message of the node any more. In addition, the node with better performance in the candidate node set in the time period can be upgraded, for example, the node is added into the common node set of the file initiating node.
In the embodiment, the influence of the abnormal node on consensus can be reduced by introducing a dynamic change mechanism of node upgrading and downgrading.
In addition, the PBFT consensus algorithm is a classical distributed consensus algorithm, and a normal execution request mainly includes three processes of pre-preparation (pre-prepare), preparation (prepare) and confirmation (commit) (referred to as a three-stage execution request for short). The purpose of the three-segment execution request is mainly to ensure that the instruction sequence still executes correctly in the distributed system based on the state machine copy, and the basic goal of the blockchain consensus mechanism is to achieve consensus on the whole network and not to require the instruction sequence to be completely correct. Block chaining consensus requires the broadcast of information throughout the network, whereas information is already broadcast throughout the network during the pre-prepare and prepare phases. In view of this, the present application can combine and simplify the original three-stage process, for example, a two-stage process. Therefore, one-time information transmission in the whole network can be reduced, and the efficiency is improved.
The application of the blockchain file storage method of the present application to judicial evidence storage is briefly described below.
Fig. 2 shows a basic principle diagram of the blockchain evidence storing technology.
FIG. 3 is a block chain technology-based electronic evidence system architecture model diagram, which can be applied to the block chain evidence-based electronic evidence-based technology. The system mainly comprises an electronic data information acquisition module, a linear data packaging module, a block chain system and a system database, wherein the main functions of the modules are as follows:
an electronic data acquisition module: and collecting a Hash characteristic value 1 of user certificate storage data, stamping a time stamp on the collected data, extracting a Hash characteristic value 2, and recording the collected data and the original data into a system database. The electronic data may include transaction records, audio files, video files, and other documents. The electronic data acquisition module comprises a data processing unit and a data storage unit. The electronic data acquisition module comprises new data uploaded and data which is not uploaded but updates the existing data.
A linearized data packing module: and when the electronic data information is acquired, the hash characteristic value 2 and the time stamp are transmitted to a linear data packaging module, hash operation is carried out on the hash characteristic value 2 and the time stamp in the module by taking time as a sequence, and finally an explicit chained data structure based on a time axis is generated. The characteristic of the hash operation determines that after the hash characteristic value 2 of each file is linearized, the state of the data is basically determined when the data exists. During specific operation, the data can be packed according to unit time, and the evidence storage files can also be packed according to unit quantity. The former is packed according to fixed time interval, which is suitable for use when the data volume or concurrency is large, and can complete the solidification of data information in fixed time; the latter packs and puts in storage the data according to the size of the data scale, and is suitable for the condition that the data volume is small or the curing time of the data state is insensitive.
The block chain system: the system solidifies the data state onto the blockchain as blockchain system interaction, and has the main tasks of submitting the data information to the blockchain system, checking and confirming the data state and ensuring that the data information is recorded into a system database.
A system database: the system database may be a centralized database.
It should be noted that various optional embodiments in the file storage method in the present application may be implemented in combination with each other, or may be implemented separately, and the present application is not limited thereto.
The above embodiments of the present application have at least the following advantages or benefits:
according to the technology, the file can be prevented from being illegally tampered, and the technology is applied to storage of judicial evidence, so that the anti-tampering performance of the judicial evidence can be ensured.
As shown in fig. 4, the present application provides a file storage apparatus 400 comprising:
a first broadcasting module 401, configured to broadcast, by a file initiating node, a target file to a blockchain; the target file carries signature information of the file initiating node;
a storage module 402, configured to, in response to the target file being verified as a valid file, store the target file in a first chunk by the file originating node;
a verification module 403, configured to respond to the file initiating node sending consensus preparation information, where the consensus node of the file initiating node verifies the consensus preparation information, and the consensus preparation information is used to modify the target file.
Optionally, the file storage apparatus 400 further includes:
a second broadcasting module, configured to broadcast a consensus confirmation message by the first consensus node if the first consensus node of the file initiating node verifies that the consensus preparation information is true.
Optionally, the file storage apparatus 400 further includes:
a third broadcasting module, configured to broadcast a change message by a second consensus node of the file initiating node if the second consensus node verifies that the consensus preparation information is false.
Optionally, the file storage apparatus 400 further includes:
and the modification module is used for responding that the number of the consensus confirmation messages received by the file initiating node reaches a first threshold value, and the file initiating node modifies the target file based on the consensus preparation information.
Optionally, the file storage apparatus 400 further includes:
and the forbidding module is used for forbidding the file initiating node to modify the target file based on the consensus preparation information in response to the fact that the number of the consensus confirmation messages received by the file initiating node is smaller than the first threshold.
Optionally, the file storage apparatus 400 further includes:
and the deleting module is used for deleting the third consensus node from the consensus node set of the file initiating node in response to the third consensus node of the file initiating node being detected to have abnormality.
The file storage apparatus 400 provided in this embodiment of the present application can implement each process in the above file storage method embodiments, and can achieve the same beneficial effects, and for avoiding repetition, details are not repeated here.
There is also provided, in accordance with an embodiment of the present application, an electronic device, a readable storage medium, and a computer program product.
FIG. 5 illustrates a schematic block diagram of an example electronic device 500 that can be used to implement embodiments of the present disclosure. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the present application that are described and/or claimed herein.
As shown in fig. 5, the electronic device 500 includes a computing unit 501, which can perform various appropriate actions and processes according to a computer program stored in a Read Only Memory (ROM)502 or a computer program loaded from a storage unit 508 into a Random Access Memory (RAM) 503. In the RAM503, various programs and data required for the operation of the device 500 can also be stored. The calculation unit 501, the ROM502, and the RAM503 are connected to each other by a bus 504. An input/output (I/O) interface 505 is also connected to bus 504.
A number of components in the electronic device 500 are connected to the I/O interface 505, including: an input unit 506 such as a keyboard, a mouse, or the like; an output unit 507 such as various types of displays, speakers, and the like; a storage unit 508, such as a magnetic disk, optical disk, or the like; and a communication unit 509 such as a network card, modem, wireless communication transceiver, and the like. The communication unit 509 allows the electronic device 500 to exchange information/data with other devices through a computer network such as the internet and/or various telecommunication networks.
The computing unit 501 may be a variety of general-purpose and/or special-purpose processing components having processing and computing capabilities. Some examples of the computing unit 501 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various dedicated Artificial Intelligence (AI) computing chips, various computing units running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, and so forth. The calculation unit 501 executes the respective methods and processes described above, such as a file storage method. For example, in some embodiments, the file storage method may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as storage unit 508. In some embodiments, part or all of the computer program may be loaded and/or installed onto the device 500 via the ROM502 and/or the communication unit 509. When the computer program is loaded into the RAM503 and executed by the computing unit 501, one or more steps of the file storage method described above may be performed. Alternatively, in other embodiments, the computing unit 501 may be configured to perform the file storage method by any other suitable method (e.g., by means of firmware).
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuitry, Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), system on a chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
Program code for implementing the methods of the present disclosure may be written in any combination of one or more editing languages. These program codes may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program codes, when executed by the processor or controller, cause the functions/operations specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), the internet, and blockchain networks.
The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The Server can be a cloud Server, also called a cloud computing Server or a cloud host, and is a host product in a cloud computing service system, so as to solve the defects of high management difficulty and weak service expansibility in the traditional physical host and VPS service ("Virtual Private Server", or simply "VPS"). The server may also be a server of a distributed system, or a server incorporating a blockchain.
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in the present application may be executed in parallel, sequentially, or in different orders, and the present invention is not limited thereto as long as the desired results of the technical solutions disclosed in the present application can be achieved.
The above-described embodiments should not be construed as limiting the scope of the present application. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made in accordance with design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims (15)

1. A file storage method, comprising:
the file initiating node broadcasts the target file to the block chain; the target file carries signature information of the file initiating node;
in response to the target file being verified as a legitimate file, the file originating node storing the target file in a first block;
responding to the file initiating node to send consensus preparation information, and verifying the consensus preparation information by a consensus node of the file initiating node, wherein the consensus preparation information is used for modifying the target file.
2. The method of claim 1, after the responding to the file originating node sending consensus preparation information, the consensus preparation information verified by the file originating node's consensus node, the method further comprising:
and if the first consensus node of the file initiating node verifies that the consensus preparation information is true, the first consensus node broadcasts a consensus confirmation message.
3. The method of claim 1, after the responding to the file originating node sending consensus preparation information, the consensus preparation information verified by the file originating node's consensus node, the method further comprising:
and if the second consensus node of the file initiating node verifies that the consensus preparation information is false, the second consensus node broadcasts a change message.
4. The method of claim 2, further comprising:
and in response to the number of the consensus confirmation messages received by the file initiating node reaching a first threshold, the file initiating node modifies the target file based on the consensus preparation information.
5. The method of claim 4, further comprising:
and in response to the number of the consensus confirmation messages received by the file initiating node being smaller than the first threshold, prohibiting the file initiating node from modifying the target file based on the consensus preparation information.
6. The method of claim 1, after the responding to the file originating node sending consensus preparation information, the consensus preparation information verified by the file originating node's consensus node, the method further comprising:
and in response to detecting that the third consensus node of the file initiating node is abnormal, deleting the third consensus node from the set of consensus nodes of the file initiating node.
7. A file storage device comprising:
the first broadcasting module is used for broadcasting the target file to the block chain by the file initiating node; the target file carries signature information of the file initiating node;
a storage module, configured to, in response to the target file being verified as a legitimate file, store, by the file originating node, the target file in a first chunk;
and the verification module is used for responding to the sending of consensus preparation information by the file initiating node, the consensus node of the file initiating node verifies the consensus preparation information, and the consensus preparation information is used for modifying the target file.
8. The apparatus of claim 7, further comprising:
a second broadcasting module, configured to broadcast a consensus confirmation message by the first consensus node if the first consensus node of the file initiating node verifies that the consensus preparation information is true.
9. The apparatus of claim 7, further comprising:
a third broadcasting module, configured to broadcast a change message by a second consensus node of the file initiating node if the second consensus node verifies that the consensus preparation information is false.
10. The apparatus of claim 8, further comprising:
and the modification module is used for responding that the number of the consensus confirmation messages received by the file initiating node reaches a first threshold value, and the file initiating node modifies the target file based on the consensus preparation information.
11. The apparatus of claim 10, further comprising:
and the forbidding module is used for forbidding the file initiating node to modify the target file based on the consensus preparation information in response to the fact that the number of the consensus confirmation messages received by the file initiating node is smaller than the first threshold.
12. The apparatus of claim 7, further comprising:
and the deleting module is used for deleting the third consensus node from the consensus node set of the file initiating node in response to the third consensus node of the file initiating node being detected to have abnormality.
13. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1 to 6.
14. A non-transitory computer readable storage medium having stored thereon computer instructions for causing the computer to perform the method of any one of claims 1 to 6.
15. A computer program product comprising a computer program which, when executed by a processor, implements the method of any one of claims 1 to 6.
CN202110138638.1A 2021-02-01 2021-02-01 File storage method and device, electronic equipment and storage medium Pending CN112835854A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110138638.1A CN112835854A (en) 2021-02-01 2021-02-01 File storage method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110138638.1A CN112835854A (en) 2021-02-01 2021-02-01 File storage method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN112835854A true CN112835854A (en) 2021-05-25

Family

ID=75931460

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110138638.1A Pending CN112835854A (en) 2021-02-01 2021-02-01 File storage method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112835854A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113378144A (en) * 2021-07-14 2021-09-10 湖北央中巨石信息技术有限公司 Image file consensus method, system, device and medium based on block chain

Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108492103A (en) * 2018-02-07 2018-09-04 北京大学深圳研究生院 A kind of alliance's block chain common recognition method
CN109033475A (en) * 2018-09-10 2018-12-18 湖南智慧政务区块链科技有限公司 A kind of file memory method, device, equipment and storage medium
CN110309672A (en) * 2019-07-01 2019-10-08 北京理工大学 A kind of controlled data management method of the secret protection based on block chain
CN110336707A (en) * 2019-08-07 2019-10-15 卓尔智联(武汉)研究院有限公司 Block chain common recognition device, method and computer readable storage medium
CN110474925A (en) * 2019-09-19 2019-11-19 腾讯科技(深圳)有限公司 Judicial document delivery information sharing method, device and computer readable storage medium
CN110956542A (en) * 2019-11-07 2020-04-03 支付宝(杭州)信息技术有限公司 Block chain system and operation method, device and equipment thereof
CN111125115A (en) * 2019-12-26 2020-05-08 山东爱城市网信息技术有限公司 Data storage method, device and medium based on block chain
CN111310206A (en) * 2020-02-12 2020-06-19 腾讯科技(深圳)有限公司 Data encryption method, node equipment and storage medium
CN111371768A (en) * 2020-02-27 2020-07-03 浙江超脑时空科技有限公司 Consensus processing method, authentication initiating node, authentication node, device, and medium
CN111654395A (en) * 2020-06-01 2020-09-11 腾讯科技(深圳)有限公司 Voting information processing method, device, equipment and storage medium
CN111711711A (en) * 2020-05-28 2020-09-25 北京邮电大学 Block chain-based top-level domain name management and analysis method and system

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108492103A (en) * 2018-02-07 2018-09-04 北京大学深圳研究生院 A kind of alliance's block chain common recognition method
CN109033475A (en) * 2018-09-10 2018-12-18 湖南智慧政务区块链科技有限公司 A kind of file memory method, device, equipment and storage medium
CN110309672A (en) * 2019-07-01 2019-10-08 北京理工大学 A kind of controlled data management method of the secret protection based on block chain
CN110336707A (en) * 2019-08-07 2019-10-15 卓尔智联(武汉)研究院有限公司 Block chain common recognition device, method and computer readable storage medium
CN110474925A (en) * 2019-09-19 2019-11-19 腾讯科技(深圳)有限公司 Judicial document delivery information sharing method, device and computer readable storage medium
CN110956542A (en) * 2019-11-07 2020-04-03 支付宝(杭州)信息技术有限公司 Block chain system and operation method, device and equipment thereof
CN111125115A (en) * 2019-12-26 2020-05-08 山东爱城市网信息技术有限公司 Data storage method, device and medium based on block chain
CN111310206A (en) * 2020-02-12 2020-06-19 腾讯科技(深圳)有限公司 Data encryption method, node equipment and storage medium
CN111371768A (en) * 2020-02-27 2020-07-03 浙江超脑时空科技有限公司 Consensus processing method, authentication initiating node, authentication node, device, and medium
CN111711711A (en) * 2020-05-28 2020-09-25 北京邮电大学 Block chain-based top-level domain name management and analysis method and system
CN111654395A (en) * 2020-06-01 2020-09-11 腾讯科技(深圳)有限公司 Voting information processing method, device, equipment and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
宋刚: "网络艺术社会学 现场与在场", 31 December 2020, 南昌:江西美术出版社, pages: 68 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113378144A (en) * 2021-07-14 2021-09-10 湖北央中巨石信息技术有限公司 Image file consensus method, system, device and medium based on block chain
CN113378144B (en) * 2021-07-14 2022-09-02 湖北央中巨石信息技术有限公司 Image file consensus method, system, device and medium based on block chain

Similar Documents

Publication Publication Date Title
CN109791591B (en) Method and system for identity and credential protection and verification via blockchain
CN109242685B (en) Block chain-based consensus and verification method and device
CN111163182B (en) Block chain-based device registration method and apparatus, electronic device, and storage medium
US10432411B2 (en) System and method for file time-stamping using a blockchain network
CN116882994A (en) Method and system for providing authenticated, auditable and immutable input for intelligent contracts
US20210049715A1 (en) Blockchain-based data procesing method, apparatus, and electronic device
US20200329022A1 (en) Data authentication method, apparatus, and system
CN112738253A (en) Data processing method, device and equipment based on block chain and storage medium
CN111209339B (en) Block synchronization method, device, computer and storage medium
CN110324416B (en) Download path tracking method, device, server, terminal and medium
CN109409882A (en) A kind of credit accreditation storage method and device based on block chain
CN109902493B (en) Script issuing method and server
CN113570479B (en) Block chain transmission method, system and storage medium for real estate transaction data
CN112134883B (en) Method, device and related product for carrying out rapid authentication on trust relationship between nodes based on trusted computing
CN113312326B (en) Method, electronic device and computer program product for storage management
CN107171808B (en) A kind of verification method and device of electronic record authenticity
CN109858285B (en) Block chain data processing method, device, equipment and medium
CN112835854A (en) File storage method and device, electronic equipment and storage medium
CN112583805B (en) Block chain-based data processing method and device, electronic equipment and storage medium
CN110598374B (en) Block chain-based work registration method, apparatus and computer-readable storage medium
CN110381114B (en) Interface request parameter processing method and device, terminal equipment and medium
CN116739596A (en) Blockchain-based transaction supervision method, device, equipment, medium and product
WO2020134637A1 (en) Key component verification method and apparatus, and terminal device
CN114398678A (en) Registration verification method and device for preventing electronic file from being tampered, electronic equipment and medium
CN113592645A (en) Data verification method and device

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