Blockchain-based business processing method and system

By using a multi-level blockchain-based architecture to automatically process device parameters of IoT devices, the problem of high regulatory difficulty in internet data settlement platforms is solved, thereby improving data security and credibility.

CN116091072BActive Publication Date: 2026-03-31HANGZHOU QULIAN TECHNOLOGY CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-01-10
Publication Date
2026-03-31

AI Technical Summary

Technical Problem

The rapid updates of information on the Internet have increased the difficulty of supervising data settlement platforms and reduced the credibility of data.

Method used

By adopting a multi-layered blockchain architecture, the system enables IoT devices to report their parameters layer by layer, automate business data settlement, and determine business behaviors to generate transaction data through the collaborative work of the data chain, data processing terminal, business terminal, and public chain. This also isolates the data from the data chain and business terminal, thereby improving data security.

Benefits of technology

It reduces the difficulty of supervising data settlement, improves data security and credibility, and enables automated settlement of business data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116091072B_ABST
    Figure CN116091072B_ABST
Patent Text Reader

Abstract

The embodiment of the application discloses a kind of business processing method and system based on blockchain, it is related to blockchain technical field, data processing end is based on the service block data of data chain sending to determine whether user terminal generates service behavior, if service behavior is generated, transaction is created to service block data, generates transaction data and sends transaction data to service end, service end is based on received transaction data to carry out service settlement, generates service transaction data, and sends service transaction data to public chain;Public chain is based on received service transaction data, calls equity contract and changes the equity data of each user terminal in public chain according to service transaction data;The application is based on the multilevel blockchain architecture, and the device parameters of internet-of-things equipment are reported layer by layer, the automatic settlement of service data is realized, the supervision difficulty of data settlement is reduced, and the isolation of device parameters in data chain and service data in service end can be realized, to improve data security.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of blockchain technology, and more specifically to a blockchain-based business processing method and system. Background Technology

[0002] With the development of internet and terminal technologies, more and more online platforms are entering people's lives. To attract users and increase traffic, such as boosting sales, these platforms may employ various online promotional methods or offer incentive programs, such as price reductions, cash back, or points rewards. However, the rapid and convenient updating of information online reduces the reliability of data and increases the difficulty of regulating data settlement platforms. Summary of the Invention

[0003] This invention provides a blockchain-based business processing method and system to reduce the difficulty of existing data settlement.

[0004] On one hand, embodiments of the present invention provide a blockchain-based business processing method, which is applied to a blockchain-based business processing system. The blockchain-based business processing system includes at least one data chain, at least one data processing terminal, at least one business terminal, and a public chain. Each data chain corresponds to one data processing terminal, and each data processing terminal corresponds to one business terminal. Equity contracts are deployed on the public chain, and each business terminal connects to the public chain. The method includes:

[0005] The data nodes on the data chain send business block data to the data processing terminal; the business block data includes the device parameters of the IoT devices used by the user terminal corresponding to the data node within a preset time period;

[0006] The data processing terminal determines whether the user terminal generates a business activity based on the device parameters of the IoT device used by the user terminal within a preset time period in the received business block data. If a business activity is generated, a transaction is created in the business block data, transaction data is generated, and the transaction data is sent to the business terminal.

[0007] The business terminal performs business settlement based on the received transaction data to obtain the business data of the user terminal. Based on the business data of the user terminal, it modifies the total business data of the user terminal in the business terminal. At preset intervals, it generates business transaction data based on the modified total business data of all user terminals in the business terminal and sends the business transaction data to the public chain.

[0008] The public chain, upon receiving business transaction data, invokes the rights contract to modify the rights data of each user terminal within the public chain according to the business transaction data.

[0009] On the other hand, embodiments of the present invention provide a blockchain-based business processing method, which is applied to a blockchain-based business processing system. The blockchain-based business processing system includes at least one data chain, at least one data processing terminal, at least one business terminal, and a public chain. Each data chain corresponds to one data processing terminal, and each data processing terminal corresponds to one business terminal. Equity contracts are deployed on the public chain, and each business terminal connects to the public chain. The method is executed by the data processing terminal and includes:

[0010] Obtain service block data sent by data nodes on the data chain, wherein the service block data includes the device parameters of the IoT devices used by the user terminal corresponding to the data node within a preset time period;

[0011] Based on the device parameters of the IoT device used by the user terminal, determine whether the user terminal generates business behavior;

[0012] If a business activity occurs, a transaction is created on the business block data, transaction data is generated, and the transaction data is sent to the corresponding business terminal so that the business terminal can perform business settlement based on the transaction data and obtain the business data of the user terminal.

[0013] On the other hand, embodiments of the present invention provide a blockchain-based business processing method, which is applied to a blockchain-based business processing system. The blockchain-based business processing system includes at least one data chain, at least one data processing terminal, at least one business terminal, and a public chain. Each data chain corresponds to one data processing terminal, and each data processing terminal corresponds to one business terminal. Equity contracts are deployed on the public chain, and each business terminal connects to the public chain. The method is executed by the business terminal, which has business contracts deployed on it. The method includes:

[0014] Receive transaction data from the user terminal sent by the data processing terminal;

[0015] The business contract is invoked to perform business settlement on the transaction data to obtain the business data of the user terminal, and the total business data of the user terminal in the business terminal is changed based on the business data of the user terminal.

[0016] At preset intervals, business transaction data is generated based on the total business data modified by all user terminals in the business terminal, and the business transaction data is sent to the public chain.

[0017] On the other hand, embodiments of the present invention provide a blockchain-based business processing system, the system including at least one data chain, at least one data processing terminal, at least one business terminal and a public chain, each data chain corresponding to a data processing terminal, each data processing terminal corresponding to a business terminal, and equity contracts deployed on the public chain, with each business terminal connected to the public chain;

[0018] The data chain is used to collect device parameters of IoT devices used by user terminals within a preset time period, generate service block data based on the device parameters, and send the service block data to the corresponding data processing terminal.

[0019] The data processing terminal is used to obtain business block data sent by the data nodes on the corresponding data chain, and determine whether the user terminal generates business behavior based on the device parameters of the IoT device used by the user terminal within a preset time period in the business block data. If business behavior is generated, a transaction is created in the business block data, transaction data is generated, and the transaction data is sent to the corresponding business terminal.

[0020] The business terminal is used to receive the transaction data sent by the corresponding data processing terminal, perform business settlement on the transaction data to obtain the business data of the user terminal, change the total business data of the user terminal in the business terminal according to the business data of the user terminal, generate business transaction data according to the changed total business data of all user terminals in the business terminal at preset intervals, and send the business transaction data to the public chain.

[0021] The public chain receives the business transaction data sent by the business terminal, and calls the equity contract to change the equity data of each user terminal in the public chain according to the business transaction data.

[0022] This invention provides a blockchain-based business processing method and system, relating to the field of blockchain technology. Data nodes on the data chain send business block data to a data processing terminal. The business block data includes device parameters of the IoT devices used by the user terminal corresponding to the data node within a preset time period. The data processing terminal determines whether the user terminal has generated a business activity based on the device parameters of the IoT devices used by the user terminal within the preset time period in the received business block data. If a business activity has occurred, a transaction is created in the business block data, generating transaction data which is then sent to the business terminal. The business terminal performs business settlement based on the received transaction data, obtaining the user terminal's business data, and modifies the user terminal's settings in the business terminal based on the user terminal's business data. The system generates business transaction data based on the total business data of all user terminals modified in the business terminal at preset intervals, and sends the business transaction data to the public chain. Upon receiving the business transaction data, the public chain invokes the equity contract to modify the equity data of each user terminal in the public chain according to the business transaction data. This invention is based on a multi-level blockchain architecture, reporting the device parameters of IoT devices layer by layer to achieve automatic settlement of business data and reduce the difficulty of supervising data settlement. Furthermore, the data processing terminal analyzes business behavior based on device parameters, creating transaction data only when the user terminal performs the aforementioned business behavior, and settling business data based on the transaction data. This achieves isolation between device parameters in the data chain and business data in the business terminal, improving data security. Attached Figure Description

[0023] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0024] Figure 1 This is a schematic diagram of the structure of a blockchain-based business processing system provided in an embodiment of the present invention;

[0025] Figure 2 This is a schematic diagram illustrating the process of business processing by the blockchain-based business processing system provided in this embodiment of the invention.

[0026] Figure 3 This is another schematic diagram of the blockchain-based business processing system provided in this embodiment of the invention;

[0027] Figure 4 This is a flowchart illustrating the blockchain-based business processing method provided in an embodiment of the present invention;

[0028] Figure 5This is a schematic flowchart of a blockchain-based business processing method applicable to the data processing end provided in an embodiment of the present invention;

[0029] Figure 6 This is a schematic diagram of the structure of a blockchain-based business processing device located at the data processing end, as provided in an embodiment of the present invention.

[0030] Figure 7 This is a flowchart illustrating a blockchain-based business processing method applicable to the business side, provided by an embodiment of the present invention.

[0031] Figure 8 This is a schematic diagram of the structure of a blockchain-based business processing device located at the business end, as provided in an embodiment of the present invention.

[0032] Figure 9 This is a schematic diagram of the structure of a blockchain-based business processing device provided in an embodiment of the present invention. Detailed Implementation

