CN112667855B - Block chain data management method, electronic device and computer storage medium - Google Patents

Block chain data management method, electronic device and computer storage medium Download PDF

Info

Publication number
CN112667855B
CN112667855B CN201910977075.8A CN201910977075A CN112667855B CN 112667855 B CN112667855 B CN 112667855B CN 201910977075 A CN201910977075 A CN 201910977075A CN 112667855 B CN112667855 B CN 112667855B
Authority
CN
China
Prior art keywords
data
rule
check
uplink
inspection
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910977075.8A
Other languages
Chinese (zh)
Other versions
CN112667855A (en
Inventor
李博
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Xintang Sichuang Educational Technology Co Ltd
Original Assignee
Beijing Xintang Sichuang Educational 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 Xintang Sichuang Educational Technology Co Ltd filed Critical Beijing Xintang Sichuang Educational Technology Co Ltd
Priority to CN201910977075.8A priority Critical patent/CN112667855B/en
Publication of CN112667855A publication Critical patent/CN112667855A/en
Application granted granted Critical
Publication of CN112667855B publication Critical patent/CN112667855B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Telephonic Communication Services (AREA)

Abstract

The embodiment of the application provides a block chain data management method, electronic equipment and a computer storage medium, wherein the block chain data management method comprises the following steps: performing first double inspection before chain winding on the data to be chain wound according to the first inspection rule, the second inspection rule and a preset inspection multi-branch tree; after determining that the data to be uplink passes the first double inspection, performing uplink on the data to be uplink; and/or performing second double-check on the data on the chain to be output according to the third check rule, the fourth check rule and the check multi-branch tree; after determining that the on-chain data passes the second double check, the on-chain data is output. Double detection is carried out on the data before data chaining and before data output, and the legality and health of the content of the chained data are guaranteed.

Description

Block chain data management method, electronic device and computer storage medium
Technical Field
The embodiment of the application relates to the technical field of block chains, in particular to a block chain data management method, electronic equipment and a computer storage medium.
Background
The blockchain is a novel application mode of computer technologies such as distributed data storage, point-to-point transmission, a consensus mechanism and an encryption algorithm. After a certain node in the block chain links data, other nodes can also store the data by using a consensus mechanism, so that distributed data storage is realized. However, if the data of the uplink contains content that endangers public safety, the data is difficult to clear due to the characteristic of distributed storage, and the spread range is wider. In the related art, the content security of uplink data on the blockchain is not guaranteed.
Disclosure of Invention
In view of the above, an objective of the present invention is to provide a chain data management method, an electronic device and a computer storage medium, so as to overcome the problem in the prior art that the content security of uplink data in a block chain is not guaranteed.
In a first aspect, an embodiment of the present application provides a method for managing blockchain data, including:
performing first double inspection before chain winding on the data to be chain wound according to the first inspection rule, the second inspection rule and a preset inspection multi-branch tree; after determining that the data to be uplink passes the first double inspection, performing uplink on the data to be uplink; and/or performing second double-check on the data on the chain to be output according to the third check rule, the fourth check rule and the check multi-branch tree; outputting the data on the chain after determining that the data on the chain passes the second double check; and the first double check and the second double check are used for checking the data content of the data to be uplink.
Optionally, in an embodiment of the present application, the performing a first double check before winding on the data to be wound according to the first check rule, the second check rule, and a preset check multi-branch tree includes:
receiving a test result of the application layer for testing the data to be uplink according to the first test rule and a preset test multi-branch tree, and testing the data to be uplink according to the second test rule in the application service layer when the test result indicates that the data to be uplink conforms to the first test rule;
and when the data to be uplink accords with the second check rule, determining that the data to be uplink passes the first double check.
Optionally, in an embodiment of the present application, the first verification rule includes at least one of: illegal keyword alarm rules, keyword silence filter rules and label rules; the checking multi-branch tree includes at least one, each checking multi-branch tree includes a plurality of levels of nodes, and each node includes preset character information.
Optionally, in an embodiment of the present application, when the first check rule includes an illegal keyword alarm rule, receiving a check result obtained by the application layer checking the uplink-to-be-transmitted data according to the first check rule and a preset check multi-way tree, where the check result includes: receiving a comparison result obtained by comparing the character content in the data to be uplink transmitted with a plurality of test multi-branch trees by an application layer according to an illegal keyword alarm rule, if the comparison result indicates that at least one branch of at least one test multi-branch tree is compared, intercepting the data to be uplink transmitted to the application service layer, and generating alarm prompt information;
when the first check rule comprises a keyword silence filter rule, receiving a check result of the application layer for checking the uplink data according to the first check rule and a preset check multi-branch tree, wherein the check result comprises the following steps: receiving a comparison result obtained by comparing the character content in the data to be uplink with a plurality of test multi-branch trees by the application layer according to the keyword silence filtering rule, and if the comparison result indicates that at least one branch of at least one test multi-branch tree is compared, deleting the character content in the comparison in the data to be uplink and transmitting the deleted character content to the application service layer;
when the first check rule includes a label rule, receiving a check result of the application layer checking the data to be uplink according to the first check rule and a preset check multi-branch tree, including: and receiving a comparison result obtained by comparing the character content in the data to be uplink with the plurality of test multi-branch trees according to the label rule by the application layer, and if the comparison result indicates that at least one branch of at least one test multi-branch tree is compared, adding a set label to the character content in the comparison in the data to be uplink and transmitting the label to the application service layer.
Optionally, in an embodiment of the present application, the second verification rule includes at least one of: high-sensitivity Chinese character filtering rules, illegal picture filtering rules and illegal audio filtering rules.
Optionally, in an embodiment of the present application, when the second check rule includes a high-sensitivity chinese character filtering rule, checking, at the application service layer, the to-be-uplink data according to the second check rule includes: performing set symbol filtering processing on data to be linked up in an application service layer to obtain Chinese character content; acquiring set high-sensitivity characters and short sentences related to the set high-sensitivity characters in the Chinese character content; determining the security of the data to be linked according to a comparison result of comparing the obtained short sentence with the short sentences in the preset illegal short sentence library;
when the second check rule includes an illegal picture filtering rule, checking, at the application service layer, the to-be-uplink data according to the second check rule includes: performing OCR recognition on picture data in to-be-linked data in an application service layer to obtain corresponding characters; performing symbol setting and filtering processing on the characters to obtain Chinese character contents; acquiring set high-sensitivity characters and short sentences related to the set high-sensitivity characters in the Chinese character content; determining the security of the data to be linked according to a comparison result of comparing the obtained short sentence with the short sentences in the preset illegal short sentence library;
when the second check rule includes an illegal audio filtering rule, checking the uplink data to be processed according to the second check rule in the application service layer includes: converting audio data in data to be linked into characters in an application service layer; performing symbol setting and filtering processing on the characters to obtain Chinese character contents; acquiring set high-sensitivity characters and short sentences related to the set high-sensitivity characters in the Chinese character content; and determining the security of the data to be linked according to a comparison result of comparing the obtained short sentence with the short sentence in the preset illegal short sentence library.
Optionally, in an embodiment of the present application, the method further includes:
and updating the first check rule, the second check rule, the third check rule and the fourth check rule in real time.
Optionally, in an embodiment of the present application, the third verification rule is the same as the first verification rule and is set in the application layer; or the third check rule is the same as the second check rule, and the third check rule is arranged in the application service layer;
alternatively, the first and second electrodes may be,
the fourth inspection rule is the same as the first inspection rule, and the fourth inspection rule is arranged in the application layer; or the fourth check rule is the same as the second check rule and is set in the application service layer.
In a second aspect, an embodiment of the present application provides an electronic device, including: at least one processor; memory storing at least one program which, when executed by the at least one processor, causes the at least one processor to carry out a blockchain data management method as described in any one embodiment of the first aspect.
In a third aspect, an embodiment of the present application provides a computer storage medium, where a computer program is stored, and when executed by a processor, the computer program implements the block chain data management method described in any one of the embodiments of the first aspect.
In the embodiment of the application, before the data to be uplink-linked is uplink-linked, the data content of the data to be uplink-linked is subjected to the first dual inspection before uplink-linking according to the first inspection rule, the second inspection rule and the preset inspection multi-branch tree, so that the uplink data can meet the first inspection rule and the second inspection rule. When the data on the chain is output, the data content of the data on the chain to be output is subjected to second double-check through the third check rule, the fourth check rule and the check multi-branch tree, so that the safety of the output data on the chain is ensured. On one hand, compared with the prior art that only one check is carried out, the data security is effectively enhanced no matter the double check is carried out on the data before the data chaining or the double check is carried out on the data when the data is output; on the other hand, in the prior art, single check is realized through identity check, which cannot effectively ensure the security of the uploaded data or the output data although the validity of the identity of the person who uploads the data or outputs the data is ensured, and both the first double check and the second double check in the embodiment of the application mainly check the data content of the data, so that the validity and the security of the data to be uplinked and the data to be output are effectively ensured; on the other hand, in the scheme of the embodiment of the application, the preset inspection multi-branch tree is used for inspection, the inspection multi-branch tree corresponds to the inspection rule, so that the corresponding inspection rule is more convenient to realize, and compared with the conventional inspection rule, the inspection speed is higher and the inspection efficiency is higher.
Drawings
Some specific embodiments of the present application will be described in detail hereinafter by way of illustration and not limitation with reference to the accompanying drawings. The same reference numbers in the drawings identify the same or similar elements or components. Those skilled in the art will appreciate that the drawings are not necessarily drawn to scale. In the drawings:
fig. 1 is a flowchart of a block chain data management method according to an embodiment of the present disclosure;
FIG. 2 is a schematic diagram of a method for inspecting a multi-way tree according to an embodiment of the present disclosure;
fig. 3 is a block chain system architecture according to an embodiment of the present disclosure;
fig. 4 is a schematic structural diagram of a block chain data management apparatus according to an embodiment of the present disclosure;
fig. 5 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
The following further describes specific implementation of the embodiments of the present invention with reference to the drawings.
The first embodiment,
Fig. 1 shows a flowchart of a method for managing blockchain data according to an embodiment of the present invention, where fig. 1 is a flowchart of a method for managing blockchain data according to an embodiment of the present invention. The block chain data management method comprises the following steps:
101. and performing first double detection before uplink on the data to be uplink according to the first detection rule, the second detection rule and a preset detection multi-branch tree.
Optionally, in an embodiment of the present application, the performing a first double check before winding on the data to be wound according to the first check rule, the second check rule, and a preset check multi-branch tree includes:
receiving a test result of the application layer for testing the data to be uplink according to the first test rule and a preset test multi-branch tree, and testing the data to be uplink according to the second test rule in the application service layer when the test result indicates that the data to be uplink conforms to the first test rule; and when the data to be uplink accords with the second check rule, determining that the data to be uplink passes the first double check.
In practical application, the application layer can be implemented as a client accessing the block chain, the client is directly facing to a user, the first inspection rule and the inspection multi-branch tree are subjected to the first inspection and then are implemented by the application layer, resources required by calculation and inspection are distributed to the client at the front end, and therefore the burden and the pressure at the rear end of the block chain are reduced. The application service layer can be realized as a node in a block chain, which is in butt joint with the client, and the second inspection is carried out through a second inspection rule and then is delivered to the application service layer, so that the inspection content is more comprehensive, and the security of the data to be uplink is further improved.
The check multi-branch tree is generated according to the first check rule and/or the second check rule, the check multi-branch tree can comprise a plurality of (two or more), and in specific setting, the check multi-branch tree can be generated according to specific contents of the check rules. For example, if the verification rule indicates that certain keywords are to be verified, then a corresponding at least one multi-way tree may be generated from the keywords. The specific generation mode for generating the multi-branch tree according to the keywords can be generated in any appropriate mode, so that the generated multi-branch tree can meet corresponding inspection rules after being subjected to breadth traversal or depth traversal.
Here, the first and second verification rules are described by referring to two application scenarios, which are only exemplary and do not represent that the present application is limited thereto:
optionally, in the first application scenario, the first verification rule includes at least one of: illegal keyword alarm rules, keyword silence filter rules and label rules; the checking multi-branch tree includes at least one, each checking multi-branch tree includes a plurality of levels of nodes, and each node includes preset character information. The method comprises the following steps that 1, an illegal keyword alarm rule is used for indicating that when the data to be linked up is detected to contain illegal keywords, alarm is conducted, and uploading of the data is stopped; 2. the keyword silent filtering rule is used for indicating that illegal keywords in the data to be linked are covered, for example, the illegal keywords are replaced by preset characters, the illegal keywords are deleted, and the like, and/or the keyword silent filtering rule is also used for indicating that data desensitization is carried out on user key information and the user key information is protected; 3. the tag rule is used to indicate that the to-be-linked data is classified and processed by semantic analysis recognition, or by a path of the to-be-linked data, or by keywords (for example, if the to-be-linked data includes "three high", "one model", "result list"), and the related content identified is characterized as a tag and the content is labeled. In the subsequent processing, operations such as data statistical processing and the like can be performed by the tag.
Optionally, in an embodiment of the present application, when the first check rule includes an illegal keyword alarm rule, receiving a check result obtained by the application layer checking the uplink-to-be-transmitted data according to the first check rule and a preset check multi-way tree, where the check result includes: receiving a comparison result obtained by comparing the character content in the data to be uplink transmitted with a plurality of test multi-branch trees by an application layer according to an illegal keyword alarm rule, if the comparison result indicates that at least one branch of at least one test multi-branch tree is compared, intercepting the data to be uplink transmitted to the application service layer, and generating alarm prompt information;
when the first check rule includes a keyword silence filter rule, receiving a check result of the application layer checking the uplink data according to the first check rule and a preset check multi-branch tree, including: receiving a comparison result obtained by comparing the character content in the data to be uplink with a plurality of test multi-branch trees by the application layer according to the keyword silence filtering rule, and if the comparison result indicates that at least one branch of at least one test multi-branch tree is compared, deleting the character content in the comparison in the data to be uplink and transmitting the deleted character content to the application service layer;
when the first check rule includes a label rule, receiving a check result of the application layer checking the data to be uplink according to the first check rule and a preset check multi-branch tree, including: and receiving a comparison result obtained by comparing the character content in the data to be uplink with the plurality of test multi-branch trees according to the label rule by the application layer, and if the comparison result indicates that at least one branch of at least one test multi-branch tree is compared, adding a set label to the character content in the comparison in the data to be uplink and transmitting the label to the application service layer.
Here, a specific example is taken to describe the checking of the multi-branch tree, as shown in fig. 2, fig. 2 is a schematic diagram of the checking of the multi-branch tree provided in the embodiment of the present application, as can be seen from fig. 2, the checking of the multi-branch tree is composed of a plurality of branches and a plurality of nodes included in each branch: examples of the keywords "first name, second item, second spring, and third group of words" include "i feel like a bar" and "the third group of words is problematic". When the fifth character is scanned, the root character of one of the multi-branch trees stored in the database is found to be matched. The content behind the 'first' word in the input content is taken, the word-by-word is taken, and the first-level comparison with the multi-branch tree is carried out, so that the five-word phrase content completely meeting the 'third group' word in the content is found, and the content is considered as the hit keyword.
Optionally, in a second application scenario, the second verification rule comprises at least one of: high-sensitivity Chinese character filtering rules, illegal picture filtering rules and illegal audio filtering rules. The highly sensitive Chinese characters in the second inspection rule may include at least one of words violating law, words violating social justice, words violating public interests, and words not complying with relevant regulations. The words that do not comply with the relevant regulations may include words that do not comply with a certain company system, words that do not comply with a certain association, and the like, which is not limited in the present application.
Optionally, in an embodiment of the second application scenario, when the second check rule includes a high-sensitivity chinese character filtering rule, checking, at the application service layer, the to-be-uplink data according to the second check rule includes: performing set symbol filtering processing on data to be linked up in an application service layer to obtain Chinese character content; acquiring set high-sensitivity characters and short sentences related to the set high-sensitivity characters in the Chinese character content; and determining the security of the data to be linked according to a comparison result of comparing the obtained short sentence with the short sentence in the preset illegal short sentence library. The set symbol filtering process may be performed on other symbols besides the commonly used chinese characters, including messy codes, spaces, numbers, icons, and the like, and it should be noted that the embodiments of the present application take the chinese characters as an example to check, which does not represent that the present application is limited to this, and may also check other forms of language characters, such as english, japanese, Tibetan, and the like. The specific obtaining mode of the short sentence associated with the high-sensitivity word can be set by those skilled in the art according to actual needs, for example, taking the punctuation mark as a separation unit, taking the sentence between the previous punctuation mark and the next punctuation mark of the high-sensitivity word, or taking the complete sentence with the sentence mark as a unit. In addition, the phrases in the illegal phrase library may also be implemented by one or more multi-way trees.
When the second check rule includes an illegal picture filtering rule, checking, at the application service layer, the to-be-uplink data according to the second check rule includes: performing OCR (Optical Character Recognition) Recognition on picture data in the to-be-uplink data at an application service layer to acquire corresponding characters; performing symbol setting and filtering processing on the characters to obtain Chinese character contents; acquiring set high-sensitivity characters and short sentences related to the set high-sensitivity characters in the Chinese character content; and determining the security of the data to be linked according to a comparison result of comparing the obtained short sentence with the short sentence in the preset illegal short sentence library. If the data to be chain-linked comprises a picture and the picture shows characters, character recognition needs to be carried out on the data to be chain-linked, and malicious data are prevented from being chain-linked in the form of the picture. Therefore, the data security when the data to be linked is pictures is ensured. Wherein, the short sentences in the illegal short sentence library can be realized by one or more multi-branch trees.
When the second check rule includes an illegal audio filtering rule, checking the uplink data to be processed according to the second check rule in the application service layer includes: converting audio data in the data to be uplink into characters in an application service layer; performing symbol setting and filtering processing on the characters to obtain Chinese character contents; acquiring set high-sensitivity characters and short sentences related to the set high-sensitivity characters in the Chinese character content; and determining the security of the data to be linked according to a comparison result of comparing the obtained short sentence with the short sentence in the preset illegal short sentence library. If the data to be uplink includes audio data, and the audio data is played back as text, audio data translation needs to be performed on the data to be uplink, so as to prevent malicious data from being uplinked in an audio form. Therefore, the data security when the data to be uplink is audio is ensured. Wherein, the short sentences in the illegal short sentence library can be realized by one or more multi-branch trees.
Therefore, the effective inspection and processing of various different types of data to be uplink are realized, and the data capable of being uplink are all safe data. The method comprises the steps that a content input process part is arranged before uplink, a content output process part is arranged during external output, in content security inspection in the input process, the detection of data to be uplink is carried out on an application layer according to a first detection rule and a preset detection multi-branch tree and is finished by a front end, and the detection of the data to be uplink is carried out on an application service layer according to a second detection rule and is finished by a rear end. The calculation power of the front end is dispersed in the hands of the user, and illegal contents input by the user can be intercepted at the user end, so that the calculation burden of the rear end is reduced, and the network bandwidth for transmitting the illegal contents is avoided.
In order to improve the inspection of the to-be-uplink data according to the second inspection rule, the to-be-uplink data may be preprocessed before the to-be-uplink data is inspected according to the second inspection rule.
For example, in the first example of the present application, before checking the content of the data to be uplink according to the second checking rule, the method further includes: and preprocessing the data to be linked according to a preprocessing rule, wherein the preprocessing rule is used for indicating at least one of messy code compiling, icon removing, word sequencing and word translation.
It should be noted that the scrambling code compiling means that the scrambling code (the scrambling code can represent non-language characters) is converted into characters, and some scrambling codes have a display effect close to that of the characters, for example, a square frame
Figure BDA0002233985350000083
The display effect of the Chinese character is similar to that of the Chinese character, such as a cross symbol
Figure BDA0002233985350000082
The display effect of the Chinese character is similar to that of the Chinese character, and some messy code symbols can express the meaning of the characters, such as gesture symbols
Figure BDA0002233985350000081
The meaning of 'hand' can be expressed, so that the messy codes are converted into characters, and the inspection is more comprehensive; the random code compiling may be performed by using a neural network model, or may be performed according to a compiling rule stored in a database, which is not limited in the present application.
The icon removal refers to removing icons without special meanings in the uplink data, the icons refer to small graphs, and the icons which cannot be compiled can be removed by combining a messy code compiling process.
Word sorting refers to sorting words in the data to be sorted, and checking various sorted words, for example, sorting "ABC" into various combinations of "BAC", "CAB", and the like.
The word translation refers to translating different types of language characters in the data to be uplink into the same type of language characters, for example, the data to be uplink includes three characters, namely english, chinese and japanese, and both the english character and the chinese character are translated into a chinese character, or both the chinese character and the japanese character are translated into an english character, which is not limited in this application.
It should be noted that the preprocessing of the scrambling code compiling, the icon removing, the word sorting and the word translating can be freely combined, and the preprocessing rule can include one or more of the above, which is not limited in the present application. After the preprocessing, the inspection of the data to be uplink is more accurate and comprehensive, and the security of the data to be uplink is further ensured.
102. And after determining that the data to be uplink passes the first double check, performing uplink on the data to be uplink.
If the data to be uplink accords with the second inspection rule, the plurality of nodes carry out uplink on the data to be uplink based on the common identification mechanism, if the data to be uplink does not accord with the second inspection rule, corresponding processing can be carried out according to actual needs, and if the data to be uplink does not accord with the second inspection rule, the uplink is stopped; and alarming, reporting to a management node and the like.
Through the process, the safe uplink of the data to be uplink is realized.
Optionally, when outputting data on the chain, a double check may also be performed to ensure the security of the output data, as follows.
103. And performing second double-check on the data on the chain to be output according to the third check rule, the fourth check rule and the preset check multi-branch tree.
The check multi-branch tree used in this step may be the same as the check multi-branch tree used in the first and second check rules, so as to save implementation cost. But not limited to, different multi-way trees for the third and/or fourth inspection rules may be set to implement different inspections.
Optionally, in an embodiment of the present application, the third check rule is the same as the first check rule and both are set in the application layer; or the third check rule is the same as the second check rule, and the third check rule is set in the application service layer.
In another embodiment of the present application, the fourth verification rule is the same as the first verification rule, and the fourth verification rule is set at the application layer; or the fourth check rule is the same as the second check rule and is set in the application service layer.
Thereby, the implementation cost of the second double check is reduced.
Optionally, in an embodiment of the present application, performing a second double check on the data on the chain to be output according to the third check rule, the fourth check rule and the check multi-way tree, includes: checking the data on the chain to be output according to a third checking rule and the checking multi-branch tree; when the data to be output accords with a third check rule, checking the data on the chain according to a fourth check rule; and when the data to be output accord with the fourth check rule, determining that the data to be output passes the second double check. The checking of the data on the chain according to the fourth checking rule can be realized by combining the multi-branch tree checking.
Optionally, in another embodiment of the present application, the second double check may further comprise additional rules. Here, the additional rule may represent any appropriate rule not included in the third check rule and the fourth check rule, and the additional rule is only needed to be used for checking before output, since the data is checked according to the second and second check rules before uplink; alternatively, the second double check may contain a third or fourth check rule in addition to the additional rule. Of course, this is merely an example and does not represent a limitation of the present application.
In this case, the additional rule may be in addition to the rules according to the third and fourth verification rules. For example, when data is linked up, the second check rule comprises a rule "a", the data is checked according to the rule "a", the fourth check rule adopts the same rule as the second check rule, and the fourth check rule comprises a rule "AB", the data on the link is checked according to the rule "AB", so that the condition that the output data is illegal or unsafe due to rule change is avoided; moreover, the data is checked according to the second checking rule during the data uplink, so that the safety of the data output on the chain is further improved.
104. After determining that the on-chain data passes the second double check, the on-chain data is output.
Through the steps 101-104, the safety of the uplink data is guaranteed, and the safety of the output data is also guaranteed.
Through the embodiment, before the data to be uplink-linked is uplink-linked, the data content of the data to be uplink-linked is subjected to the first double inspection before uplink-linking according to the first inspection rule, the second inspection rule and the preset inspection multi-branch tree, so that the data to be uplink-linked can meet the first inspection rule and the second inspection rule. When the data on the chain is output, the data content of the data on the chain to be output is subjected to second double-check through the third check rule, the fourth check rule and the check multi-branch tree, so that the safety of the output data on the chain is ensured. On one hand, compared with the prior art that only one check is carried out, the data security is effectively enhanced no matter the double check is carried out on the data before the data chaining or the double check is carried out on the data when the data is output; on the other hand, in the prior art, single check is realized through identity check, which cannot effectively ensure the security of the uploaded data or the output data although the validity of the identity of the person who uploads the data or outputs the data is ensured, and both the first double check and the second double check in the embodiment of the application mainly check the data content of the data, so that the validity and the security of the data to be uplinked and the data to be output are effectively ensured; on the other hand, in the scheme of the embodiment of the application, the preset inspection multi-branch tree is used for inspection, the inspection multi-branch tree corresponds to the inspection rule, so that the corresponding inspection rule is more convenient to realize, and compared with the conventional inspection rule, the inspection speed is higher and the inspection efficiency is higher.
Optionally, in an embodiment of the present application, the method for managing blockchain data further includes: and updating the first check rule, the second check rule, the third check rule and the fourth check rule in real time. Optionally, if necessary, the same or different one or more multi-way trees corresponding to the multiple inspection rules may also be updated in real time correspondingly.
It should be noted that, the steps 101-.
With reference to fig. 3, a description is given to a check before data uplink and a check before data output on a link, fig. 3 is a schematic diagram of a block chain system architecture according to an embodiment of the present disclosure, and in fig. 3, the block chain system includes an application layer, an application service layer, a block chain bottom layer, and a management platform.
The application layer is mainly realized on terminal equipment, can realize human-computer interaction through local application software, webpage application software and the like, and can realize functions such as login, data uploading, data downloading, data inquiring and the like. In this embodiment, setting the verification performed according to the first verification rule and the verification performed according to the third verification rule may be performed at the application layer.
The application service layer is an equipment cluster for realizing business calculation, and realizes functions such as data management and the like through a program which runs in the back-end server and is used for carrying out business calculation. In this embodiment, setting the verification according to the second verification rule and the verification according to the fourth verification rule may be performed at the application service layer.
The block chain bottom layer is used for realizing a series of functions such as accounting, on-chain content query and the like, and for the data uplink process, data to be uplink processed is handed to the block chain bottom layer to execute the content uplink after being subjected to the previous two-layer inspection (inspection according to a first inspection rule and inspection according to a second inspection rule), which can be called as a data content security previous inspection process; for the process of chain data output, the chain data is required to be checked according to a fourth check rule and then presented to the terminal device, and before the terminal device is presented to the user, the chain data can be checked according to a third check rule in an application layer, which can be called as a data content safety posterior process.
The actual existing form of the management platform can be a management node host or a distributed host cluster, and the management platform can realize real-time release of data content inspection rules (namely, the second inspection rule and the fourth inspection rule, and the first inspection rule and the third inspection rule) to an application layer and an application service layer; and meanwhile, the system is responsible for collecting alarm information, and presenting alarm items or statistical data in a period of time to an external supervisor for auditing and the like. When the management platform deploys the rules, the rules can be deployed to an application layer and an application service layer in real time. In particular, the verification rule may have multiple versions, each version having a version number. The application layer and the application service layer inquire whether the version of the check rule is changed or not from the management platform before checking the data content, if not, the currently deployed check rule is executed, otherwise, a new check rule is obtained, and then checking is carried out according to the new check rule.
By updating the inspection rule in real time, the method can better adapt to the actual data inspection requirement and provide safer block chain data service.
Example II,
Based on the method for managing blockchain data described in the first embodiment, an embodiment of the present invention provides a device for managing blockchain data, which is used to execute the method for managing blockchain data described in the first embodiment, as shown in fig. 4, the device for managing blockchain data 40 includes: a first security module 401, a cochain module 402, a second security module 403 and an output module 404; the first security module 401 is configured to perform a first double check before uplink on data to be uplink transmitted according to a first check rule, a second check rule, and a preset check multi-branch tree; a chaining module 402, configured to perform a chaining on the to-be-uplink data after determining that the to-be-uplink data passes the first double check; a second security module 403, configured to perform a second duplicate check on the data on the chain to be output according to the third check rule, the fourth check rule, and the check multi-way tree; an output module 404, configured to output the on-chain data after determining that the on-chain data passes the second double check; and the first double check and the second double check are used for checking the data content of the data to be uplinked or the data content of the data to be output on the chain.
Example III,
Based on the method for managing blockchain data described in the first embodiment, an embodiment of the present application provides an electronic device, configured to execute the method for managing blockchain data described in the first embodiment, as shown in fig. 5, where fig. 5 is a schematic structural diagram of an electronic device provided in an embodiment of the present application, and the electronic device 50 includes: at least one processor 501; the memory 502, the memory storing at least one program 512, a bus 503 and a communication interface 504, the at least one processor 501, the memory 502 and the communication interface 504 communicating with each other through the bus 503, when the at least one program is executed by the at least one processor 501, the at least one processor 501 is enabled to implement the block chain data management method as described in the first embodiment.
Example four,
The embodiment of the present application provides a computer storage medium, where a computer program is stored on the computer storage medium, and when the computer program is executed by a processor, the block chain data management method as described in the first embodiment is implemented.
The block chain data management device of the embodiment of the present application exists in various forms, including but not limited to:
(1) a mobile communication device: such devices are characterized by mobile communications capabilities and are primarily targeted at providing voice, data communications. Such terminals include: smart phones (e.g., iphones), multimedia phones, functional phones, and low-end phones, among others.
(2) Ultra-mobile personal computer device: the device belongs to the category of personal computers, has calculation and processing functions, and generally has the characteristic of mobile internet access. Such terminals include: PDA, MID, and UMPC devices, etc., such as ipads.
(3) A portable entertainment device: such devices can display and play multimedia content. This type of device includes: audio, video players (e.g., ipods), handheld game consoles, electronic books, and smart toys and portable car navigation devices.
(4) And other electronic devices with data interaction functions.
So far, specific embodiments of the present application have been described. Other embodiments are within the scope of the following claims. In some cases, the actions recited in the claims can be performed in a different order 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 be advantageous.
In the 90 s of the 20 th century, improvements in a technology could clearly distinguish between improvements in hardware (e.g., improvements in circuit structures such as diodes, transistors, switches, etc.) and improvements in software (improvements in process flow). However, as technology advances, many of today's process flow improvements have been seen as direct improvements in hardware circuit architecture. Designers almost always obtain the corresponding hardware circuit structure by programming an improved method flow into the hardware circuit. Thus, it cannot be said that an improvement in the process flow cannot be realized by hardware physical modules. For example, a Programmable Logic Device (PLD), such as a Field Programmable Gate Array (FPGA), is an integrated circuit whose Logic functions are determined by programming the Device by a user. A digital system is "integrated" on a PLD by the designer's own programming without requiring the chip manufacturer to design and fabricate application-specific integrated circuit chips. Furthermore, nowadays, instead of manually making an Integrated Circuit chip, such Programming is often implemented by "logic compiler" software, which is similar to a software compiler used in program development and writing, but the original code before compiling is also written by a specific Programming Language, which is called Hardware Description Language (HDL), and HDL is not only one but many, such as abel (advanced Boolean Expression Language), ahdl (alternate Hardware Description Language), traffic, pl (core universal Programming Language), HDCal (jhdware Description Language), lang, Lola, HDL, laspam, hardward Description Language (vhr Description Language), vhal (Hardware Description Language), and vhigh-Language, which are currently used in most common. It will also be apparent to those skilled in the art that hardware circuitry that implements the logical method flows can be readily obtained by merely slightly programming the method flows into an integrated circuit using the hardware description languages described above.
The controller may be implemented in any suitable manner, for example, the controller may take the form of, for example, a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro) processor, logic gates, switches, an Application Specific Integrated Circuit (ASIC), a programmable logic controller, and an embedded microcontroller, examples of which include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320, the memory controller may also be implemented as part of the control logic of the memory. Those skilled in the art will also appreciate that, in addition to implementing the controller as pure computer readable program code, the same functionality can be implemented by logically programming method steps such that the controller is in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers, embedded microcontrollers and the like. Such a controller may thus be considered a hardware component, and the means included therein for performing the various functions may also be considered as a structure within the hardware component. Or even means for performing the functions may be regarded as being both a software module for performing the method and a structure within a hardware component.
The systems, devices, modules or units illustrated in the above embodiments may be implemented by a computer chip or an entity, or by a product with certain functions. One typical implementation 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.
For convenience of description, the above devices are described as being divided into various units by function, and are described separately. Of course, the functionality of the various elements may be implemented in the same one or more pieces of software and/or hardware in the practice of the present application.
Furthermore, an embodiment of the present application provides a computer storage medium, where a computer program is stored on the computer storage medium, and when executed by a processor, the computer program implements the block chain data management method as described in the first embodiment.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
Computer-readable media, including both permanent and non-permanent, removable and non-removable media, may implement the 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.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The application may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular transactions or implement particular abstract data types. The application may also be practiced in distributed computing environments where transactions are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
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 above are merely examples of the present application and are not intended to limit the present application. Various modifications and changes may occur to those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.

