CN112487497A - Method and device for managing off-link files based on intelligent contracts and electronic equipment - Google Patents

Method and device for managing off-link files based on intelligent contracts and electronic equipment Download PDF

Info

Publication number
CN112487497A
CN112487497A CN202011457643.0A CN202011457643A CN112487497A CN 112487497 A CN112487497 A CN 112487497A CN 202011457643 A CN202011457643 A CN 202011457643A CN 112487497 A CN112487497 A CN 112487497A
Authority
CN
China
Prior art keywords
file
chain
intelligent contract
data
target file
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
CN202011457643.0A
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.)
Hangzhou Rivtower Technology Co Ltd
Original Assignee
Hangzhou Rivtower 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 Hangzhou Rivtower Technology Co Ltd filed Critical Hangzhou Rivtower Technology Co Ltd
Priority to CN202011457643.0A priority Critical patent/CN112487497A/en
Publication of CN112487497A publication Critical patent/CN112487497A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • 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
    • G06F2221/00Indexing scheme relating to security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F2221/21Indexing scheme relating to G06F21/00 and subgroups addressing additional information or applications relating to security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F2221/2107File encryption

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Theoretical Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Bioethics (AREA)
  • General Health & Medical Sciences (AREA)
  • Computer Hardware Design (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Storage Device Security (AREA)

Abstract

One or more embodiments of the present specification disclose a method, an apparatus, and an electronic device for managing an out-of-chain file based on an intelligent contract, where the method includes: the data original text of the file to be stored is stored in the off-chain storage space, meanwhile, the attribute parameters of the data fingerprint obtained by performing fingerprint calculation on the data original text are mapped to the intelligent contract and are associated with the file identification of the file to be stored, therefore, the file to be stored outside the chain is associated to the intelligent contract, effective management of the file outside the chain on the chain is achieved, the data fingerprint can be guaranteed to be incapable of being tampered in the storage process after being stored on the chain, meanwhile, the efficiency of chain loading storage is guaranteed, and therefore the management level of the file outside the chain is improved.

Description

Method and device for managing off-link files based on intelligent contracts and electronic equipment
Technical Field
The present invention relates to the field of blockchain technologies, and in particular, to a method and an apparatus for managing an off-chain file based on an intelligent contract, and an electronic device.
Background
The blockchain is a decentralized and innovative solution for solving the multi-party trust problem by using a distributed book technology, and is a leading-edge technology of the current society.
Currently, blockchains generally use smart contracts in the financial field to represent financial assets. The financial assets usually relate to the rights and obligations of investors and distributors, and the content still needs to be saved in the traditional legal documents and contracts and the like at the current stage, so that the important documents such as the legal documents and the contracts cannot be guaranteed not to be tampered. If the important file contents are directly linked to be stored, the files can be prevented from being maliciously tampered, but the storage pressure is inevitably caused due to the large number of files and the large content. Therefore, the existing file management scheme has a plurality of defects.
Disclosure of Invention
One or more embodiments of the present disclosure provide a method, an apparatus, and an electronic device for managing an off-link file based on an intelligent contract, so as to ensure that the file is not tampered, ensure efficiency of uplink certificate storage, and improve a management level of the off-link file.
To solve the above technical problem, one or more embodiments of the present specification are implemented as follows:
in a first aspect, a method for managing an out-of-chain file based on an intelligent contract is provided, which includes:
acquiring a target file to be stored, wherein a data original text of the target file is stored outside a chain;
determining attribute parameters related to management process data in the target file based on file management attributes preset in the intelligent contract, wherein the file management attributes at least comprise: a file data fingerprint;
and uploading the determined attribute parameters and the file identification of the target file to the intelligent contract for associated storage.
In a second aspect, an apparatus for managing an out-of-chain file based on an intelligent contract is provided, including:
the acquisition module is used for acquiring a target file to be stored, wherein the data original text of the target file is stored outside a chain;
the determining module is used for determining attribute parameters related to management process data in the target file based on preset file management attributes in the intelligent contract; wherein the file management attributes include at least: a file data fingerprint;
and the storage module is used for uploading the determined attribute parameters and the file identification of the target file to the intelligent contract for associated storage.
In a third aspect, an electronic device is provided, including:
a processor; and
a memory arranged to store computer executable instructions that, when executed, cause the processor to perform:
acquiring a target file to be stored, wherein a data original text of the target file is stored outside a chain;
determining attribute parameters related to management process data in the target file based on file management attributes preset in the intelligent contract, wherein the file management attributes at least comprise: a file data fingerprint;
and uploading the determined attribute parameters and the file identification of the target file to the intelligent contract for associated storage.
In a fourth aspect, a computer-readable storage medium is presented, storing one or more programs which, when executed by an electronic device comprising a plurality of application programs, cause the electronic device to perform:
acquiring a target file to be stored, wherein a data original text of the target file is stored outside a chain;
determining attribute parameters related to management process data in the target file based on file management attributes preset in the intelligent contract, wherein the file management attributes at least comprise: a file data fingerprint;
and uploading the determined attribute parameters and the file identification of the target file to the intelligent contract for associated storage.
The technical scheme provided by one or more embodiments of the present specification can be seen that a data original text of a file to be certified is stored in an off-link storage space, and meanwhile, attribute parameters of a data fingerprint obtained by performing fingerprint calculation on the data original text are mapped to an intelligent contract to be associated with a file identifier of the file to be certified.
Drawings
In order to more clearly illustrate one or more embodiments or prior art solutions of the present specification, reference will now be made briefly to the attached drawings, which are needed in the description of one or more embodiments or prior art, and it should be apparent that the drawings in the description below are only some of the embodiments described in the specification, and that other drawings may be obtained by those skilled in the art without inventive exercise.
Fig. 1a to fig. 1c are schematic diagrams respectively illustrating steps of a method for managing an out-of-chain file based on an intelligent contract according to an embodiment of the present specification.
Fig. 2a to fig. 2e are schematic structural diagrams of an off-link file management apparatus based on an intelligent contract according to an embodiment of the present specification.
Fig. 3 is a schematic structural diagram of an electronic device provided in an embodiment of the present specification.
Detailed Description
In order to make the technical solutions in the present specification better understood, the technical solutions in one or more embodiments of the present specification will be clearly and completely described below with reference to the accompanying drawings in one or more embodiments of the present specification, and it is obvious that the one or more embodiments described are only a part of the embodiments of the present specification, and not all embodiments. All other embodiments that can be derived by a person skilled in the art from one or more of the embodiments described herein without making any inventive step shall fall within the scope of protection of this document.
Based on the file management scheme mentioned in the background art, although directly storing the file on the link can ensure that the file is not tampered, it is not feasible due to the problem of storage efficiency. And if the fingerprint of the file is chained, the file can be directly chained to store the certificate, and the file is stored outside the chain, and meanwhile, the file management party outside the chain is restrained by the mode of the fingerprint on the chain from maliciously tampering the file. However, this method merely links the file fingerprint for storage, and cannot effectively manage the attribute parameters related to the management process data, such as file identification, file storage address, and file change history. Therefore, the file management scheme in the specification can be adopted, the data original text of the file to be stored is stored in the off-chain storage space, meanwhile, the attribute parameters of the data fingerprint obtained by performing fingerprint calculation on the data original text are mapped to the intelligent contract and are associated with the file identification of the file to be stored, in this way, the file to be stored, which is stored outside the chain, is associated to the intelligent contract, the effective management of the off-chain file on the chain is realized, the data fingerprint can be guaranteed to be incapable of being tampered in the storing process after the storing of the certificate on the chain, and the uplink storing efficiency is guaranteed, so that the management level of the off-chain file is improved.
Example one
Referring to fig. 1a, a method for managing an out-of-chain file based on an intelligent contract is provided for the embodiments of the present specification, it should be understood that, in the financial field, management of a financial asset may be implemented by an intelligent contract, and in particular, related asset information content such as a rights and interest share of the financial asset may be maintained in the intelligent contract. Since the financial assets may relate to important documents such as related legal documents and contracts, in this embodiment of the present specification, such important documents may be managed in combination with an intelligent contract, and the specific management scheme may include the following steps:
step 102: and acquiring a target file to be stored, wherein the data original text of the target file is stored outside the chain.
In an implementation scheme, a user side serving as any block node module of a block link network can acquire a target file to be stored, and a data original text of the target file can be stored in an out-of-link storage space in advance.
Step 104: determining attribute parameters related to management process data in the target file based on file management attributes preset in the intelligent contract, wherein the file management attributes at least comprise: file data fingerprints.
It should be understood that, when performing the fingerprint calculation, the data fingerprint algorithm used may be implemented according to an existing scheme for processing the data fingerprint, for example, a hash algorithm is used to calculate the data fingerprint, and other algorithms are not exemplified herein. The target file after chain loading and certification can ensure data security and credibility, is not easy to tamper and is convenient to manage.
In this embodiment of the present specification, what is different from the existing scheme is that a file management attribute may be preset in an intelligent contract, and for a complete file, the file management attribute may at least include: file data fingerprint: type bytes 32; document storage time: type uint 256; file modification time: type uint 256; file storage address (URI, uniform resource identifier): type string, through which the file can be obtained. In fact, the file management attribute may further include a file identifier, type byte32, which has an identification uniqueness.
In one implementation, an asset management sub-contract may be added to an existing intelligent contract, where the asset management sub-contract is pre-set with file management attributes, and the types and calling modes of the attributes are defined.
Step 106: and uploading the determined attribute parameters and the file identification of the target file to the intelligent contract for associated storage.
It should be understood that in the embodiment of the present specification, the attribute parameters and the file identification may be stored in association in the smart contract in a manner of sending a transaction to the blockchain. Therefore, the transaction data can be recorded and stored in a block mode in the block chain for subsequent inquiry.
Specifically, taking the summary language description of EtherFang as an example, the interface is defined as follows:
Figure BDA0002829628690000051
Figure BDA0002829628690000061
when the attribute parameters of the target file are uploaded, the corresponding interface can be called by referring to the following method:
function setDocument(bytes32_name,string_uri,bytes32_documentHash)external;
function of adding documents
Inputting parameters:
@ param _ name file identification
Uniform resource locator (URI) for @ param _ URI file
@ param _ documentHash value of content hash (i.e., data fingerprint)
Note that document addition fails, the setDocument must throw exceptions; document addition is successful and must trigger a DocumentUpdated event.
Therefore, the attribute parameters and the file identification of the target file are uploaded to the intelligent contract for associated storage through the mode, so that off-link file storage process data can be conveniently managed in the intelligent contract, and the management efficiency and the reliability are improved.
It should be understood that, in the embodiment of this specification, the method for managing an out-of-chain file may specifically include: and inquiring the data original text of the target file, verifying the inquired data original text, updating the target file and deleting the target file.
An implementable scenario, as shown with reference to fig. 1b, where the file management attributes further comprise a file storage address, then, for a certified target file, the method further comprises:
step 108: and inquiring the file storage address of the target file from the intelligent contract based on the file identification of the target file to be inquired.
In specific implementation, a getDocument method can be called;
function getDocument(bytes32_name)external view returns(string,bytes32,uint256);
function of obtaining file attribute parameters by file identification
Inputting parameters:
@ param _ name file identification
Returning parameters:
uniform resource locator (URI) for @ return string file
@ return byte32 content hash value
The timestamp of the latest modification of @ return agent 256
Step 110: and acquiring the data original text of the target file from the off-link storage space corresponding to the file storage address.
Further, after acquiring the data original text of the target file, in order to determine whether the data original text is the original data content, the steps shown in fig. 1c may be referred to:
step 112: and inquiring the file content hash of the target file from the intelligent contract based on the file identification of the target file to be inquired.
Step 114: and comparing the file content hash with the hash of the data original text acquired from the out-of-link storage space, if the file content hash is consistent with the hash of the data original text acquired from the out-of-link storage space, determining that the data original text stored out of the link is not modified, and otherwise, determining that the data original text stored out of the link is modified.
Considering that modification of the data original text stored outside the chain (for example, modification of the asset share of an asset beneficiary) inevitably occurs in the process of managing the files outside the chain, and/or when the attribute parameters related to the data of the management process in the target file are changed (for example, modification of the file identification), the method further comprises:
sending the changed data fingerprint to a block chain for evidence storage and updating; and/or the presence of a gas in the gas,
and updating the changed attribute parameters to the intelligent contract to be stored in association with the file identification of the target file.
Specifically, the process of adding the attribute parameter of the target file shown in fig. 1a may be referred to when changing.
Further, when the target file is deleted, the method further comprises:
and deleting the attribute parameters stored in the intelligent contract in association with the file identification of the target file.
In specific implementation, the removeDocument method may be called:
function removeDocument(bytes32_name)external;
function of deleting file
Inputting parameters:
@ param _ name document name
It is worth noting that the file deletion fails, and the removeDocument must throw an exception; the file deletion is successful and a DocumentRemoved event must be triggered.
In fact, the embodiment of the present specification further includes a management method, that is, a query is performed on all the out-of-link files;
in specific implementation, the getAllDocuments method may be invoked:
function getAllDocuments()external view returns(bytes32[]);
the function is that all the file lists added on the same intelligent contract are returned, including:
files added through setDocument and files not deleted by removeDocument
It should be understood that, in the above scheme, the file events involved, specifically implementing the code, are as follows:
event DocumentRemoved(bytes32 indexed_name,string_uri,bytes32_documentHash);
event DocumentUpdated(bytes32 indexed_name,string_uri,bytes32_documentHash);
@ param _ name file identification
Uniform resource locator (URI) for @ param _ URI file
@ param _ documentHash value of content hash (i.e., data fingerprint)
According to the scheme, the file management interface comprises a document adding or updating and deleting method for managing document adding, deleting and modifying operations, and the two methods can modify the state on a chain, so that a file event needs to be triggered. The file query mainly comprises two method interfaces of querying a document through a document name and querying all document names.
Wherein, the consistency of Ether Fang defines the storage structure of the file in the contract as:
Figure BDA0002829628690000091
mapping(bytes32=>Document)documents;
the structure is used for representing files, including uri, documentHash and timestamp. And maintaining a file list by using a map structure, and managing by taking the file identifier as Key and the file structure as Value.
Through the technical scheme, the data original text of the file to be stored is stored in the off-chain storage space, meanwhile, the attribute parameters of the data fingerprint obtained by performing fingerprint calculation on the data original text are mapped to the intelligent contract and are associated with the file identification of the file to be stored, therefore, the file to be stored outside the chain is associated to the intelligent contract, effective management of the off-chain file on the chain is achieved, the data fingerprint can be guaranteed to be incapable of being tampered in the storage process after the storage on the chain, meanwhile, the efficiency of cochain storage is guaranteed, and therefore the management level of the off-chain file is improved.
Example two
Referring to fig. 2a, an apparatus 200 for managing an out-of-chain file based on an intelligent contract provided for an embodiment of the present specification, the apparatus 200 may include:
an obtaining module 202, configured to obtain a target file to be stored, where a data original text of the target file is stored outside a chain;
a determining module 204, configured to determine, based on a file management attribute preset in an intelligent contract, an attribute parameter related to management process data in the target file; wherein the file management attributes include at least: a file data fingerprint;
and the storage module 206 is configured to upload the determined attribute parameters and the file identifier of the target file to the intelligent contract for associated storage.
Optionally, as an embodiment, referring to fig. 2b, the apparatus further includes:
the query module 208 is configured to query a file storage address of a target file from the intelligent contract based on a file identifier of the target file to be queried; and the number of the first and second groups,
and the data source file is used for acquiring the data source file of the target file from the out-of-link storage space corresponding to the file storage address.
In a specific implementation manner of the embodiment of the present specification, referring to fig. 2c, the apparatus further includes:
the verification module 210 is configured to query a file data fingerprint of a target file from the intelligent contract based on a file identifier of the target file to be queried; and
and the data fingerprint comparison module is used for comparing the file data fingerprint with the data fingerprint of the data original text acquired from the storage space outside the chain, if the file data fingerprint is consistent with the data fingerprint of the data original text acquired from the storage space outside the chain, the data original text stored outside the chain is determined to be not modified, and otherwise, the data original text stored outside the chain is determined to be modified.
In a further specific implementation manner of the embodiment of the present specification, referring to fig. 2d, the apparatus further includes:
and the updating module 212 is configured to update the changed attribute parameters to the intelligent contract to be stored in association with the file identifier of the target file when the target file is changed.
In this embodiment, the update module 212 and the parameter storage module 206 may be combined into a single module, and perform the add/update operation of the target file together.
In a further specific implementation manner of the embodiment of the present specification, referring to fig. 2e, the apparatus further includes:
and the deleting module 214 is configured to delete the attribute parameters stored in the intelligent contract in association with the file identifier of the target file when the target file is deleted.
Through the technical scheme, the data original text of the file to be stored is stored in the off-chain storage space, meanwhile, the attribute parameters containing the data fingerprint are mapped to the intelligent contract and are associated with the file identification of the file to be stored, therefore, the file to be stored outside the chain is associated to the intelligent contract, effective management of the file outside the chain on the chain is achieved, the data fingerprint can guarantee that the data in the storage process cannot be tampered after the data fingerprint is stored on the chain, the efficiency of chaining and storage is guaranteed simultaneously, and therefore the management level of the file outside the chain is improved.
EXAMPLE III
Fig. 3 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure. Referring to fig. 3, at a hardware level, the electronic device includes a processor, and optionally further includes an internal bus, a network interface, and a memory. The Memory may include a Memory, such as a Random-Access Memory (RAM), and may further include a non-volatile Memory, such as at least 1 disk Memory. Of course, the electronic device may also include hardware required for other services.
The processor, the network interface, and the memory may be connected to each other via an internal bus, which may be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, an EISA (Extended Industry Standard Architecture) bus, or the like. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one double-headed arrow is shown in FIG. 3, but this does not indicate only one bus or one type of bus.
And the memory is used for storing programs. In particular, the program may include program code comprising computer operating instructions. The memory may include both memory and non-volatile storage and provides instructions and data to the processor.
The processor reads the corresponding computer program from the nonvolatile memory into the memory and then runs the computer program, and forms a management device for the out-of-chain files based on the intelligent contract on a logic level. The processor is used for executing the program stored in the memory and is specifically used for executing the following operations:
acquiring a target file to be stored, wherein a data original text of the target file is stored outside a chain;
determining attribute parameters related to management process data in the target file based on file management attributes preset in the intelligent contract, wherein the file management attributes at least comprise: a file data fingerprint;
and uploading the determined attribute parameters and the file identification of the target file to the intelligent contract for associated storage.
The method performed by the apparatus according to the embodiments shown in fig. 1a to 1c in this specification can be implemented in a processor or implemented by a processor. The processor may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by integrated logic circuits of hardware in a processor or instructions in the form of software. The Processor may be a general-purpose Processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but also Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components. The methods, steps, and logic blocks disclosed in one or more embodiments of the present specification may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of a method disclosed in connection with one or more embodiments of the present disclosure may be embodied directly in hardware, in a software module executed by a hardware decoding processor, or in a combination of the hardware and software modules executed by a hardware decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art. The storage medium is located in a memory, and a processor reads information in the memory and completes the steps of the method in combination with hardware of the processor.
The electronic device may also execute the method shown in fig. 1a to 1c, and implement the functions of the corresponding apparatus in the embodiments shown in fig. 1a to 1c, which are not described herein again in this specification.
Of course, besides the software implementation, the electronic device of the embodiment of the present disclosure does not exclude other implementations, such as a logic device or a combination of software and hardware, and the like, that is, the execution subject of the following processing flow is not limited to each logic unit, and may also be hardware or a logic device.
Through the technical scheme, the data original text of the file to be stored is stored in the off-chain storage space, meanwhile, the attribute parameters of the data fingerprint obtained by performing fingerprint calculation on the data original text are mapped to the intelligent contract and are associated with the file identification of the file to be stored, so that the file to be stored outside the chain is associated to the intelligent contract, effective management of the off-chain file on the chain is achieved, the data fingerprint can be guaranteed to be incapable of being tampered in the storage process after being stored on the chain, meanwhile, the efficiency of chaining storage is guaranteed, and therefore the management level of the off-chain file is improved.
Example four
Embodiments of the present specification also propose a computer-readable storage medium storing one or more programs, the one or more programs comprising instructions, which when executed by a portable electronic device comprising a plurality of application programs, are capable of causing the portable electronic device to perform the method of the embodiment shown in fig. 1 a-1 c, and in particular for performing the method of:
acquiring a target file to be stored, wherein a data original text of the target file is stored outside a chain;
determining attribute parameters related to management process data in the target file based on file management attributes preset in the intelligent contract, wherein the file management attributes at least comprise: a file data fingerprint;
and uploading the determined attribute parameters and the file identification of the target file to the intelligent contract for associated storage.
Through the technical scheme, the data original text of the file to be stored is stored in the off-chain storage space, meanwhile, the attribute parameters of the data fingerprint obtained by performing fingerprint calculation on the data original text are mapped to the intelligent contract and are associated with the file identification of the file to be stored, so that the file to be stored outside the chain is associated to the intelligent contract, effective management of the off-chain file on the chain is achieved, the data fingerprint can be guaranteed to be incapable of being tampered in the storage process after being stored on the chain, meanwhile, the efficiency of chaining storage is guaranteed, and therefore the management level of the off-chain file is improved.
In short, the above description is only a preferred embodiment of the present disclosure, and is not intended to limit the scope of the present disclosure. Any modification, equivalent replacement, improvement and the like made within the spirit and principle of the present specification shall be included in the protection scope of the present specification.
The system, apparatus, module or unit illustrated in one or more of the above embodiments may be implemented by a computer chip or an entity, or by an article of manufacture with a certain functionality. One typical implementation device is a computer. In particular, the computer may be, for example, a personal computer, a laptop computer, a cellular telephone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.
Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, a computer readable medium does not include a transitory computer readable medium such as a modulated data signal and a carrier wave.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the system embodiment, since it is substantially similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
The foregoing description has been directed to specific embodiments of this disclosure. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.

Claims (12)

1. A method for managing an out-of-chain file based on an intelligent contract comprises the following steps:
acquiring a target file to be stored, wherein a data original text of the target file is stored outside a chain;
determining attribute parameters related to management process data in the target file based on file management attributes preset in the intelligent contract, wherein the file management attributes at least comprise: a file data fingerprint;
and uploading the determined attribute parameters and the file identification of the target file to the intelligent contract for associated storage.
2. The intelligent contract-based off-link file management method of claim 1, wherein the file management attributes further include a file storage address; the method further comprises the following steps:
inquiring a file storage address of a target file from the intelligent contract based on a file identifier of the target file to be inquired;
and acquiring the data original text of the target file from the off-link storage space corresponding to the file storage address.
3. The intelligent contract-based off-link file management method of claim 2, the method further comprising:
inquiring the file data fingerprint of the target file from the intelligent contract based on the file identification of the target file to be inquired;
and comparing the file data fingerprint with the file data fingerprint of the data original text acquired from the storage space outside the chain, if the file data fingerprint is consistent with the file data fingerprint of the data original text acquired from the storage space outside the chain, determining that the data original text stored outside the chain is not modified, otherwise, determining that the data original text stored outside the chain is modified.
4. A method for managing an off-link file based on an intelligent contract as recited in any of claims 1-3, wherein when the target file is changed, the method further comprises:
and updating the changed attribute parameters to the intelligent contract to be stored in association with the file identification of the target file.
5. A method for managing an out-of-chain file based on an intelligent contract according to any one of claims 1-3, when the target file is deleted, the method further comprising:
and deleting the attribute parameters stored in the intelligent contract in association with the file identification of the target file.
6. An apparatus for managing an out-of-chain file based on an intelligent contract, comprising:
the acquisition module is used for acquiring a target file to be stored, wherein the data original text of the target file is stored outside a chain;
the determining module is used for determining attribute parameters related to management process data in the target file based on preset file management attributes in the intelligent contract; wherein the file management attributes include at least: a file data fingerprint;
and the storage module is used for uploading the determined attribute parameters and the file identification of the target file to the intelligent contract for associated storage.
7. The intelligent contract-based off-link file management apparatus of claim 6, the file management attributes further comprising a file storage address; the device further comprises:
the query module is used for querying a file storage address of the target file from the intelligent contract based on the file identification of the target file to be queried; and the number of the first and second groups,
and the data source file is used for acquiring the data source file of the target file from the out-of-link storage space corresponding to the file storage address.
8. An apparatus for managing out-of-chain files based on intelligent contracts according to claim 7, the apparatus further comprising:
the verification module is used for inquiring the file data fingerprint of the target file from the intelligent contract based on the file identification of the target file to be inquired; and
and the data processing module is used for comparing the file data fingerprint with the file data fingerprint of the data original text acquired from the storage space outside the chain, if the file data fingerprint is consistent with the file data fingerprint of the data original text acquired from the storage space outside the chain, determining that the data original text stored outside the chain is not modified, and otherwise, determining that the data original text stored outside the chain is modified.
9. An apparatus for managing out-of-chain files based on intelligent contracts according to any of claims 6 to 8, the apparatus further comprising:
and the updating module is used for updating the changed attribute parameters to the intelligent contract to be stored in association with the file identification of the target file when the target file is changed.
10. An apparatus for managing out-of-chain files based on intelligent contracts according to any of claims 6 to 8, the apparatus further comprising:
and the deleting module is used for deleting the attribute parameters which are stored in the intelligent contract in a way of being associated with the file identification of the target file when the target file is deleted.
11. An electronic device, comprising:
a processor; and
a memory arranged to store computer executable instructions that, when executed, cause the processor to perform:
acquiring a target file to be stored, wherein a data original text of the target file is stored outside a chain;
determining attribute parameters related to management process data in the target file based on file management attributes preset in the intelligent contract, wherein the file management attributes at least comprise: a file data fingerprint;
and uploading the determined attribute parameters and the file identification of the target file to the intelligent contract for associated storage.
12. A computer-readable storage medium storing one or more programs that, when executed by an electronic device including a plurality of application programs, cause the electronic device to perform:
acquiring a target file to be stored, wherein a data original text of the target file is stored outside a chain;
determining attribute parameters related to management process data in the target file based on file management attributes preset in the intelligent contract, wherein the file management attributes at least comprise: a file data fingerprint;
and uploading the determined attribute parameters and the file identification of the target file to the intelligent contract for associated storage.
CN202011457643.0A 2020-12-10 2020-12-10 Method and device for managing off-link files based on intelligent contracts and electronic equipment Pending CN112487497A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011457643.0A CN112487497A (en) 2020-12-10 2020-12-10 Method and device for managing off-link files based on intelligent contracts and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011457643.0A CN112487497A (en) 2020-12-10 2020-12-10 Method and device for managing off-link files based on intelligent contracts and electronic equipment

Publications (1)

Publication Number Publication Date
CN112487497A true CN112487497A (en) 2021-03-12

Family

ID=74916625

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011457643.0A Pending CN112487497A (en) 2020-12-10 2020-12-10 Method and device for managing off-link files based on intelligent contracts and electronic equipment

Country Status (1)

Country Link
CN (1) CN112487497A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113723047A (en) * 2021-07-27 2021-11-30 山东旗帜信息有限公司 Map construction method, device and medium based on legal document

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107944868A (en) * 2017-12-07 2018-04-20 杭州趣链科技有限公司 A kind of electronics deposit system and management method based on block chain intelligence contract
CN109615383A (en) * 2018-10-26 2019-04-12 阿里巴巴集团控股有限公司 Data based on block chain deposit card, acquisition methods and device
CN109918378A (en) * 2019-03-05 2019-06-21 中国科学院深圳先进技术研究院 A kind of remotely-sensed data storage method and storage system based on block chain
CN110851127A (en) * 2019-10-28 2020-02-28 杭州趣链科技有限公司 Universal evidence storage method based on block chain
CN110912937A (en) * 2019-12-23 2020-03-24 杭州中科先进技术研究院有限公司 Block chain-based digital certificate storage platform and certificate storage method
CN111651408A (en) * 2020-06-08 2020-09-11 Oppo广东移动通信有限公司 Method, device, terminal and storage medium for acquiring data

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107944868A (en) * 2017-12-07 2018-04-20 杭州趣链科技有限公司 A kind of electronics deposit system and management method based on block chain intelligence contract
CN109615383A (en) * 2018-10-26 2019-04-12 阿里巴巴集团控股有限公司 Data based on block chain deposit card, acquisition methods and device
CN109918378A (en) * 2019-03-05 2019-06-21 中国科学院深圳先进技术研究院 A kind of remotely-sensed data storage method and storage system based on block chain
CN110851127A (en) * 2019-10-28 2020-02-28 杭州趣链科技有限公司 Universal evidence storage method based on block chain
CN110912937A (en) * 2019-12-23 2020-03-24 杭州中科先进技术研究院有限公司 Block chain-based digital certificate storage platform and certificate storage method
CN111651408A (en) * 2020-06-08 2020-09-11 Oppo广东移动通信有限公司 Method, device, terminal and storage medium for acquiring data

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113723047A (en) * 2021-07-27 2021-11-30 山东旗帜信息有限公司 Map construction method, device and medium based on legal document

Similar Documents

Publication Publication Date Title
US11323260B2 (en) Method and device for identity verification
CN110032880B (en) Screen recording evidence obtaining method and system based on block chain and electronic equipment
CN110020542B (en) Data reading and writing method and device and electronic equipment
JP2019532550A (en) Method and apparatus for data storage, data check, and data connection
CN110032599B (en) Data structure reading and updating method and device, and electronic equipment
CN110020544B (en) Hash information processing method and system for storage record in block of block chain
CN110032598B (en) Method and device for updating field and electronic equipment
CN107402821B (en) Access control method, device and equipment for shared resources
CN112380294B (en) Block chain cross-chain access method and device
CN111415158B (en) Wind control method and system based on block chain
CN111859470A (en) Business data chaining method and device
CN111260469A (en) Block chain-based evidence storing method, block chain-based evidence storing query method, corresponding device and electronic equipment
CN112954073B (en) Service providing method, device, equipment and system
EP3812917A1 (en) Data structure reading method and apparatus, data structure updating method and apparatus, and electronic device
CN112235278A (en) Method and device for monitoring address information of trader and electronic equipment
CN111310137B (en) Block chain associated data evidence storing method and device and electronic equipment
WO2020108152A1 (en) Method, device and electronic equipment for preventing misuse of identity data
CN111651467A (en) Block chain link point interface issuing and calling method and device
WO2021082661A1 (en) Webpage screenshot capturing method, apparatus and device
US9665732B2 (en) Secure Download from internet marketplace
CN111488371A (en) Data query method and device
US11604894B2 (en) Data processing methods, apparatuses, devices, and media
CN112487497A (en) Method and device for managing off-link files based on intelligent contracts and electronic equipment
CN113836331A (en) Image query method, device and storage medium
CN113032820B (en) File storage method, access method, device, equipment and storage medium

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