[0033] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0034] like Figure 1 As shown, Figure 1 This is a schematic diagram of the structure of a blockchain-based business processing system provided in an embodiment of the present invention. The blockchain-based business processing system includes a data chain 100, a data processing terminal 200, a business terminal 300, and a public chain 400. Figure 1 As shown, each data chain 100 corresponds to a data processing terminal 200, each data processing terminal 200 corresponds to a business terminal 300, and equity contracts are deployed on the public chain 400. Each business terminal 300 is connected to the public chain 400.

[0035] Specifically, Data Chain 100 stores the device parameters of IoT devices used by user terminals in a blockchain manner. Based on the received device parameters, it generates business block data and sends the business block data to Data Processing Terminal 200 via a message middleware. Depending on the actual application scenario of Data Chain 100, the device parameters of IoT devices also differ. For example, in vehicle scenarios (such as vehicle driving scenarios, vehicle transportation scenarios, etc.), the device parameters can be the driving distance and the weight of the transported goods. In device replacement scenarios (such as battery replacement scenarios, chip replacement scenarios, etc.), the device parameters can be device coding information within the IoT device, such as battery coding and chip coding.

[0036] Optionally, multiple data nodes on the data chain 100 each receive device parameters of the IoT devices used by the user terminal within a preset time period, create a data block based on the received device parameters, perform hash calculations based on the received device parameters to obtain the transaction hash of the device parameters, and store the transaction hash and device parameters in the created data block. Understandably, each user terminal has a unique terminal identifier on the data chain 100. Optionally, the preset time period can be one day, three days, or one week, etc., and this embodiment of the invention does not specifically limit this. Optionally, the data node can be a mobile terminal, such as a mobile phone, tablet computer, personal computer, etc.; optionally, the data node can also be a service terminal, such as a server, server cluster, cloud server, etc. It should be noted that this embodiment of the invention does not limit the specific form of the data node.

[0037] Optionally, for each data block generated on data chain 100, the business block data within that data block is sent to data processing terminal 200 via message middleware. Optionally, at preset intervals, data chain 100 sends the business block data from data blocks generated within that period to data processing terminal 200 via message middleware. The message middleware includes, but is not limited to, ActiveMQ, RabbitMQ, RocketMQ, Kafka, and ZeroMQ; the preset interval can be 1 day, 3 days, or 1 week.

[0038] Data processing terminal 200 is a terminal device with data processing capabilities, including but not limited to servers, cloud servers, and computers. The data processing terminal subscribes to business block data on data chain 100 through message middleware. It determines whether the user terminal has generated business behavior based on the device parameters of the IoT devices used by the user terminal within a preset time period in the business block data. If business behavior is generated, it creates a transaction in the business block data, generates transaction data, and sends the transaction data to business terminal 300.

[0039] Optionally, depending on the actual application scenario of Data Link 100, the business behavior of the user terminal will also be different. For example, in the scenario of device replacement, the business behavior can be battery replacement or chip replacement.

[0040] Optionally, the data processing terminal 200 can be deployed on the data chain 100. For example, a master node can be selected from the data nodes on the data chain 100 and set as the data processing terminal 200. The master node can be selected from the data nodes on the data chain 100 through a voting mechanism; this embodiment of the invention does not specifically limit the method used. Optionally, the data processing terminal 200 can be deployed outside the data chain 100.

[0041] Optionally, the transaction data includes, but is not limited to, business behavior data and transaction proofs. The business behavior data includes, but is not limited to, business behaviors and the number of times the business behaviors are performed. The business behaviors are obtained by the data processing terminal 200 based on device parameters. The transaction proofs are used to prove the validity of the business behaviors. The transaction proofs include the transaction hash of the device parameters on which the business behaviors are based on on the data chain 100.

[0042] The business terminal 300 performs business settlement based on the transaction data sent by the data processing terminal 200, obtains business data, and stores the transaction data and business data in a blockchain. It also updates the total business data of user terminals based on their business data and generates business transaction data based on the total business data of all user terminals stored in the business terminal 300 at preset intervals, sending the business transaction data to the public blockchain 400. Each user terminal has a unique terminal identifier on the business terminal 300. The preset interval can be 1 day, 3 days, or 1 week; this embodiment of the invention does not specifically limit this.

[0043] Among them, business terminal 300 can be a terminal device deployed with a blockchain network, or business terminal 300 can be a blockchain network terminal.

[0044] Optionally, business data can be digital assets, such as points, data traffic, tickets, etc.; optional business data can also be financial assets. Optionally, business settlement can be a process of determining the business data corresponding to the transaction data through a preset function deployed in the business terminal 300. The preset function can be one or more of linear functions, exponential functions, power functions, and quadratic functions.

[0045] Optionally, business settlement is the process of determining the business data corresponding to a business behavior based on the business behavior data in the received transaction data.

[0046] In some implementations, the service terminal 300 deploys a preset mapping relationship. By mapping the service behavior in the service behavior data to the service behavior itself, the unit service parameter corresponding to the service behavior is obtained. Based on the unit service parameter and the number of times the service behavior occurs, the service data is obtained. The preset mapping relationship is used to map the service behavior to its corresponding unit service parameter. Optionally, the preset mapping relationship can be mapping relationship data, including at least one service behavior and the unit service parameter corresponding to each service behavior; alternatively, the preset mapping relationship can be a function, such as a linear function, exponential function, or power function. The unit service parameter represents the service data obtainable by the user terminal for each service behavior. For example, taking battery replacement as an example, if transaction data indicates that the user terminal performed two battery replacements within a preset time period, and the unit service parameter corresponding to the battery replacement is determined to be 40 based on the preset mapping relationship, then the user terminal's service data is 80.

[0047] In other implementations, the business terminal 300 is equipped with a business contract. The business contract is invoked to perform business settlement based on the business behavior and the number of times the business behavior corresponds to the transaction data, thereby obtaining the business data.

[0048] Optionally, the business transaction data includes the total business data of each user terminal in business terminal 300 and the total business data of business terminal 300. The total business data is the sum of the total business data of each user terminal.

[0049] Public chain 400 is used to provide rights issuance and rights redemption. Rights issuance refers to changing the rights data of each user terminal in public chain 400 based on the business transaction data sent by business terminal 300. It can be understood that each user terminal has a unique terminal identifier on public chain 400, and for each user terminal, its terminal identifier on data chain 100, terminal identifier on business terminal 300, and terminal identifier on public chain 400 can be the same. Therefore, based on the user terminal's terminal identifier, the rights data corresponding to that user terminal can be queried on public chain 400, the business data corresponding to the user terminal can be queried on business terminal 300, and the device parameters corresponding to the user terminal can be queried on data chain 100.

[0050] Optionally, the equity contract is used to process transactions related to equity change events, and the processing results are stored on the public blockchain 400. The processing results refer to the equity data after the change on the user's terminal.

[0051] For example, let's take a battery replacement scenario as an example for illustration. Figure 2 As shown, Figure 2 This is a schematic diagram illustrating the business processing process of the blockchain-based business processing system provided in this embodiment of the invention. Figure 2 In the application scenario shown, business contracts are pre-deployed on business terminal 300, and equity contracts are deployed on public chain 400. Each battery swapping station corresponds to a data chain 100 and a business terminal 300, and each vehicle is equipped with a user terminal.

[0052] Specifically, the target user terminal collects the battery number of the vehicle at each moment within a preset time period and sends the collected battery number of the vehicle at each moment to the data chain 100; the data chain 100 generates a data block based on the received battery number of the vehicle at each moment and sends the business block data in the generated data block to the data processing terminal 200; the data processing terminal 200 determines whether the vehicle where the target user terminal is located has performed a battery replacement service based on the device parameters in the received business block data. If a battery replacement service has been performed, transaction data is constructed based on the number of battery replacements and the transaction hash of the business block data on the data chain 100, and the transaction data is sent to the business terminal 30. 0; Business terminal 300 calls the business contract to perform business settlement on the transaction data, obtains the business data of the target user terminal, and changes the total business data of the target user terminal in business terminal 300 according to the business data of the target user terminal; when the preset period is reached, business terminal 300 generates business transaction data based on the total business data and total business data of each user terminal on business terminal 300 at the current time, and sends the business transaction data to public chain 400; public chain 400 calls the equity contract, changes the equity data of each user terminal in public chain 400 according to the total business data of each user terminal in the business transaction data, and saves the changed equity data of each user terminal to public chain 400.

[0053] The blockchain-based business processing system provided in this embodiment of the invention, based on a multi-level blockchain architecture, reports the device parameters of IoT devices layer by layer, realizing automatic settlement of business data and reducing the difficulty of supervising data settlement; and through the data processing terminal 200, business behavior analysis is performed based on device parameters, and transaction data is created only when the user terminal performs the above-mentioned business behavior, and business data settlement is performed based on the transaction data. This can achieve isolation between device parameters in the data chain 100 and business data in the business terminal 300, thereby improving data security.

[0054] In some optional implementations, for each data chain 100, when a data block is generated on the data chain 100, the business block data in the data block is sent to the data processing terminal 200 corresponding to the data chain 100.

[0055] In some optional implementations, for each data chain 100, the data chain 100 sends the business block data from the data blocks generated within a preset time period to the data processing terminal 200 corresponding to the data chain 100. For example, the data processing terminal 200 corresponding to each data chain 100 subscribes to the business block data on the data chain 100 using middleware. The preset time period can be 1 hour, 1 day, 3 days, or 1 week.