Claims (9)

1. A method for block chain data management, comprising:
performing first double inspection before chain winding on the data to be chain wound according to the first inspection rule, the second inspection rule and a preset inspection multi-branch tree; after determining that the data to be uplink passes the first duplicate check, uplink the data to be uplink; the first inspection rule is set in an application layer, and the second inspection rule is set in an application service layer; the first inspection rule at least comprises a label rule, the label rule is used for indicating that the data to be uplink is classified through semantic analysis and identification or through a path of the data to be uplink to obtain corresponding content characteristics, and the content characteristics are used as labels to label the content of the data to be uplink;
and the combination of (a) and (b),
performing second double-check on the data on the chain to be output according to the third check rule, the fourth check rule and the check multi-branch tree; outputting the on-chain data after determining that the on-chain data passes the second double check; the third inspection rule is set in an application layer, and the fourth inspection rule is set in an application service layer;
wherein, the first double check and the second double check are both used for checking the data content of the data to be uplinked or the data content of the data to be output;
the first double inspection before chain loading is carried out on the data to be chain loaded according to the first inspection rule, the second inspection rule and the preset inspection multi-branch tree, and comprises the following steps:
receiving a test result of the application layer testing the data to be uplink according to the first test rule and a preset test multi-branch tree, wherein the test result comprises the following steps: receiving a comparison result obtained by comparing the character content in the data to be uplink with the plurality of test multi-branch trees according to the label rule by the application layer, if the comparison result indicates that at least one branch of at least one test multi-branch tree is compared, adding a set label to the character content in the comparison in the data to be uplink and transmitting the label to the application service layer;
when the inspection result indicates that the data to be uplink accords with the first inspection rule, inspecting the data to be uplink according to a second inspection rule in an application service layer;
and when the data to be uplink-transmitted accords with the second checking rule, determining that the data to be uplink-transmitted passes the first double check.
2. The method of claim 1,
the first verification rule further comprises at least one of: illegal keyword alarm rules and keyword silence filter rules;
the check multi-branch tree comprises at least one check multi-branch tree, each check multi-branch tree comprises multiple levels of nodes, and each node comprises preset character information.
3. The method of claim 2,
when the first check rule includes the illegal keyword alarm rule, receiving a check result of an application layer checking the data to be uplink according to the first check rule and a preset check multi-branch tree, including: receiving a comparison result obtained by comparing the character content in the data to be uplink transmitted with a plurality of the inspection multi-branch trees by an application layer according to the illegal keyword alarm rule, and if the comparison result indicates that at least one branch of at least one inspection multi-branch tree is compared, intercepting the transmission of the data to be uplink transmitted to the application service layer and generating alarm prompt information;
when the first check rule includes the keyword silence filter rule, receiving a check result of an application layer checking the data to be uplink according to the first check rule and a preset check multi-branch tree, including: and receiving a comparison result obtained by comparing the character content in the data to be uplink with the plurality of the check multi-branch trees by an application layer according to the keyword silence filtering rule, and if the comparison result indicates that at least one branch of at least one check multi-branch tree is compared, deleting the character content in the comparison in the data to be uplink and then transmitting the deleted character content to the application service layer.
4. The method of claim 1, wherein the second verification rule comprises at least one of: high-sensitivity Chinese character filtering rules, illegal picture filtering rules and illegal audio filtering rules.
5. The method of claim 4,
when the second checking rule comprises the high-sensitivity Chinese character filtering rule, the checking the data to be uplink by the application service layer according to the second checking rule comprises the following steps: performing symbol setting filtering processing on the data to be linked on the application service layer to obtain Chinese character content; acquiring set highly sensitive characters in the Chinese character content and short sentences associated with the set highly sensitive characters; determining the security of the data to be linked according to a comparison result of comparing the obtained short sentence with short sentences in a preset illegal short sentence library;
when the second check rule includes the illegal picture filtering rule, the checking, at the application service layer, the data to be uplink according to the second check rule includes: performing OCR recognition on the picture data in the data to be linked on an application service layer to obtain corresponding characters; performing the set symbol filtering processing on the characters to obtain Chinese character contents; acquiring set highly sensitive characters in the Chinese character content and short sentences associated with the set highly sensitive characters; determining the security of the data to be linked according to a comparison result of comparing the obtained short sentence with short sentences in a preset illegal short sentence library;
when the second check rule includes the illegal audio filtering rule, the checking, at the application service layer, the to-be-uplink data according to the second check rule includes: converting the audio data in the data to be uplink into characters in an application service layer; performing the set symbol filtering processing on the characters to obtain Chinese character contents; acquiring set highly sensitive characters in the Chinese character content and short sentences associated with the set highly sensitive characters; and determining the security of the data to be uplink according to a comparison result of comparing the obtained short sentence with the short sentence in the preset illegal short sentence library.
6. The method of claim 1, further comprising:
and updating the first check rule, the second check rule, the third check rule and the fourth check rule in real time.
7. The method of any of claims 1-6, wherein the third verification rule is the same as the first verification rule; or, the third verification rule is the same as the second verification rule;
alternatively, the first and second electrodes may be,
the fourth verification rule is the same as the first verification rule; alternatively, the fourth verification rule is the same as the second verification rule.
8. An electronic device, comprising:
at least one processor;
memory storing at least one program that, when executed by the at least one processor, causes the at least one processor to implement the blockchain data management method of any one of claims 1-7.
9. A computer storage medium, having a computer program stored thereon, which, when executed by a processor, implements the blockchain data management method of any one of claims 1 to 7.
CN201910977075.8A 2019-10-15 2019-10-15 Block chain data management method, electronic device and computer storage medium Active CN112667855B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910977075.8A CN112667855B (en) 2019-10-15 2019-10-15 Block chain data management method, electronic device and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910977075.8A CN112667855B (en) 2019-10-15 2019-10-15 Block chain data management method, electronic device and computer storage medium