[0056] Optionally, to ensure data transmission security, the data chain 100 can encrypt the business block data when sending it to the data processing terminal 200. Specifically, for each data chain 100, when a data node receives device parameters of an IoT device uploaded by a user terminal, it creates an initial block, creates business block data based on the device parameters and the user terminal's terminal identifier, writes the business block data into the initial block to obtain a data block, encrypts the business block data in the data block to obtain block information, and sends the block information to the data processing terminal 200 corresponding to that data chain 100. When the data processing terminal 200 receives the block information sent by the data chain 100, it decrypts the block information to obtain the business block data within the block information.

[0057] The business block data of the data block can be encrypted using either symmetric encryption or asymmetric encryption.

[0058] Optionally, to ensure data security, for each data chain 100, when a data node on the data chain 100 receives device parameters of an IoT device uploaded by a user terminal, it creates an initial block, creates data transaction information according to the device parameters and the user terminal's terminal identifier in a preset transaction format, and writes the data transaction information into the initial block to obtain a data block. The data chain 100 encrypts the data transaction information in the generated data block to obtain block information, and sends the block information to the data processing terminal 200 corresponding to the data chain 100. The data processing terminal 200 decrypts the block information and deserializes the decrypted block information according to a preset transaction format to obtain the device parameters.

[0059] Optionally, in some implementations, each data chain 100 corresponds to one application scenario. The application scenarios corresponding to each data chain 100 can be the same, or they can be different. For example, taking data chains A1 and A2 in a blockchain-based business processing system as examples, the application scenarios of data chain A1 and A2 can be the same, such as both being used in a battery replacement scenario. Alternatively, the application scenarios of data chains A1 and A2 can be different, such as A1 being used in a battery replacement scenario and A2 being used in a chip replacement scenario.

[0060] Optionally, in some implementations, to easily and conveniently determine whether a user terminal has generated business activity, the determination can be made by checking whether the device parameters change within a preset time period.

[0061] For example, taking battery replacement as an actual application scenario of data chain 100, data processing terminal 200 can determine whether the user terminal has performed a battery replacement service within a preset time period based on whether the device parameters have changed within that preset time period. When receiving service block data, data processing terminal 200 compares the device parameters of the IoT device used by the user terminal within the preset time period in the service block data; if the device parameters of the IoT device used by the user terminal have changed within the preset time period, it is determined that the user terminal has performed a service activity.

[0062] Optionally, in some implementations, the service block data also includes time information for each device parameter, where the time information refers to the time when the user terminal collects the device parameters. To facilitate determining whether the device parameters have changed within a preset time period, the device parameters corresponding to each time information within the preset time period can be compared to determine whether the device parameters have changed within the preset time period. Specifically, the method for determining whether the device parameters have changed includes steps a1 to a4:

[0063] Step a1: Sort the parameters of each device according to the time information of each device parameter to obtain the parameter sequence.

[0064] Step a2: For each device parameter in the parameter sequence, compare the device parameter with the preceding device parameter adjacent to it to obtain the comparison result of the device parameter.

[0065] Step a3: If the comparison results of each device parameter in the parameter sequence indicate that the parameters are consistent, then it is determined that the device parameters of the IoT device used by the user terminal have not changed within the preset time period.

[0066] Step a4: If there are target device parameters in the parameter sequence that indicate inconsistent comparison results, then it is determined that the device parameters of the IoT device used by the user terminal have changed within the preset time period.

[0067] Optionally, in some implementations, the device parameters in the service block data can be compared with the pre-stored benchmark parameters; if the device parameters are consistent with the benchmark parameters, it is determined that the device parameters of the IoT device used by the user terminal have not changed within the preset time period; if the device parameters are inconsistent with the benchmark parameters, it is determined that the device parameters of the IoT device used by the user terminal have changed within the preset time period, and the device parameters are set to the new benchmark parameters.

[0068] Optionally, if the device parameters of the IoT device used by the user terminal change within a preset time period, it is determined that the user terminal has generated a business activity; if the device parameters of the IoT device used by the user terminal do not change within the preset time period, it is determined that the user terminal has not generated a business activity.

[0069] Optionally, if the device parameters of the IoT device used by the user terminal change within a preset time period, the number of times the device parameters change is set as the number of business actions. For example, taking the parameter sequence {A001, A001, A002, A002, A005} as an example, if the device parameters of the IoT device used by the user terminal change within the preset time period, and the device parameters change twice within the preset time period, then the user terminal performs two business actions within the preset time period.

[0070] In some optional implementations, considering that the user terminal periodically collects device parameters of IoT devices, i.e., there are time intervals between the collected device parameters, the existence of this time interval may lead to incomplete device parameter collection. That is, the device parameters collected within a preset time period have not changed, and the historical device parameters collected in the previous preset time period have not changed either, but a battery replacement occurred between the preset time period and the previous preset time period. Although the time interval can be shortened to improve the completeness of device parameters, shortening the time interval will increase the amount of data collected and increase the data processing load of the data processing terminal. Based on this, in order to improve the accuracy of business behavior analysis, this embodiment of the invention obtains historical device parameters when the device parameters of the IoT devices used by the user terminal have not changed within a preset time period, compares the device parameters with the historical device parameters, and determines whether the user terminal has generated business behavior based on the comparison result. Specifically, the business behavior analysis method based on device parameters includes steps b1 to b2:

[0071] Step b1: If the device parameters of the IoT device used by the user terminal do not change within the preset time period, then obtain the historical business block data that matches the business block data of the user terminal, and determine whether the historical device parameters in the historical business block data are consistent with the device parameters. If the historical device parameters in the historical business block data are inconsistent with the device parameters, then determine that the user terminal has generated a business behavior.

[0072] Optionally, in some implementations, historical business block data can be obtained from the historical data block corresponding to the data block on data chain 100, based on the data block of the business block data on data chain 100. The historical data block is the preceding data block of the data block. Specifically, the method for obtaining historical business block data includes:

[0073] (1) Obtain the block height or block time of the data block where the business block data is located in the data chain.

[0074] (2) Identify the historical data blocks in the data chain that have the same business type as the business block data, and have the smallest height difference between the historical block heights and the block heights, or the smallest time difference between the historical block times and the block times.

[0075] (3) Set the historical business block data in the historical data block to the historical business block data that matches the business block data of the user terminal.

[0076] Since each data block on data chain 100 corresponds to a block of data and a block height, candidate historical data blocks with the same business type as the business block data can be selected from data chain 100 based on the block height or block time of the data block containing the business block data. From these candidate historical data blocks, the historical data block with the closest block height or block time to the data block containing the business block data can be selected, and the historical business block data within that historical data block can be obtained. Here, block time refers to the time when the data block containing the business block data was generated on data chain 100, and block height refers to the height information of the data block on data chain 100. The business type can be the terminal identifier of the user terminal in the business block data, or it can be the device type of the IoT device used by the user terminal in the business block data.

[0077] Optionally, based on the block height or block time of the data block where the business block data is located in the data chain 100, the data blocks on the data chain 100 can be traversed to select the historical data blocks in the data chain 100 with the smallest height difference between historical block heights or the smallest time difference between historical block times.

[0078] Optionally, if the historical device parameters in the historical service block data are consistent with the device parameters, it is determined that the user terminal did not generate any service behavior. For example, taking the battery number as the device parameter, the battery number can be compared with the historical battery number in the historical service block data. If the battery number is consistent with the historical battery number, it is determined that the user terminal did not generate any battery replacement service behavior; if the battery number is inconsistent with the historical battery number, it is determined that the user terminal generated any battery replacement service behavior.

[0079] Step b2: If the device parameters of the IoT device used by the user terminal change within a preset time period, it is determined that the user terminal has generated a business behavior.

[0080] Optionally, when collecting device parameters of IoT devices at the user terminal, operation data of the user terminal within a preset time period can also be collected. The device parameters and operation data are then sent to data link 100, which writes the operation data and device parameters into a data block. That is, the business block data sent by data link 100 to data processing terminal 200 also includes operation data. To improve the reliability of business behavior analysis, it can be determined whether the user terminal has generated business behavior based on the operation data and device parameters. The operation data records the behavior of the IoT devices used by the user terminal within the preset time period, including but not limited to charging behavior and battery replacement behavior.

[0081] Optionally, in step b2, if the device parameters of the IoT device used by the user terminal change within a preset time period, data analysis is performed on the operation data to determine whether battery replacement behavior exists among the actions of the IoT device used by the user terminal. If battery replacement behavior exists, it is determined that the user terminal has generated a service action; otherwise, it is determined that the user terminal has not generated a service action. For example, when a vehicle has a backup battery, and the backup battery is used for power supply, the device parameters collected by the user terminal change, but the vehicle does not generate a battery replacement service action. It is understood that battery replacement refers to replacing the battery in the vehicle with the battery in the battery swapping station.

[0082] Optionally, it can be determined whether there is a battery replacement behavior in the behavior of the IoT device used by the user terminal by detecting whether there is a pre-stored target field in the operation data. When there is a pre-stored target field in the operation data, it is determined that there is a battery replacement behavior in the behavior of the IoT device used by the user terminal. When there is no pre-stored target field in the operation data, it is determined that there is no battery replacement behavior in the behavior of the IoT device used by the user terminal.

[0083] In some optional implementations, the operation data is used to record the operation behaviors and operating parameters of the user terminal. Whether the user terminal has generated business behavior can be determined based on the operation data and device parameters in the business block data. Specifically, the business behavior analysis method based on operation data and device parameters includes steps c1 to c4:

[0084] Step c1: Based on the device parameters of the IoT devices used by the user terminal within the preset time period, determine whether the device parameters of the IoT devices used by the user terminal have changed within the preset time period.

[0085] Optionally, steps a1 to a4 can be used to determine whether the device parameters of the IoT device used by the user terminal have changed within a preset time period.

[0086] Step c2 involves parsing the operation data to determine if behavioral parameters exist. These behavioral parameters characterize the user terminal's actions within a preset time period, including actions such as battery replacement, battery charging, and battery fault reporting.

[0087] Step c3: If the device parameters of the IoT device used by the user terminal change within a preset time period, and there are behavioral parameters in the operation data, then it is determined that the user terminal has generated a business behavior.

[0088] Optionally, if the device parameters of the IoT device used by the user terminal change within a preset time period, and there are behavioral parameters in the operation data, that is, the user terminal generates an operation behavior, then it is determined that the user terminal generates a business behavior.

[0089] Optionally, if the device parameters of the IoT device used by the user terminal change within a preset time period, and the operation data contains behavioral parameters, indicating that the user terminal has generated an operation, then the behavior type of the operation is determined. If the behavior type of the operation is a target behavior type, then the user terminal has generated a business behavior. The target behavior type can be a battery swapping behavior.

[0090] Step c4: If the device parameters of the IoT device used by the user terminal do not change within the preset time period, and / or there are no behavioral parameters in the operation data, then it is determined that the user terminal has not generated any business behavior.

[0091] Optionally, if the device parameters of the IoT device used by the user terminal do not change within a preset time period, and behavioral parameters exist in the operation data, it is determined that the user terminal has not generated any business behavior. For example, if a vehicle replaces its battery and then installs the replaced battery back into the vehicle, although the vehicle has performed a battery swap, it has not actually swapped with the battery at the battery swapping station. Therefore, it is determined that the user terminal has not generated any business behavior.

[0092] Optionally, if the device parameters of the IoT device used by the user terminal change within a preset time period and no behavioral parameters are found in the operation data, it is determined that the user terminal has not generated any business behavior. For example, if the vehicle swaps batteries with other battery swapping stations or is powered by a backup battery, it is determined that the user terminal has not generated any business behavior.

[0093] In this embodiment, when it is determined that the user terminal has generated a business activity, a transaction is created based on the business block data, and transaction data is generated. When it is determined that the user terminal has not generated a business activity, the system waits for the next business block data to be sent by the data chain 100.

[0094] In some optional implementations, the data processing terminal 200 can generate transaction data according to a preset transaction format based on the transaction hash, business behavior, number of behaviors, and terminal identifier of the user terminal in the data block where the business block data is located in the data chain 100, and send the transaction data to the business terminal 300. Specifically, the method for generating transaction data includes:

[0095] (1) Obtain the hash value corresponding to the business block data and the block identifier information of the data block where the business block data is located in data chain 100.

[0096] (2) The number of business behaviors is obtained based on the number of times the equipment parameters change within a preset time period.

[0097] (3) Generate transaction data for the user terminal based on the preset contract address, number of actions, business actions, hash value and block identifier information.

[0098] Here, the contract address refers to the calling address of the business contract deployed in the business terminal 300. Understandably, after deploying the business contract, the business terminal 300 sends the contract address of the business contract to the data processing terminal 200 corresponding to that business terminal 300.

[0099] Optionally, the preset transaction format can be to concatenate the hash value of the transaction hash, block identifier information, contract address, identifier code corresponding to the business behavior, number of behaviors, and terminal identifier in sequence; or, the preset transaction format can be to concatenate the hash value of the transaction hash and block identifier information to generate a transaction proof, concatenate the contract address, identifier code corresponding to the business behavior, and number of behaviors to generate behavior data, concatenate the transaction proof and behavior data to generate initial transaction data, and concatenate the initial transaction data and terminal identifier to generate transaction data.

[0100] Optionally, to enhance data transmission security, when generating transaction data, the contract address, the identifier code corresponding to the business behavior, and the number of behaviors can be concatenated to generate behavior data. The behavior data can be encrypted to obtain the ciphertext of the behavior data. The hash value of the transaction hash and the block identifier information can be concatenated to generate a transaction proof. The transaction proof and the ciphertext of the behavior data can be concatenated to generate initial transaction data. The initial transaction data can be concatenated with the terminal identifier to generate transaction data.

[0101] The behavioral data can be encrypted using either symmetric encryption or non-heap encryption.

[0102] Optionally, to further enhance data security, after obtaining the initial transaction data, it can be encrypted using either symmetric or asymmetric encryption methods to obtain ciphertext. This ciphertext is then concatenated with the terminal identifier to generate the final transaction data. Alternatively, after generating the transaction data, it can be encoded to obtain a transaction verification code, which, along with the transaction data, is then sent to the business terminal (300). The encoding process can be either hash encoding or MD5.

[0103] In this embodiment, a business contract is deployed on the business terminal 300. The business contract is used to process transactions of business data settlement events of user terminals, and the settled business data is stored in the business terminal 300.

[0104] In this embodiment, when the business terminal 300 receives the transaction data, it performs a security check on the transaction data. When the security check of the transaction data passes, it calls the business contract to perform business settlement on the transaction data, obtains the business data of the user terminal corresponding to the terminal identifier in the transaction data, and modifies the total business data of the user terminal in the business terminal 300 based on the business data of the user terminal.

[0105] Optionally, if the security verification of the transaction data fails, the transaction data is discarded, and a prompt message is sent to the corresponding data processing terminal 200, prompting the data processing terminal 200 to resend the transaction data.

[0106] Optionally, the transaction data can be encoded using a pre-stored encoding method to obtain a corresponding transaction code. This transaction code is then compared with a transaction verification code. If the transaction code and verification code match, the security verification of the transaction data is considered successful; otherwise, the security verification fails. Alternatively, the transaction data can be decrypted using a preset key, or the ciphertext of the behavioral data within the transaction data can be used to obtain decrypted transaction data or decrypted behavioral data. If the decrypted transaction data or decrypted behavioral data is not empty, the security verification of the transaction data is considered successful; otherwise, the security verification fails.

[0107] In some optional implementations, the business contracts deployed in the business terminal 300 include a first business contract and a second business contract. The first business contract is used to process transactions of business data settlement events of user terminals, and the second business contract is used to process transactions of total business data change events of user terminals based on the settled business data, and store the changed total business data in the business terminal 300.

[0108] Optionally, after receiving transaction data from data processing terminal 200, the business terminal 300 performs security verification on the transaction data. If the security verification passes, it calls the first business contract to perform business settlement, obtaining the user terminal's business data. Then, it calls the second business contract to modify the user terminal's total business data in business chain 31 based on the business data. Specifically, the business settlement method of the business terminal 300 includes steps d1 to d2:

[0109] Step d1: Invoke the second business contract to invoke the first business contract according to the preset contract address, perform business settlement based on the number of actions and business actions, and obtain the business data of the user terminal.

[0110] Step d2: Obtain the total business data of the user terminal, call the second business contract, and change the total business data of the user terminal in business chain 31 according to the business data.

[0111] Optionally, in some implementations, considering that business behaviors may change in actual application scenarios, or the business parameters corresponding to business behaviors may also change, and business contracts are difficult to modify after deployment, in order to facilitate the modification of business contracts, the contract address of the first business contract can be set in the second business contract. When it is necessary to modify the first business contract, a new first business contract is deployed, and the new contract address of the new first business contract is obtained. The contract address of the first business contract in the second business contract is updated to the new contract address. In this way, the new first business contract can be indirectly called through the second business contract, thereby improving the flexibility of business data settlement on the business side 300.

[0112] Optionally, at least one first business contract and one second business contract are deployed in the business terminal 300. Each business action corresponds to one first business contract, meaning that each business terminal 300 can perform the settlement of business data for at least one business action.

[0113] Optionally, after receiving transaction data sent by data processing terminal 200, the business terminal 300 performs security verification based on the transaction data. When the security verification of the transaction data passes, it determines the first business contract that matches each business behavior in the transaction data according to the behavior type of the business behavior in the transaction data, calls the first business contract that matches each business behavior in the transaction data to perform business settlement, obtains the business data of each business behavior of the user terminal, and calls the second business contract to change the total business data of the user terminal in the business chain 31 according to the business data of each business behavior of the user terminal.

[0114] Optionally, step d1 includes: calling a second business contract based on a preset contract address, referencing the contract address of the first business contract within the second business contract, calling the first business contract, performing business settlement based on business actions and the number of actions, and obtaining the user terminal's business data. In some implementations, the first business contract can be called to determine the unit business parameter corresponding to the business action, and the user terminal's business data can be obtained by multiplying the number of actions by the unit business parameter.

[0115] In some optional implementations, in order to facilitate the timely distribution of user terminal rights data, the business terminal 300 generates business transaction data from the total business data of all user terminals modified within the business terminal 300 within the preset time interval every preset time interval, and sends the business transaction data to the public chain 400.

[0116] Specifically, at each preset time interval, the business terminal 300 obtains the modified total business data of each user terminal within the preset time interval, and obtains the total business data based on the modified total business data of each user terminal. The modified total business data of each user terminal and the total business data are then used to generate business transaction data according to the preset rights and interests transaction format, and the business transaction data is sent to the public chain 400.

[0117] Optionally, after sending business transaction data to the public chain 400, the total business data of each user terminal in the business terminal 300 after their respective modifications are changed is modified to 0, and business settlement is performed based on the transaction data sent by the data processing terminal 200 within the next preset time period.

[0118] Optionally, after sending business transaction data to public chain 400, the total business data modified by each user terminal within a preset time period is written into the storage block in business terminal 300, and a new storage block is created to store the total business data modified by each user terminal within the next preset time period in the new storage block.

[0119] In some optional implementations, to better preserve the user terminal's business data and total business data, and to prevent tampering with the business data and total business data, a business chain 31 can be set up in the business terminal 300. The total business data and business data of each user terminal can be stored in the business chain 31 in the form of a blockchain. For example, as shown... Figure 3 As shown, Figure 3 This is another schematic diagram of a blockchain-based business processing system provided in this embodiment of the invention. The business terminal 300 in the blockchain-based business processing system includes a business processing terminal 32 and a business chain 31. Each business terminal 300's business chain 31 connects to the public chain 400 through its corresponding business processing terminal 32. The business chain 31 deploys a first business contract and a second business contract. The business blocks on the business chain 31 store the user terminal's transaction data, business data, and total business data.

[0120] Understandably, at least one first business contract and one second business contract are deployed in business chain 31.

[0121] Optionally, the business processing terminal 32 is used to generate business transaction data based on the total business data after changes to all user terminals on the business chain 31, and send the business transaction data to the public chain 400. In some implementations, the business processing terminal 32 can be a mobile terminal or a computer device.

[0122] Optionally, the business processing terminal 32 can be deployed on the business chain 31. For example, there are multiple business nodes on the business chain 31. The main business node is selected from the multiple business nodes and set as the business processing terminal 32. Optionally, the business processing terminal 32 can be deployed outside the business chain 31 and interact with the business nodes on the business chain 31 through wired networks, wireless networks, data interfaces, etc.

[0123] Optionally, when the business terminal 300 performs business settlement based on the transaction data sent by the data processing terminal 200, the business chain 31 calls the first business contract through the second business contract to perform business settlement on the business actions and number of actions in the transaction data, obtains the user terminal's business data, calls the second business contract on the business chain 31, modifies the user terminal's total business data in the business chain 31 according to the user terminal's business data, and writes the user terminal's transaction data, business data, and modified total business data into the business block corresponding to the user terminal. Understandably, each user terminal has a unique terminal identifier on the business chain 31.

[0124] In this embodiment, when the business processing terminal 32 generates business transaction data, it sends a first transaction request to the business chain 31. The business chain 31 responds to the first transaction request, locks the total business data of each user terminal on the business chain 31, and sends the total business data of each user terminal on the business chain 31 at the current time to the business processing terminal 32. The business processing terminal 32 generates business transaction data based on the total business data of each user terminal and sends the business transaction data to the public chain 400.

[0125] Optionally, when business chain 31 receives the first transaction request sent by business processing terminal 32, it locks the modified total business data of each user terminal in business chain 31 at the current moment, generates business status data based on the modified total business data of all previous user terminals, saves the business status data, modifies the total business data for the next preset time period, and sends the business status data to the corresponding business processing terminal 32. The business status data is used to represent the total business data of user terminals on business chain 31 within the current preset time period, as well as the record data of business data settlement. In some implementations, the business status data can be a snapshot.

[0126] Optionally, when the business chain 31 receives the first transaction request sent by the business processing terminal 32, it locks the changed total business data of each user terminal in the business chain 31 at the current moment and sends feedback information to the business processing terminal 32. When the business processing terminal 32 receives the feedback information, it sends a second transaction request to the business chain 31. The business chain 31 responds to the second transaction request, generates business status data based on the changed total business data of all previous user terminals, saves the business status data, changes the total business data for the next preset time period, and sends the business status data to the corresponding business processing terminal 32.

[0127] Optionally, after responding to the first transaction request, business chain 31 enters the next preset duration stage of business data, creates a new business block, stores the total business data of each user terminal within the next preset duration in the new business block, and sets the total business data of each user terminal to 0. At this time, if the data processing terminal 200 sends transaction data of the user terminal, the business data of the user terminal is determined according to the transaction data and the execution of the first business contract, the second business contract is executed, the total business data of each user terminal is changed in business chain 31 according to the business data, and the changed total business data is written into the new business block.

[0128] Optionally, after receiving the business status data, the business processing terminal 32 determines the total business data of each user terminal within the preset time period and the total business data within the preset time period based on the business status data. Then, based on the total business data of each user terminal, the total business data, the identification information of the business status data, the identification information of the business chain 31, and according to a preset rights transaction format, it generates business transaction data and sends the business transaction data to the public chain. It should be noted that this embodiment of the invention does not specifically limit the form of the preset rights transaction format; it can be set according to the specific application scenario.

[0129] In this embodiment of the invention, when the public chain 400 receives the business transaction data sent by the business processing terminal 32, it determines the user terminal to which the rights data to be issued is to be determined based on the business transaction data, and calls the rights contract to change the rights data of each user terminal to which the rights data to be issued is to be changed in the public chain 400 according to the business transaction data.

[0130] For example, taking a battery swapping scenario, each swapping station has a corresponding equity account set up in the public chain 400. The equity account stores the total equity data corresponding to the swapping station. When business transaction data sent by the business processing terminal 32 is received, the target equity account is determined according to the business chain 31 identifier in the business transaction data. The equity contract is called to determine the total number of equity to be issued based on the total business data in the business transaction data. Based on the total business volume of each user terminal and the total business data of each user terminal, the equity share corresponding to each user terminal is determined. Based on the equity share corresponding to each user terminal, the equity data of the terminal identifier corresponding to each user terminal is changed on the public chain 400. The total equity data in the target equity account is modified according to the total equity volume.

[0131] Optionally, after changing the equity data of a user terminal, Public Chain 400 will write the equity share corresponding to each user terminal, the changed equity data, and the business transaction data into the equity block in Public Chain 400.

[0132] Optionally, the public chain 400 corresponds to an application client, which provides services such as rights exchange to users corresponding to user terminals. Rights exchange can be achieved by exchanging value through the rights data on the public chain 400 of the user terminal. For example, users can use their rights data to redeem different items, gift certificates, and other prizes, thereby consuming the rights data. This method of incentivizing users through rights data can encourage them to continuously generate business activities to obtain more rights data.

[0133] In this embodiment, based on Figure 1 and Figure 3 The blockchain-based business processing system architecture ensures that every share of rights issued on the public chain 400 can be traced through the layered transmission of data.

[0134] Optionally, when a user has doubts about the rights and interests data of a user terminal, the system responds to the user's input rights and interests tracing request, determines the target rights and interests share to be traced and the target business transaction data corresponding to the target rights and interests share, obtains the status data identifier information to be verified from the target business transaction data, and sends a business tracing request to the business processing terminal 32 corresponding to the target business transaction data based on the status data identifier information to be verified. The business processing terminal 32 responds to the business tracing request and sends a business verification request to the business chain 31 based on the status data identifier information to be verified in the business tracing request. The business chain 31 responds to the business verification request and determines whether the status data identifier information to be verified exists on the business chain 31. If the business status data corresponding to the pending verification status data identifier information exists on business chain 31, then the target business status data is returned to business processing terminal 32. Business processing terminal 32 sends the target business status data returned by business chain 31 to public chain 400. Public chain 400 sends the total business data of the user terminal in the target business status data to the user corresponding to the user terminal. If the business status data corresponding to the pending verification status data identifier information does not exist on business chain 31, then a business tracing failure prompt message is returned to business processing terminal 32. Business processing terminal 32 sends the prompt message returned by business chain 31 to public chain 400. Public chain 400 sends a rights tracing failure prompt message to the user corresponding to the user terminal.

[0135] Optionally, to ensure the credibility of rights data distribution, the business data and total business data in business chain 31 are also traceable. When the business processing terminal 32 or business chain 31 of business terminal 300 receives a data traceability request, the business processing terminal 32 or business chain 31 of business terminal 300 responds to the data traceability request, determines the target hash value and target block identifier information of the data to be traced back, and realizes the traceability of transaction data based on the target hash value and target block identifier information of the data to be traced back. Specifically, the transaction data traceability method includes steps e1 to e4:

[0136] Step e1: The business terminal 300 sends a data verification request to the data processing terminal 200.

[0137] The data verification request includes the target hash value and target block identifier information of the data to be traced back; the data verification request is used to verify the authenticity of the data to be traced back to the data processing terminal 200.

[0138] Optionally, the business processing terminal 32 or business chain 31 in the business terminal 300 sends a data verification request to the data processing terminal 200 based on the target hash value and target block identifier information of the data to be traced back.

[0139] In step e2, the data processing terminal 200 responds to the received data verification request and sends a data query request to the data chain 100 based on the target hash value and the target block identifier information. The data request is used to request target block information from the data chain 100 that matches the target hash value and the target block identifier information.

[0140] Step e3: Based on the received data query request, data chain 100 queries whether there is target block information that matches the target hash value and target block identifier information, and returns the target block information to data processing terminal 200.

[0141] Step e4: Based on the received target block information, the data processing terminal 200 sends the data verification result back to the business terminal 300; the data verification result includes data verification passed and data verification failed.

[0142] Optionally, step e4 includes: if the target block information is not empty, then the data verification is confirmed to be successful, and the target block information is sent to the business terminal 300; if the target block information is empty, then the data verification is confirmed to be unsuccessful, and a prompt message is sent to the business terminal 300.

[0143] Optionally, step e4 includes: the data processing terminal 200 compares the received target block information with the data to be traced back. If the target block information matches the data to be traced back, the data verification is deemed successful, and the target block information is sent to the business terminal 300. If the target block information does not match the data to be traced back, the data verification is deemed unsuccessful, and a prompt message is sent to the business terminal 300. Optionally, the matching of the target block information and the data to be traced back can be determined by checking whether they are consistent. For example, if the target block information matches the data to be traced back, the matching is determined; if they do not match, the mismatch is determined.

[0144] Optionally, when the business chain 31 or business processing terminal 32 in the business terminal 300 receives the target block information, it determines that the data tracing is successful; when the business chain 31 or business processing terminal 32 in the business terminal 300 receives the prompt information, it determines that the data tracing has failed.

[0145] The blockchain-based business processing system provided in this embodiment, based on a multi-level blockchain architecture, reports the device parameters of IoT devices layer by layer, realizing automatic settlement of business data and rights data, reducing the difficulty of data settlement supervision; and through the data processing terminal 200, business behavior analysis is performed based on device parameters. Transaction data is only created when the user terminal performs the above-mentioned business behavior, and business data settlement is performed based on the transaction data. This can achieve isolation between device parameters in the data chain and business data in the business terminal 300, improving data security.

[0146] The following combines the use of Figure 1 and Figure 3 The structure of the blockchain-based business processing system shown provides a blockchain-based business processing flow. This business processing flow is applicable to a blockchain-based business processing system that includes at least one data chain, at least one data processing terminal 200, at least one business terminal, and a public chain 400. Each data chain corresponds to one data processing terminal 200, each data processing terminal 200 corresponds to one business terminal, and equity contracts are deployed on the public chain 400. Each business terminal connects to the public chain 400. Figure 4 The flowchart illustrating the blockchain-based business processing method uses one data chain and a corresponding business terminal as an example. Specifically, the blockchain-based business processing method includes steps 210 to 240:

[0147] Step 210: Data nodes on the data chain send business block data to the data processing terminal. The business block data includes device parameters of the IoT devices used by the user terminals corresponding to the data nodes within a preset time period.

[0148] Step 220: The data processing end determines whether the user terminal has generated business behavior based on the device parameters of the IoT device used by the user terminal within a preset time period in the received business block data. If business behavior is generated, the transaction is created in the business block data, and the transaction data is sent to the business end.

[0149] Step 230: The business terminal performs business settlement based on the received transaction data to obtain the business data of the user terminal. Based on the business data of the user terminal, it modifies the total business data of the user terminal in the business terminal. At a preset time interval, it generates business transaction data based on the modified total business data of all user terminals in the business terminal and sends the business transaction data to the public chain.

[0150] Step 240: Based on the received business transaction data, the public chain calls the equity contract to change the equity data of each user terminal in the public chain according to the business transaction data.

[0151] Optionally, in some implementations, it is determined whether the user terminal has generated a service behavior based on the device parameters of the IoT device used by the user terminal within a preset time period in the received service block data. If a service behavior is generated, it includes: if the device parameters of the IoT device used by the user terminal have not changed within the preset time period, then historical service block data matching the user terminal's service block data is obtained, and it is determined whether the historical device parameters in the historical service block data are consistent with the device parameters. If the historical device parameters in the historical service block data are inconsistent with the device parameters, then it is determined that the user terminal has generated a service behavior; if the device parameters of the IoT device used by the user terminal have changed within the preset time period, then it is determined that the user terminal has generated a service behavior.

[0152] Optionally, obtaining historical business block data that matches the business block data of the user terminal includes: obtaining the block height or block time of the data block where the business block data is located in the data chain; determining the historical data block in the data chain with the smallest height difference between the historical block heights and the block heights, or the smallest time difference between the historical block times and the block times, that has the same business type as the business block data; and setting the historical business block data in the historical data block as the historical business block data that matches the business block data of the user terminal.

[0153] Optionally, the business block data also includes time information for each device parameter. In this embodiment, it can be determined that the device parameters of the IoT device used by the user terminal have not changed within a preset time period based on each device parameter and its time information. Specifically, this includes: sorting each device parameter according to its time information to obtain a parameter sequence; comparing each device parameter in the parameter sequence with the preceding device parameter adjacent to it to obtain a comparison result; the comparison result includes parameter consistency and parameter inconsistency; if the comparison result of each device parameter in the parameter sequence indicates parameter consistency, it is determined that the device parameters of the IoT device used by the user terminal have not changed within the preset time period; if there is a target device parameter in the parameter sequence whose comparison result indicates parameter inconsistency, it is determined that the device parameters of the IoT device used by the user terminal have changed within the preset time period.

[0154] Optionally, in some implementations, the business block data also includes user terminal operation data within a preset time period. To ensure the feasibility of business behavior analysis, business behavior analysis is performed using operation data and device parameters to determine whether the user terminal has generated business behavior. Specifically, this includes: determining whether the device parameters of the IoT device used by the user terminal have changed within the preset time period based on the device parameters of the IoT device used by the user terminal; parsing the operation data to determine whether there are behavioral parameters in the operation data; behavioral parameters characterize the user terminal's operation behavior within the preset time period; if the device parameters of the IoT device used by the user terminal have changed within the preset time period, and behavioral parameters exist in the operation data, then it is determined that the user terminal has generated business behavior; if the device parameters of the IoT device used by the user terminal have not changed within the preset time period, and / or there are no behavioral parameters in the operation data, then it is determined that the user terminal has not generated business behavior.

[0155] Optionally, in some implementations, if a business action is generated, a transaction is created for the business block data. Generating transaction data includes: obtaining the hash value corresponding to the business block data and the block identifier information of the data block where the business block data is located in the data chain; obtaining the number of business actions based on the number of changes in device parameters within a preset time period; and generating transaction data for the user terminal based on the preset contract address, number of actions, business action, hash value, and block identifier information.

[0156] Optionally, in some implementations, after business settlement is performed based on the received transaction data to obtain the user terminal's business data, the business end sends a data verification request to the data processing end. The data verification request includes the target hash value and target block identifier information of the data to be traced back. The data verification request is used to verify the authenticity of the data to be traced back to the data processing end. In response to the received data verification request, the data processing end sends a data query request to the data chain based on the target hash value and target block identifier information. The data request is used to request target block information that matches the target hash value and target block identifier information from the data chain. Based on the received data query request, the data chain queries whether there is target block information that matches the target hash value and target block identifier information, and returns the target block information to the data processing end. Based on the received target block information, the data processing end feeds back the data verification result to the business end. The data verification result includes data verification passed and data verification failed.

[0157] Optionally, based on the received target block information, the data verification result is fed back to the business end, including: if the target block information is not empty, the data verification is determined to be successful, and the target block information is sent to the business end; if the target block information is empty, the data verification is determined to be unsuccessful, and a prompt message is sent to the business end.

[0158] Optionally, based on the received target block information, the data verification result is fed back to the business end, including: if the target block information matches the data to be traced, the data verification is determined to be successful, and the target block information is sent to the business end; if the target block information does not match the data to be traced, the data verification is determined to be unsuccessful, and a prompt message is sent to the business end.

[0159] The blockchain-based business processing method provided in this invention uses a multi-level blockchain architecture to report the device parameters of IoT devices layer by layer, enabling automatic settlement of business data and reducing the difficulty of supervising data settlement. Furthermore, the data processing terminal analyzes business behavior based on device parameters, and only creates transaction data when the user terminal performs the aforementioned business behavior. Business data settlement is then performed based on the transaction data, which can achieve isolation between device parameters in the data chain and business data in the business terminal, thereby improving data security.

[0160] As can be understood, the preceding text has described the technical concept and related implementation methods of this specification from the perspective of the overall system architecture. The following embodiments are described from the perspective of individual terminals, namely the data processing terminal and the business terminal.

[0161] like Figure 5 As shown, according to one embodiment, a blockchain-based business processing flow suitable for a data processing end is provided, including the following steps:

[0162] Step 310: Obtain the business block data sent by the data node on the data chain. The business block data includes the device parameters of the IoT devices used by the user terminal corresponding to the data node within a preset time period.

[0163] Step 320: Determine whether the user terminal generates business behavior based on the device parameters of the IoT device used by the user terminal.

[0164] Step 330: If a business activity occurs, a transaction is created for the business block data, transaction data is generated, and the transaction data is sent to the corresponding business terminal so that the business terminal can perform business settlement based on the transaction data and obtain the business data of the user terminal.

[0165] Correspondingly, such as Figure 5 As shown, a blockchain-based business processing device that can be located at a data processing terminal is provided. The device includes:

[0166] The parameter acquisition module is used to acquire business block data sent by data nodes on the data chain. The business block data includes the device parameters of the IoT devices used by the user terminal corresponding to the data node within a preset time period.

[0167] The behavior analysis module is used to determine whether the user terminal generates business behavior based on the device parameters of the IoT device used by the user terminal.

[0168] The transaction creation module is used to create transactions from business block data when business activities occur, generate transaction data, and send the transaction data to the corresponding business terminal so that the business terminal can perform business settlement based on the transaction data and obtain the business data of the user terminal.

[0169] like Figure 7 As shown, according to one embodiment, a blockchain-based business processing flow suitable for the business side is provided, including the following steps:

[0170] Step 410: Receive transaction data from the user terminal sent by the data processing terminal.

[0171] Step 420: Call the business contract to perform business settlement on the transaction data, obtain the business data of the user terminal, and modify the total business data of the user terminal in the business end based on the business data of the user terminal.

[0172] Step 430: At each preset interval, generate business transaction data based on the total business data modified by all user terminals in the business terminal, and send the business transaction data to the public chain.

[0173] Optionally, in some implementations, the business contract includes a first business contract and a second business contract, and the transaction data includes a preset contract address, number of actions, and business actions. Step 420 includes: calling the second business contract to call the first business contract according to the preset contract address, performing business settlement according to the number of actions and business actions, and obtaining the user terminal's business data; obtaining the user terminal's total business data, calling the second business contract, and changing the user terminal's total business data in the business chain according to the business data.

[0174] Optionally, in some implementations, such as Figure 3As shown, the business end includes a business processing end and a business chain. The business chain of each business end is connected to the public chain through the corresponding business processing end. The business chain deploys a first business contract and a second business contract. The business blocks on the business chain store the transaction data, business data and total business data of the user terminals. Step 430 includes: the business processing end sends a first transaction request to the business chain at preset intervals; the first transaction request is used to request the changed total business data of each user terminal in the business chain from the business chain; the business chain responds to the first transaction request of the business processing end, locks the changed total business data of all user terminals, generates business status data based on the changed total business data of all previous user terminals, and sends the business status data to the corresponding business processing end; the business processing end receives the business status data sent by the business chain, generates business transaction data based on the business status data, and sends the business transaction data to the public chain.

[0175] Correspondingly, such as Figure 8 As shown, a blockchain-based business processing device that can be installed at the business end is provided. The device includes:

[0176] The receiving module is used to receive transaction data from the user terminal sent by the data processing end;

[0177] The settlement module is used to call the business contract to perform business settlement on the transaction data, obtain the business data of the user terminal, and change the total business data of the user terminal in the business end based on the business data of the user terminal.

[0178] The business transaction module is used to generate business transaction data based on the total business data modified by all user terminals in the business end at preset intervals, and send the business transaction data to the public chain.

[0179] It is worth noting that Figure 4 The method embodiment shown is Figure 1 or Figure 3 The system architecture shown has a business processing flow. Figure 5 , Figure 7 The method embodiments shown are respectively Figure 1 or Figure 3 The system architecture shown illustrates the execution flow of the data processing end and the business end. Figure 6 , Figure 8 The illustrated device embodiments are respectively in Figure 5 , Figure 7 The method embodiments shown correspond to each other and will not be described again here.

[0180] This invention also provides a blockchain-based business processing device, such as... Figure 9 As shown, it illustrates a structural schematic diagram of a blockchain-based business processing device according to an embodiment of the present invention. Specifically:

[0181] The blockchain-based business processing device may include components such as a processor 901 with one or more processing cores, a memory 902 with one or more computer-readable storage media, a power supply 903, and an input unit 904. Those skilled in the art will understand that... Figure 9 The blockchain-based business processing device structure shown does not constitute a limitation on blockchain-based business processing devices. It may include more or fewer components than shown, or combine certain components, or have different component arrangements. Wherein:

[0182] The processor 901 is the control center of the blockchain-based business processing device. It connects various parts of the device via various interfaces and lines, and executes software programs and / or modules stored in the memory 902, as well as accessing data stored in the memory 902, to perform various functions and process data, thereby providing overall monitoring of the device. Optionally, the processor 901 may include one or more processing cores; preferably, it may integrate an application processor and a modem processor, where the application processor primarily handles the operating system, user interface, and applications, while the modem processor primarily handles wireless communication. It is understood that the modem processor may not be integrated into the processor 901.

[0183] The memory 902 can be used to store software programs and modules. The processor 901 executes various functional applications and data processing by running the software programs and modules stored in the memory 902. The memory 902 may mainly include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback function, image playback function, etc.), etc.; the data storage area may store data created based on the use of the blockchain-based business processing device, etc. In addition, the memory 902 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, or other volatile solid-state storage device. Accordingly, the memory 902 may also include a memory controller to provide the processor 901 with access to the memory 902.

[0184] The blockchain-based business processing equipment also includes a power supply 903 that supplies power to the various components. Preferably, the power supply 903 can be logically connected to the processor 901 through a power management system, thereby enabling functions such as charging, discharging, and power consumption management through the power management system. The power supply 903 may also include one or more DC or AC power supplies, recharging systems, power fault detection circuits, power converters or inverters, power status indicators, and other arbitrary components.

[0185] The blockchain-based business processing device may also include an input unit 904, which can be used to receive input digital or character information and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function control.

[0186] Although not shown, the blockchain-based business processing device may also include a display unit, etc., which will not be described in detail here. Specifically, in this embodiment, the processor 901 in the blockchain-based business processing device loads the executable files corresponding to the processes of one or more applications into the memory 902 according to the following instructions, and the processor 901 runs the applications stored in the memory 902 to realize various functions, as follows:

[0187] Data nodes on the data chain send business block data to the data processing terminal; the business block data includes the device parameters of the IoT devices used by the user terminal corresponding to the data node within a preset time period;

[0188] The data processing end determines whether the user terminal has generated business behavior based on the device parameters of the IoT device used by the user terminal within a preset time period in the received business block data. If business behavior is generated, the transaction is created in the business block data, the transaction data is generated and sent to the business end.

[0189] The business side performs business settlement based on the received transaction data, obtains the business data of the user terminal, modifies the total business data of the user terminal in the business side based on the business data of the user terminal, and generates business transaction data based on the modified total business data of all user terminals in the business side at preset intervals, and sends the business transaction data to the public chain.

[0190] Based on the received business transaction data, the public blockchain invokes the equity contract to change the equity data of each user terminal in the public blockchain according to the business transaction data.

[0191] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be performed by instructions, or by instructions controlling related hardware. These instructions can be stored in a computer-readable storage medium and loaded and executed by a processor.

[0192] To this end, embodiments of the present invention provide a storage medium storing a plurality of instructions that can be loaded by a processor to execute steps in any of the virtual resource transfer methods provided in the embodiments of the present invention. For example, the instructions can execute the following steps:

[0193] Data nodes on the data chain send business block data to the data processing terminal; the business block data includes the device parameters of the IoT devices used by the user terminal corresponding to the data node within a preset time period;

[0194] The data processing end determines whether the user terminal has generated business behavior based on the device parameters of the IoT device used by the user terminal within a preset time period in the received business block data. If business behavior is generated, the transaction is created in the business block data, the transaction data is generated and sent to the business end.

[0195] The business side performs business settlement based on the received transaction data, obtains the business data of the user terminal, modifies the total business data of the user terminal in the business side based on the business data of the user terminal, and generates business transaction data based on the modified total business data of all user terminals in the business side at preset intervals, and sends the business transaction data to the public chain.

[0196] Based on the received business transaction data, the public blockchain invokes the equity contract to change the equity data of each user terminal in the public blockchain according to the business transaction data.

[0197] For details on the implementation of each of the above operations, please refer to the previous examples, which will not be repeated here.

[0198] The storage medium may include: read-only memory (ROM), random access memory (RAM), disk or optical disk, etc.

[0199] Since the instructions stored in the storage medium can execute the steps in any of the virtual resource transfer methods provided in the embodiments of the present invention, the beneficial effects that any of the virtual resource transfer methods provided in the embodiments of the present invention can achieve can be realized, as detailed in the preceding embodiments, and will not be repeated here.

[0200] The foregoing has provided a detailed description of a browser page data filtering method, apparatus, and system provided by embodiments of the present invention. Specific examples have been used to illustrate the principles and implementation methods of the present invention. The descriptions of the above embodiments are only for the purpose of helping to understand the method and core ideas of the present invention. At the same time, for those skilled in the art, there will be changes in specific implementation methods and application scope based on the ideas of the present invention. Therefore, the content of this specification should not be construed as a limitation of the present invention.

Claims

1. A blockchain-based business processing method, characterized by, The method is applied to a blockchain-based business processing system; the blockchain-based business processing system comprises at least one data chain, at least one data processing end, at least one business end and a public chain, each data chain corresponds to a data processing end, each data processing end corresponds to a business end, the public chain is deployed with a right contract, each business end accesses the public chain, and the method comprises the following steps; The data node on the data chain sends business block data to the data processing end; The business block data comprises device parameters of an adopted Internet of Things equipment of a user terminal corresponding to the data node within a preset time period; The data processing end determines whether the user terminal generates a business behavior based on the device parameters of the adopted Internet of Things equipment of the user terminal within the preset time period in the received business block data, and if the user terminal generates a business behavior, transaction creation is performed on the business block data, transaction data is generated, and the transaction data is sent to the business end; The business end performs business settlement based on the received transaction data, obtains business data of the user terminal, changes total business data of the user terminal in the business end based on the business data of the user terminal, generates business transaction data according to the changed total business data of all user terminals in the business end every interval of a preset time length, and sends the business transaction data to the public chain; The public chain calls the right contract to change the right data of each user terminal in the public chain based on the received business transaction data. 2.The blockchain-based business process handling method of claim 1, wherein, The determination of whether the user terminal generates a business behavior based on the received device parameters in the business block data comprises the following steps: If the device parameters of the adopted Internet of Things equipment of the user terminal within the preset time period do not change, historical business block data matched with the business block data of the user terminal is obtained, it is determined whether the historical device parameters in the historical business block data are consistent with the device parameters, and if the historical device parameters in the historical business block data are inconsistent with the device parameters, it is determined that the user terminal generates a business behavior; If the device parameters of the adopted Internet of Things equipment of the user terminal within the preset time period change, it is determined that the user terminal generates a business behavior. 3.The blockchain-based business processing method of claim 2, wherein, The obtaining of the historical business block data matched with the business block data of the user terminal comprises the following steps: Obtaining the block height or block time of a data block where the business block data is located in the data chain; Determining a historical data block with the minimum height difference between the historical block height and the block height or the minimum time difference between the historical block time and the block time of the historical block height and the block height of the same business type as the business block data in the data chain; Setting the historical business block data in the historical data block as the historical business block data matched with the business block data of the user terminal. 4.The blockchain-based business processing method of claim 2, wherein, The business block data further comprises time information of each device parameter; Before the determination of whether the user terminal generates a business behavior based on the device parameters of the adopted Internet of Things equipment of the user terminal within the preset time period, the method comprises the following steps: According to the time information of each device parameter, the device parameters are sorted to obtain a parameter sequence; For each device parameter in the parameter sequence, the device parameter and the previous device parameter adjacent to the device parameter are compared to obtain a comparison result of the device parameter; the comparison result includes parameter consistency and parameter inconsistency; If the comparison result of each device parameter in the parameter sequence represents parameter consistency, it is determined that the device parameters of the Internet of Things device used by the user terminal in the preset time period have not changed; If there is a target device parameter in the parameter sequence whose comparison result represents parameter inconsistency, it is determined that the device parameters of the Internet of Things device used by the user terminal in the preset time period have changed. 5.The blockchain-based business processing method of claim 1, wherein, The business block data further includes operation data of the user terminal in the preset time period; According to the device parameters of the Internet of Things device used by the user terminal in the preset time period, it is determined whether the user terminal generates a business behavior, including: According to the device parameters of the Internet of Things device used by the user terminal in the preset time period, it is determined whether the device parameters of the Internet of Things device used by the user terminal in the preset time period have changed; The operation data is analyzed to determine whether there is a behavior parameter in the operation data; the behavior parameter represents that the user terminal generates an operation behavior in a preset time; If the device parameters of the Internet of Things device used by the user terminal in the preset time period have changed, and there is a behavior parameter in the operation data, it is determined that the user terminal generates a business behavior; If the device parameters of the Internet of Things device used by the user terminal in the preset time period have not changed, and / or there is no behavior parameter in the operation data, it is determined that the user terminal does not generate a business behavior. 6.The blockchain-based business processing method of claim 1, wherein, If a business behavior is generated, the business block data is subjected to transaction creation to generate transaction data, including: Obtaining a hash value corresponding to the business block data; According to the number of changes of the device parameters in the preset time period, the number of behaviors of the business behavior is obtained; According to a preset contract address, the number of behaviors, the business behavior, and the hash value, the transaction data of the user terminal is generated. 7.The blockchain-based business processing method according to any one of claims 1 to 6, wherein, After the business settlement based on the received transaction data is performed to obtain the business data of the user terminal, the method includes: The business end sends a data verification request to the data processing end, and the data verification request includes a target hash value and target block identification information of the to-be-traced data; the data verification request is used to verify the authenticity of the to-be-traced data to the data processing end; The data processing end responds to the received data verification request, and based on the target hash value and the target block identification information, sends a data query request to the data chain; the data query request is used to request the target block information consistent with the target hash value and the target block identification information from the data chain; The data chain queries whether there is target block information consistent with the target hash value and the target block identifier information based on the received data query request, and returns the target block information to the data processing end; The data processing end feeds back data verification results to the service end based on the received target block information; the data verification results include data verification pass and data verification fail. 8.The blockchain-based business processing method of claim 7, wherein, The method is applied to a business processing system based on a block chain; the business processing system based on the block chain includes at least one data chain, at least one data processing end, at least one service end, and a public chain, each data chain corresponds to a data processing end, each data processing end corresponds to a service end, and the public chain is deployed with a right contract, and each service end accesses the public chain; The method is executed by the data processing end, and the method includes: Obtaining service block data sent by a data node on the data chain, the service block data including device parameters of an Internet of Things device used by a user terminal corresponding to the data node within a preset time period; 9.A blockchain-based business processing method, characterized by, According to the device parameters of the Internet of Things device used by the user terminal, it is determined whether the user terminal generates a business behavior; If a business behavior is generated, transaction creation is performed on the service block data, transaction data is generated, and the transaction data is sent to the corresponding service end, so that the service end performs business settlement based on the transaction data to obtain business data of the user terminal. The method is applied to a business processing system based on a block chain; the business processing system based on the block chain includes at least one data chain, at least one data processing end, at least one service end, and a public chain, each data chain corresponds to a data processing end, each data processing end corresponds to a service end, and the public chain is deployed with a right contract, and each service end accesses the public chain; The method is executed by the service end, and the service end is deployed with a business contract, and the method includes: Receiving transaction data of a user terminal sent by the data processing end; 10.A blockchain-based business processing method, characterized by, Calling the business contract to perform business settlement on the transaction data to obtain business data of the user terminal, and changing business total data of the user terminal in the service end based on the business data of the user terminal; Every interval generates business transaction data according to the changed business total data of all user terminals in the service end, and sends the business transaction data to the public chain. The business contract includes a first business contract and a second business contract, and the transaction data includes a preset contract address, a behavior frequency and a business behavior; ​ ​ 11. The blockchain-based business processing method of claim 10, wherein, ​ The calling the business contract settles the business of the transaction data, obtains the business data of the user terminal, and changes the total business data of the user terminal in the business end based on the business data of the user terminal, including: According to the preset contract address, the second business contract is called to call the first business contract, and the business is settled according to the number of behaviors and the business behavior, and the business data of the user terminal is obtained; Obtain the total business data of the user terminal, call the second business contract, and change the total business data of the user terminal in the business chain according to the business data.

12. The blockchain-based business processing method of claim 10, wherein, The business end includes a business processing end and a business chain, and the business chain of each business end is connected to the public chain through the corresponding business processing end; The first business contract and the second business contract are deployed in the business chain, and the transaction data, business data and total business data of the user terminal are stored in the business block on the business chain; The business transaction data is generated according to the changed total business data of all user terminals in the business end every interval preset time length, and the business transaction data is sent to the public chain, including: The business processing end sends a first transaction request to the business chain every interval preset time length; The first transaction request is used to request the changed total business data of each user terminal in the business chain from the business chain; The business chain responds to the first transaction request of the business processing end, locks the changed total business data of all user terminals, generates business state data according to the changed total business data of all user terminals, and sends the business state data to the corresponding business processing end; The business processing end receives the business state data sent by the business chain, generates business transaction data according to the business state data, and sends the business transaction data to the public chain.

13. A blockchain-based business processing system, characterized by, The system includes at least one data chain, at least one data processing end, at least one business end and a public chain, each data chain corresponds to a data processing end, each data processing end corresponds to a business end, and the public chain is deployed with a right contract, and each business end is connected to the public chain; The data chain is used to collect the device parameters of the Internet of Things equipment used by the user terminal within a preset time, generate business block data according to the device parameters, and send the business block data to the corresponding data processing end; The data processing end is used to obtain the business block data sent by the data node on the corresponding data chain, determine whether the user terminal generates a business behavior according to the device parameters of the Internet of Things equipment used by the user terminal within the preset time period in the business block data, if the business behavior is generated, the business block data is created, the transaction data is generated, and the transaction data is sent to the corresponding business end; The business end is configured to receive the transaction data sent by the corresponding data processing end, perform business settlement on the transaction data, obtain business data of the user terminal, change total business data of the user terminal in the business end according to the business data of the user terminal, generate business transaction data according to the changed total business data of all user terminals in the business end every interval of a preset time length, and send the business transaction data to the public chain. The public chain is configured to receive the business transaction data sent by the business end, and change the equity data of each user terminal in the public chain according to the business transaction data by calling the equity contract.

Citation Information

Patent Citations

  • Business processing method and system based on blockchain

    CN112633953A

  • Cross-chain data sharing method and system between Hyperledger Fabric and Ethernet workshop

    CN115065687A