Publications (2)

Publication Number Publication Date
CN112667855A CN112667855A (en) 2021-04-16
CN112667855B true CN112667855B (en) 2022-07-05

Family

ID=75399829

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910977075.8A Active CN112667855B (en) 2019-10-15 2019-10-15 Block chain data management method, electronic device and computer storage medium

Country Status (1)

Country Link
CN (1) CN112667855B (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110278211A (en) * 2019-06-24 2019-09-24 深圳前海微众银行股份有限公司 A kind of data checking method and device based on block chain

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102799596A (en) * 2011-05-27 2012-11-28 广州明朝网络科技有限公司 Key word filtering method and system based on network application
CN107015882B (en) * 2016-12-26 2019-11-22 阿里巴巴集团控股有限公司 A kind of block data method of calibration and device
CN109299094A (en) * 2018-09-18 2019-02-01 深圳壹账通智能科技有限公司 Tables of data processing method, device, computer equipment and storage medium
CN109542856A (en) * 2018-11-26 2019-03-29 上海基诺联生物科技有限公司 A kind of Distributed data share system and method based on block chain
CN109784706A (en) * 2019-01-03 2019-05-21 深圳壹账通智能科技有限公司 Numerical computation method, device, computer equipment and storage medium
CN110119428B (en) * 2019-04-19 2023-05-12 腾讯科技(深圳)有限公司 Block chain information management method, device, equipment and storage medium

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110278211A (en) * 2019-06-24 2019-09-24 深圳前海微众银行股份有限公司 A kind of data checking method and device based on block chain

Also Published As

Publication number Publication date
CN112667855A (en) 2021-04-16

Similar Documents

Publication Publication Date Title
US10572590B2 (en) Cognitive matching of narrative data
US20180365562A1 (en) Prediction of social media postings as trusted news or as types of suspicious news
US20120209852A1 (en) Real-time data mining
US11151180B2 (en) Messaging digest
CN111930623B (en) Test case construction method and device and electronic equipment
TWI706271B (en) Method, system, device and equipment for depositing works based on blockchain
US11182605B2 (en) Search device, search method, search program, and recording medium
Pelicon et al. Investigating cross-lingual training for offensive language detection
CN112380401B (en) Service data checking method and device
US20200387534A1 (en) Media selection based on content topic & sentiment
US9558462B2 (en) Identifying and amalgamating conditional actions in business processes
Fischbach et al. Cira: A tool for the automatic detection of causal relationships in requirements artifacts
Rahman et al. Permpress: Machine learning-based pipeline to evaluate permissions in app privacy policies
US9442918B2 (en) Perspective data management for common features of multiple items
CN108268602A (en) Analyze method, apparatus, equipment and the computer storage media of text topic point
Jain et al. Prigen: Towards automated translation of android applications’ code to privacy captions
CN108268443A (en) It determines the transfer of topic point and obtains the method, apparatus for replying text
CN112667855B (en) Block chain data management method, electronic device and computer storage medium
Raj et al. Fake News Detection
Vyas et al. Detection of Malicious Bots on Twitter through BERT Embeddings-based Technique
US11017172B2 (en) Proposition identification in natural language and usage thereof for search and retrieval
CN113723095A (en) Text auditing method and device, electronic equipment and computer readable medium
Hathnapitiya et al. Early detection of sinhala fake news in social media
CN111898762A (en) Deep learning model catalog creation
US10776587B2 (en) Claim generation

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant