Block chain virtual resource transfer method and device and block chain system
By generating an account on the blockchain and transferring virtual resources, the problem of low security in traditional blockchain virtual resource transfer methods was solved, and safe and efficient resource transfer was realized.
Patent Information
- Application Number
- CN202310939823.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-27
- Publication Date
- 2025-01-28
AI Technical Summary
The traditional blockchain virtual resource transfer method has low security problems, which can easily lead to the leakage of account information of the recipient.
By generating a blockchain account for storing the virtual resources of the blockchain, determine the virtual resources of the transferor, and initiate the resource to the on -board request. In response, generate resources to receive information, and instruct the resource to receive virtual resources from the blockchain account.
The safety transfer of blockchain virtual resources, avoiding the direct interaction of the resource transfer and the recipient, reducing the risk of account information leakage and improving security.
Smart Images

Figure CN119379280A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a blockchain virtual resource transfer method, device, blockchain system, computer equipment, computer-readable storage medium and computer program product. Background Art
[0002] As a decentralized multi-node network, blockchain can achieve secure data storage. Virtual resources on the blockchain can be transferred from one blockchain account to another, realizing the circulation of resources on the chain.
[0003] In traditional technology, the resource transferor interacts with the resource recipient to obtain the resource recipient's account information, and transfers virtual resources based on the recipient's account information, which can easily cause the recipient's account information to be leaked and has the disadvantage of low security. Summary of the invention
[0004] Based on this, it is necessary to provide a blockchain virtual resource transfer method, device, blockchain system, computer equipment, computer-readable storage medium and computer program product that can improve security in response to the above-mentioned technical problems.
[0005] In a first aspect, the present application provides a blockchain virtual resource transfer method. The method comprises:
[0006] In response to the blockchain virtual resource transfer request, generating a blockchain account for storing the blockchain virtual resource;
[0007] Determine the virtual resource of the transferor that is requested to be transferred, and initiate a resource transfer request to transfer the virtual resource of the transferor to the blockchain account;
[0008] When the resource transfer request is responded to by the on-chain processing node and the virtual resources of the transferor are transferred to the blockchain account, resource collection information is generated; the resource collection information is used to instruct the resource recipient to collect at least a part of the virtual resources of the transferor from the blockchain account.
[0009] In a second aspect, the present application provides a blockchain virtual resource transfer method. The method comprises:
[0010] Obtain resource collection information, and extract account information of the blockchain account from the resource collection information;
[0011] Based on the account information, a resource collection and on-chain request is initiated to collect the target virtual resource from the blockchain account; the target virtual resource includes at least a portion of the blockchain virtual resource stored in the blockchain account; the blockchain virtual resource is transferred from the resource transferor to the blockchain account by responding to the blockchain virtual resource transfer request;
[0012] When the resource collection on-chain request is responded to by the on-chain processing node, the target virtual resource transferred from the blockchain account is received.
[0013] In a third aspect, the present application provides a blockchain system. The system includes a resource transferor, a resource recipient, and an on-chain processing node;
[0014] The resource transferor generates a blockchain account for storing blockchain virtual resources in response to the blockchain virtual resource transfer request, determines the transferor virtual resources requested to be transferred, and initiates a resource transfer request to transfer the transferor virtual resources to the blockchain account;
[0015] The on-chain processing node responds to the resource transfer-out on-chain request and transfers the transferor virtual resource to the blockchain account;
[0016] The resource transferor generates resource collection information when the virtual resource of the transferor is transferred to the blockchain account;
[0017] The resource recipient obtains the resource collection information, extracts the account information of the blockchain account from the resource collection information, and initiates a resource collection and on-chain request to collect the target virtual resource from the blockchain account based on the account information; the target virtual resource includes at least a part of the virtual resources stored in the blockchain account;
[0018] The on-chain processing node responds to the resource collection on-chain request and transfers the target virtual resource from the blockchain account;
[0019] The resource recipient receives the target virtual resource transferred from the blockchain account.
[0020] In a fourth aspect, the present application provides a blockchain virtual resource transfer device. The device comprises:
[0021] A blockchain account generation module, used to generate a blockchain account for storing blockchain virtual resources in response to a blockchain virtual resource transfer request;
[0022] A resource transfer-out on-chain request initiating module, used to determine the transferor virtual resource requested to be transferred, and initiate a resource transfer-out on-chain request to transfer the transferor virtual resource to the blockchain account;
[0023] A resource collection information generation module is used to generate resource collection information when the resource transfer request is responded to by the chain processing node and the transferor's virtual resources are transferred to the blockchain account; the resource collection information is used to instruct the resource recipient to collect at least a part of the transferor's virtual resources from the blockchain account.
[0024] In a fifth aspect, the present application provides a blockchain virtual resource transfer device. The device includes:
[0025] An information extraction module, used to obtain resource collection information and extract account information of a blockchain account from the resource collection information;
[0026] A resource collection on-chain request initiating module, used to initiate a resource collection on-chain request for collecting a target virtual resource from the blockchain account based on the account information; the target virtual resource includes at least a portion of the blockchain virtual resource stored in the blockchain account; the blockchain virtual resource is transferred from the resource transferor to the blockchain account by responding to the blockchain virtual resource transfer request;
[0027] The virtual resource receiving module is used to receive the target virtual resource transferred from the blockchain account when the resource collection on-chain request is responded to by the on-chain processing node.
[0028] In a sixth aspect, the present application provides a computer device. The computer device includes a memory and a processor, the memory stores a computer program, and the processor implements the steps of the following method when executing the computer program:
[0029] In response to the blockchain virtual resource transfer request, generating a blockchain account for storing the blockchain virtual resource;
[0030] Determine the virtual resource of the transferor that is requested to be transferred, and initiate a resource transfer request to transfer the virtual resource of the transferor to the blockchain account;
[0031] When the resource transfer request is responded to by the on-chain processing node and the virtual resources of the transferor are transferred to the blockchain account, resource collection information is generated; the resource collection information is used to instruct the resource recipient to collect at least a part of the virtual resources of the transferor from the blockchain account.
[0032] In a seventh aspect, the present application further provides a computer device. The computer device includes a memory and a processor, the memory stores a computer program, and the processor implements the steps of the following method when executing the computer program:
[0033] Obtain resource collection information, and extract account information of the blockchain account from the resource collection information;
[0034] Based on the account information, a resource collection and on-chain request is initiated to collect the target virtual resource from the blockchain account; the target virtual resource includes at least a portion of the blockchain virtual resource stored in the blockchain account; the blockchain virtual resource is transferred from the resource transferor to the blockchain account by responding to the blockchain virtual resource transfer request;
[0035] When the resource collection on-chain request is responded to by the on-chain processing node, the target virtual resource transferred from the blockchain account is received.
[0036] In an eighth aspect, the present application provides a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the following method are implemented:
[0037] In response to the blockchain virtual resource transfer request, generating a blockchain account for storing the blockchain virtual resource;
[0038] Determine the virtual resource of the transferor requested to be transferred, and initiate a resource transfer request to transfer the virtual resource of the transferor to the blockchain account;
[0039] When the resource transfer request is responded to by the on-chain processing node and the virtual resources of the transferor are transferred to the blockchain account, resource collection information is generated; the resource collection information is used to instruct the resource recipient to collect at least a part of the virtual resources of the transferor from the blockchain account.
[0040] In a ninth aspect, the present application further provides a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the following method are implemented:
[0041] Obtain resource collection information, and extract account information of the blockchain account from the resource collection information;
[0042] Based on the account information, a resource collection and on-chain request is initiated to collect the target virtual resource from the blockchain account; the target virtual resource includes at least a portion of the blockchain virtual resource stored in the blockchain account; the blockchain virtual resource is transferred from the resource transferor to the blockchain account by responding to the blockchain virtual resource transfer request;
[0043] When the resource collection on-chain request is responded to by the on-chain processing node, the target virtual resource transferred from the blockchain account is received.
[0044] In a tenth aspect, the present application provides a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, the steps of the following method are implemented:
[0045] In response to the blockchain virtual resource transfer request, generating a blockchain account for storing the blockchain virtual resource;
[0046] Determine the virtual resource of the transferor that is requested to be transferred, and initiate a resource transfer request to transfer the virtual resource of the transferor to the blockchain account;
[0047] When the resource transfer request is responded to by the on-chain processing node and the virtual resources of the transferor are transferred to the blockchain account, resource collection information is generated; the resource collection information is used to instruct the resource recipient to collect at least a part of the virtual resources of the transferor from the blockchain account.
[0048] In an eleventh aspect, the present application provides a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, the steps of the following method are implemented:
[0049] Obtain resource collection information, and extract account information of the blockchain account from the resource collection information;
[0050] Based on the account information, a resource collection and on-chain request is initiated to collect the target virtual resource from the blockchain account; the target virtual resource includes at least a portion of the blockchain virtual resource stored in the blockchain account; the blockchain virtual resource is transferred from the resource transferor to the blockchain account by responding to the blockchain virtual resource transfer request;
[0051] When the resource collection on-chain request is responded to by the on-chain processing node, the target virtual resource transferred from the blockchain account is received.
[0052] The above-mentioned blockchain virtual resource transfer method, device, blockchain system, computer equipment, computer-readable storage medium and computer program product generate a blockchain account for storing blockchain virtual resources in response to a blockchain virtual resource transfer request; determine the transferor virtual resources requested to be transferred, and initiate a resource transfer request to transfer the transferor virtual resources to the blockchain account; when the resource transfer request is responded to by the chain processing node and the transferor virtual resources are transferred to the blockchain account, resource collection information is generated; the resource collection information is used to instruct the resource recipient to collect at least a part of the transferor virtual resources from the blockchain account. By adopting the above-mentioned method, the transfer of blockchain virtual resources can be realized through the generated blockchain account, so that the resource transferor does not need to obtain the recipient account information in advance, nor does it need to interact directly with the resource recipient, which can avoid the leakage of the recipient account information and is conducive to improving security. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] Figure 1 It is an application environment diagram of the blockchain virtual resource transfer method in some embodiments;
[0054] Figure 2 A flowchart of a blockchain virtual resource transfer method in some embodiments;
[0055] Figure 3 A schematic diagram of a process for determining character encoding information in some embodiments;
[0056] Figure 4 A flowchart of a blockchain virtual resource transfer method in some other embodiments;
[0057] Figure 5 A schematic diagram of the process of initiating a resource collection and uplinking request in some embodiments;
[0058] Figure 6 A flowchart of a blockchain virtual resource transfer method in some other embodiments;
[0059] Figure 7 A schematic diagram of the interactive process of blockchain virtual resource transfer in some embodiments;
[0060] Figure 8 A schematic diagram of the interactive process of blockchain virtual resource transfer in other embodiments;
[0061] Fig. 9 A schematic diagram of the composition of a blockchain system in some embodiments;
[0062] Fig.10 It is a structural block diagram of a blockchain virtual resource transfer device in some embodiments;
[0063] Fig.11It is a structural block diagram of a blockchain virtual resource transfer device in some other embodiments;
[0064] Fig.12 is an internal structure diagram of a computer device in some embodiments;
[0065] Fig.13 1 is a diagram of the internal structure of a computer device in some other embodiments. DETAILED DESCRIPTION
[0066] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0067] Before going into detail, some terms involved in this application are explained first.
[0068] Blockchain is a new application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, encryption algorithm, etc. Blockchain is essentially a decentralized database, a string of data blocks generated by cryptographic methods. Each data block contains a batch of network transaction information, which is used to verify the validity of its information (anti-counterfeiting) and generate the next block. Blockchain can include the underlying blockchain platform, platform product service layer, and application service layer.
[0069] Smart contracts are codes developed by the business side that can execute business logic, developed using programming languages, and deployed on the blockchain. When a user wants to call a smart contract, a blockchain transaction is generated and sent to the chain. Each blockchain node can package the transaction with consensus, execute the same code logic, and produce the same results. The code is open, transparent, and visible on the chain, ensuring that it cannot be tampered with. Once a smart contract is successfully deployed, it cannot be modified and exists permanently on the chain.
[0070] The blockchain virtual resource method provided in the embodiment of the present application can be applied to a data sharing system. Among them, the data sharing system refers to a system for sharing data between nodes, and the data sharing system may include multiple nodes, and the multiple nodes may refer to each client in the data sharing system. In the embodiment of the present application, the node may specifically include a resource transferor node, a resource recipient node, an on-chain processing node, etc. Each node can receive input information when performing normal work, and maintain the shared data in the data sharing system based on the received input information. In order to ensure the information intercommunication within the data sharing system, there may be an information connection between each node in the data sharing system, and the nodes can transmit information through the above-mentioned information connection. For example, when any node in the data sharing system receives input information, other nodes in the data sharing system obtain the input information according to the consensus algorithm, and store the input information as data in the shared data, so that the data stored on all nodes in the data sharing system are consistent.
[0071] Each node in the data sharing system has a corresponding node identifier, and each node in the data sharing system can store the node identifiers of other nodes in the data sharing system, so that the generated blocks can be broadcast to other nodes in the data sharing system according to the node identifiers of other nodes. A node identifier list can be maintained in each node, and the node name and node identifier are stored in the node identifier list accordingly. The node identifier can be an IP (Internet Protocol, a protocol for interconnecting networks) address and any other information that can be used to identify the node.
[0072] The above is the routing function of the node. In addition, the node can also realize the wallet function. The wallet is used to realize the circulation of virtual resources, including initiating transactions, storing transaction records in temporary blocks of the blockchain, and querying the remaining virtual resources in the virtual resource account. On the blockchain, there are two main types of virtual resources on the chain. One is the native virtual resources generated by the on-chain processing node packaging and producing blocks, and the other is uploading data to the chain through smart contracts. This data can be called virtual resources on the blockchain, that is, non-native virtual resources. Common non-native virtual resource application protocols include ERC20, ERC721 and ERC1155. Specifically, each node can have a virtual resource account corresponding to it, and the node identifier corresponds to the virtual resource account one by one. The nodes can realize the circulation of resources between different virtual resource accounts based on the node identifier.
[0073] The blockchain virtual resource transfer method provided in this application can be applied to Figure 1In the application environment shown. The application environment includes a resource transferor 101, an on-chain processing node 102 and a resource recipient 103, the three of which can communicate over the network and realize consensus, data recording and on-chain functions in blockchain technology based on smart contracts. Among them, in the process of implementing the blockchain virtual resource transfer method, the resource transferor 101: responds to a blockchain virtual resource transfer request, generates a blockchain account for storing blockchain virtual resources; determines the transferor virtual resource requested to be transferred, and initiates a resource transfer on-chain request to transfer the transferor virtual resource to the blockchain account; when the resource transfer on-chain request is responded to by the on-chain processing node 102, and the transferor virtual resource is transferred to the blockchain account, resource collection information is generated; the resource collection information is used to instruct the resource recipient 103 to collect at least a portion of the transferor virtual resource from the blockchain account. In the process of receiving virtual resources from a blockchain account, the resource recipient 103 obtains resource collection information and extracts the account information of the blockchain account from the resource collection information; based on the account information, initiates a resource collection on-chain request to collect the target virtual resources from the blockchain account; the target virtual resources include at least a portion of the blockchain virtual resources stored in the blockchain account; and when the resource collection on-chain request is responded to by the on-chain processing node 102, receives the target virtual resources transferred from the blockchain account.
[0074] Furthermore, the resource transferor 101, the on-chain processing node 102 and the resource recipient 103 can all be implemented through a terminal or a server, and the on-chain processing node 102 that responds to the resource transfer on-chain request and the resource collection on-chain request can be the same node in the blockchain system or different nodes. Furthermore, the terminal includes but is not limited to mobile phones, computers, intelligent voice interaction devices, smart home appliances, vehicle terminals, aircraft, etc., and the server can be implemented with an independent server or a server cluster composed of multiple servers. The embodiments of the present invention can be applied to various scenarios, including but not limited to cloud technology, artificial intelligence, smart transportation, assisted driving, etc.
[0075] In one embodiment, the present application also provides an application scenario for applying the above-mentioned blockchain virtual resource transfer method, which application scenario can be, for example, a commodity promotion activity scenario. In this application scenario, the resource transferor can correspond to the merchant, and the resource recipient can correspond to the consumer. Specifically, the resource transferor responds to the blockchain virtual resource transfer request initiated by the merchant, generates a blockchain account for storing blockchain virtual resources, determines the transferor virtual resources requested to be transferred, and initiates a resource transfer request to transfer the transferor virtual resources to the blockchain account. The transferor virtual resources can be, for example, coupons, gift cards, etc. Then, the on-chain processing node responds to the resource transfer request to transfer the transferor virtual resources to the blockchain account. Next, the resource transferor generates resource collection information when the transferor virtual resources are transferred to the blockchain account. In the process of collecting the virtual resources of the blockchain account, the resource recipient obtains the resource collection information, extracts the account information of the blockchain account from the resource collection information, and initiates a resource collection request to collect the target virtual resources from the blockchain account based on the account information. The target virtual resources include at least a portion of the virtual resources stored in the blockchain account. Then, the on-chain processing node responds to the resource collection on-chain request and transfers the target virtual resource from the blockchain account. Finally, the resource recipient receives the target virtual resource transferred from the blockchain account. In this way, the transferor's virtual resources such as coupons and gift cards can be transferred from the merchant to the consumer without the need for direct interaction between the merchant and the consumer, which can reduce the risk of leakage of the transferor's account and the recipient's account, and is conducive to improving the security of the blockchain virtual resource transfer process.
[0076] In one embodiment, the blockchain virtual resource transfer method provided by the present application can also be applied to game promotion scenarios. In this application scenario, the resource transferor can correspond to the game developer, and the resource recipient can correspond to the game player. Specifically, the resource transferor responds to the blockchain virtual resource transfer request initiated by the merchant, generates a blockchain account for storing blockchain virtual resources, determines the transferor virtual resources requested to be transferred, and initiates a resource transfer request to transfer the transferor virtual resources to the blockchain account. The transferor virtual resources can be, for example, game props, character skins, etc. Then, the on-chain processing node responds to the resource transfer request to transfer the transferor virtual resources to the blockchain account. Next, the resource transferor generates resource collection information when the transferor virtual resources are transferred to the blockchain account. In the process of collecting the virtual resources of the blockchain account, the resource recipient obtains the resource collection information, extracts the account information of the blockchain account from the resource collection information, and initiates a resource collection request to collect the target virtual resources from the blockchain account based on the account information. The target virtual resources include at least a portion of the virtual resources stored in the blockchain account. Then, the on-chain processing node responds to the resource collection on-chain request and transfers the target virtual resource from the blockchain account. Finally, the resource recipient receives the target virtual resource transferred from the blockchain account. In this way, the game props, character skins and other virtual resources of the transferor can be transferred from the game developer to the game player without the need for direct interaction between the game developer and the game player, which can reduce the risk of leakage of the transferor account and the recipient account, and is conducive to improving the security of the blockchain virtual resource transfer process.
[0077] In some embodiments, Figure 2 As shown, a blockchain virtual resource transfer method is provided. This embodiment applies the method to Figure 1 Taking the resource transferor 101 in the example as an example, the following steps are included:
[0078] Step S202: In response to the blockchain virtual resource transfer request, a blockchain account for storing blockchain virtual resources is generated.
[0079] Among them, blockchain virtual resources refer to digital assets circulated on the blockchain, which can also be called on-chain assets, including native virtual resources generated by packaging blocks through on-chain processing nodes, and on-chain data released through smart contracts. The on-chain data can include, for example, game props, digital goods, product coupons, etc. The blockchain account is used to store blockchain virtual resources, and the blockchain account can be represented by the blockchain address corresponding to the blockchain account. In other words, on the blockchain, each blockchain address can correspond to a different blockchain account.
[0080] Specifically, a user can trigger a blockchain virtual resource transfer request through an operation. The operation can be, for example, an information input operation, a click operation, and the like. Exemplarily, a user can click on the resource transfer control of the resource transferor to trigger a blockchain virtual resource transfer request; or a blockchain virtual resource transfer request can be triggered by inputting the virtual resource operation type and operation number to the resource transferor, and when the operation type is transfer-out. The operation number is used to indicate the amount of resources requested for the operation. In response to the blockchain virtual resource transfer request, the resource transferor generates a blockchain account for storing blockchain virtual resources.
[0081] Step S204: determine the virtual resource of the transferor that is requested to be transferred, and initiate a resource transfer request to transfer the virtual resource of the transferor to the blockchain account.
[0082] Among them, the source of the transferor's virtual resources is the resource transferor; the transferor's virtual resources requested to be transferred are the transfer objects in the blockchain virtual resource transfer process. It can be understood that the resource transferor has a corresponding transferor account, which is used to store the blockchain virtual resources held by the transferor. The on-chain request is a request to put a business transaction on the chain. Business transactions include transactions that need to be implemented by calling smart contracts deployed by the blockchain system. In the blockchain, transactions are equivalent to events, and business transactions refer to events that implement business, which may include at least one of data storage, data authentication, data update or data query. Specifically for this application, the resource transfer on-chain request refers to a request to implement the resource transfer business on the chain, which belongs to a data update task, and the data that needs to be updated is the amount of virtual resources owned by each blockchain account. In the blockchain system, only transactions that are packaged on the chain can be executed, and the operation of packaging on the chain can be specifically performed by the on-chain processing node.
[0083] During the application process, the resource transferor can determine the virtual resource of the transferor to be transferred based on the blockchain virtual resource transfer request. Exemplarily, the blockchain virtual resource transfer request can carry the amount of resources requested to be transferred, and then the resource transferor can extract the amount of resources requested to be transferred from the blockchain virtual resource transfer request, and determine the virtual resource of the transferor that matches the amount of resources and is requested to be transferred. After determining the virtual resource of the transferor to be transferred, the resource transferor initiates a resource transfer request to transfer the virtual resource of the transferor to the blockchain account, and broadcasts the resource transfer request to the blockchain system's on-chain processing node.
[0084] Furthermore, since the on-chain processing node needs to consume its own computing resources during the process of packaging and chaining operations, the party initiating the on-chain request usually needs to transfer virtual resources that match the computing resources to the on-chain processing node to motivate the on-chain processing node to consume its own computing resources for on-chain processing. Specifically, the resource transferor can estimate the amount of virtual resources required for the resource transfer on-chain request to be initiated based on the resource consumption of each of the historical resource transfer on-chain requests that have been responded to, and generate a resource transfer on-chain request carrying the virtual resource amount; it can also obtain the current transaction volume of the blockchain system, and based on the current transaction volume, estimate the amount of virtual resources required for the resource transfer on-chain request to be initiated, and generate a resource transfer on-chain request carrying the virtual resource amount. Among them, the amount of virtual resources is positively correlated with the current transaction volume. The larger the current transaction volume, the busier the on-chain processing node is, and the more computing resources are required to process the resource transfer on-chain request.
[0085] Step S206: When the resource transfer request is responded to by the on-chain processing node and the virtual resources of the transferor are transferred to the blockchain account, resource collection information is generated.
[0086] The resource collection information may specifically include at least one of image information, character information, etc. The image information may include, for example, coded information such as a barcode or a QR code, or may include non-coded information such as a shape or a pattern. In a specific embodiment, the resource collection information may be a QR code, which may be associated with a variety of data information through coding.
[0087] Specifically, after the resource transferor initiates a resource transfer request on the chain, it waits for the response of the chain processing node. When the chain processing node responds to the resource transfer request on the chain, packages the resource transfer request on the chain, and transfers the virtual resources of the transferor to the blockchain account through the consensus mechanism, the resource transferor generates resource collection information. The resource collection information is used to instruct the resource recipient to collect at least a part of the virtual resources of the transferor from the blockchain account. The resource collection information is associated with the account information of the blockchain account and the resource information of the virtual resources of the transferor. In some embodiments, the resource collection information can also be associated with configuration information related to the collection rules. For example, the amount of virtual resources collected, the type of resources collected, whether multiple collections are supported, and so on.
[0088] Furthermore, the resource recipient can obtain resource collection information, extract the account information of the blockchain account from the resource collection information, and then, based on the account information, initiate a resource collection on-chain request to collect the target virtual resource from the blockchain account, and receive the target virtual resource transferred from the blockchain account when the resource collection on-chain request is responded to by the on-chain processing node. The target virtual resource includes at least a portion of the blockchain virtual resources stored in the blockchain account.
[0089] The above blockchain virtual resource transfer method generates a blockchain account for storing blockchain virtual resources in response to a blockchain virtual resource transfer request; determines the virtual resources of the transferor requested to be transferred, and initiates a resource transfer request to transfer the virtual resources of the transferor to the blockchain account; when the resource transfer request is responded to by the chain processing node and the virtual resources of the transferor are transferred to the blockchain account, resource collection information is generated; the resource collection information is used to instruct the resource recipient to collect at least a part of the virtual resources of the transferor from the blockchain account. By adopting the above method, the transfer of blockchain virtual resources can be realized through the generated blockchain account, so that the resource transferor does not need to obtain the account information of the recipient in advance, nor does it need to interact directly with the resource recipient, which can avoid the leakage of the account information of the recipient and is conducive to improving security.
[0090] It should be noted that the specific method for the resource transferor to generate a blockchain account is not unique. For example, the resource transferor can obtain an unoccupied available blockchain address in the blockchain system, decode the available blockchain address, obtain an account key matching the available blockchain address, and then generate a blockchain account corresponding to the available blockchain address, which is managed by the account key.
[0091] In one embodiment, step S202 includes: generating an account public key and an account private key in response to a blockchain virtual resource transfer request; encoding the account public key to obtain an encoded address; determining a target blockchain address that matches the encoded address from available blockchain addresses, and generating a blockchain account corresponding to the target blockchain address.
[0092] Among them, the blockchain account is used to store blockchain virtual resources, and the blockchain account is managed based on the account private key. The account public key and the account private key together constitute the account public and private key pair. Specifically, the resource transferor can generate the account public key and the account private key in response to the blockchain virtual resource transfer request. Furthermore, the resource transferor can randomly generate the account public key and the account private key, or generate the account public key and the account private key based on an encryption algorithm. The encryption algorithm may include, for example, a hash algorithm or an RSA algorithm, etc., which is not limited here.
[0093] Then, the resource transferor can encode the account public key to obtain the encoded address on the one hand; on the other hand, it can determine the available blockchain address that is not occupied in the blockchain system according to the address usage of the blockchain system. Then, the resource transferor determines the target blockchain address that matches the encoded address from the available blockchain addresses, and generates a blockchain account corresponding to the target blockchain address. Among them, the address consists of a series of characters, that is, the target blockchain address and the encoded address can both be represented as strings. The target blockchain address matches the encoded address, which means that the string similarity between the target blockchain address and the encoded address is the highest among the available blockchain addresses. The string similarity can be characterized by the edit distance or the Hamming distance. The edit distance refers to the minimum number of editing operations required to convert one string into another between two strings. The editing operation in the conversion process may include at least one of replacing one character with another, inserting a character, or deleting a character.
[0094] In a specific embodiment, the resource transferor can generate an account public-private key pair including an account public key and an account private key, and use a hash algorithm and the account public key to derive a public key hash value as the blockchain address of the blockchain account. The private key in the account public-private key pair is the ownership certificate of the blockchain address. Only the holder who holds the private key can manage the blockchain virtual resources in the blockchain address. By using the blockchain address, the owner of the blockchain virtual resource can safely store his assets without trusting a third party.
[0095] In the above embodiment, by encoding the account public key to obtain the encoded address, determining the target blockchain address from the available blockchain addresses, and generating a blockchain account corresponding to the target blockchain address, it can be ensured that the generated blockchain account corresponds one-to-one with the resource transferor, which is beneficial to improving the reliability of the blockchain virtual resource transfer process implemented based on the blockchain.
[0096] In one embodiment, the blockchain virtual resource transfer method further includes: determining the on-chain consumable resources required to collect the transferor virtual resources. In the case of this embodiment, initiating a resource transfer-out on-chain request to transfer the transferor virtual resources to the blockchain account includes: initiating a resource transfer-out on-chain request to transfer the transferor virtual resources and on-chain consumable resources to the blockchain account.
[0097] Among them, the sources of the resources consumed on the chain and the virtual resources of the transferor are the same. As mentioned above, since the chain processing node needs to consume its own computing resources in the process of packaging and chaining operations, the party initiating the chain request usually needs to transfer virtual resources that match the computing resources to the chain processing node to motivate the chain processing node to consume its own computing resources for chain processing. For the resource recipient, it is necessary to obtain the target virtual resources from the blockchain account by initiating a resource collection chain request. The chain processing node also needs to consume its own computing resources in response to the resource collection chain request. In this case, the chain consumption resources required to collect the transferor's virtual resources are the virtual resources that need to be paid to the chain processing node in the process of collecting the transferor's virtual resources. It can be understood that if the virtual resources of the transferor are collected by the resource recipient once, the resource recipient initiates an on-chain request to collect the virtual resources of the transferor. The on-chain consumed resources refer to the virtual resources that need to be paid to the on-chain processing node after the on-chain request for resource collection is responded to by the on-chain processing node; if the virtual resources of the transferor are split into multiple target virtual resources and collected in multiple times, the on-chain consumed resources refer to the sum of the virtual resources that need to be paid to the on-chain processing node for each collection.
[0098] Specifically, the resource transferor can determine the on-chain consumption resources required to collect the transferor's virtual resources based on the amount of resources of the transferor's virtual resources. The resource transferor can also determine the on-chain consumption resources required to collect the transferor's virtual resources based on the amount of resources of the transferor's virtual resources and the configured number of resource collections. The larger the amount of resources of the transferor's virtual resources and the more times the resources are collected, the more on-chain consumption resources need to be paid during the resource collection process. Then, the resource transferor initiates a resource transfer on-chain request to transfer the transferor's virtual resources and on-chain consumption resources to the blockchain account.
[0099] In the above embodiment, when the resource transferor transfers the transferor's resources to the blockchain account, it also transfers the on-chain consumable resources required to receive the transferor's resources. In this way, the resource recipient does not need to pay transaction fees when receiving virtual resources, which can lower the threshold for resource collection and improve the efficiency of virtual resource transfer.
[0100] In one embodiment, generating resource collection information includes: obtaining account information of a blockchain account, and determining contract information of a smart contract required to be called to collect at least a portion of the transferor's virtual resources; performing character encoding processing on the account information and the contract information to obtain character encoding information; and performing image encoding processing on the character encoding information to obtain resource collection information.
[0101] Among them, the account information of the blockchain account may include at least one of the blockchain identifier of the blockchain where the blockchain account is located, the address of the blockchain account, and the account private key for managing the blockchain account. In practical applications, business transactions of the blockchain system need to be implemented by calling smart contracts, and so do virtual resource collection transactions. Specifically, the resource transferor obtains the account information of the blockchain account and determines the contract information of the smart contract required to collect at least a part of the virtual resources of the transferor. The contract information may include the contract standard and the contract address, etc. Then, the resource transferor performs character encoding processing on the account information and the contract information to obtain the character encoding information. The specific algorithm of the character encoding processing may be, for example, Unicode, ASCII (American Standard Code for Information Interchange, American Standard Code for Information Interchange) and other algorithms. Finally, the resource transferor performs image encoding processing on the character encoding information based on the set image encoding rules to obtain the resource collection information. It can be understood that the resource collection information obtained after the image encoding processing is image information. Taking the case where the resource collection information is a QR code as an example, the resource collection information may be, for example, a stacked QR code or a matrix QR code.
[0102] In the above embodiment, character encoding processing is performed first and then image encoding processing is performed to obtain resource collection information in image form, which can increase the data capacity of the resource collection information.
[0103] In one embodiment, the transferor virtual resource includes a plurality of candidate virtual resources. In the case of this embodiment, determining the contract information of the smart contract required to be called to obtain at least a portion of the transferor virtual resources includes: determining at least one target virtual resource from the plurality of candidate virtual resources; determining the contract information of the smart contract required to be called to obtain each target virtual resource. Performing character encoding processing on the account information and the contract information to obtain character encoding information includes: performing character encoding processing on the account information and each contract information to obtain character encoding information.
[0104] Specifically, the resource transferor can transfer multiple candidate virtual resources to the blockchain account, and each candidate virtual resource together constitutes the transferor virtual resource transferred from the resource transferor to the blockchain account. Exemplarily, in the game scenario, the resource transferor can transfer multiple game props to the blockchain account, and each game prop is a candidate virtual resource; in the commodity promotion activity scenario, the resource transferor can transfer multiple commodity coupons to the blockchain account, and each commodity coupon is a candidate virtual resource. It can be understood that for a blockchain account containing multiple candidate virtual resources, multiple resource collection information can be generated, and each resource collection information corresponds to a different target virtual resource. For example, in the case where the blockchain account includes game props A, game props B, and game props C, resource collection information A for collecting game props A, resource collection information B for collecting game props B, and resource collection information C for collecting game props C can be generated; resource collection information A for collecting game props A, and resource collection information D for collecting game props B and game props C can also be generated.
[0105] Based on this, in the process of generating resource collection information, the resource transferor can determine at least one target virtual resource from each candidate virtual resource, and determine the contract information of the smart contract that needs to be called to collect each target virtual resource. Exemplarily, the user can input resource collection configuration information to the resource transferor to determine each corresponding candidate virtual resource, and the resource transferor determines the number of resource collection information to be generated and the target virtual resource corresponding to each resource collection information according to the resource collection configuration information. Then, the resource transferor performs character encoding processing on the account information and each contract information to obtain character encoding information. Further, the resource transferor can perform character encoding processing on the account information and contract information corresponding to each target virtual resource respectively, obtain multiple sub-encoding information, and then combine each sub-encoding information by splicing, statistical calculation, etc. to obtain the character encoding information corresponding to each target virtual resource. The resource transferor can also jointly encode the account information and each contract information, so that the character encoding information corresponding to each target virtual resource can be obtained by only encoding the account information once.
[0106] For example, Figure 3As shown, the virtual resources of the transferor transferred to the blockchain account include candidate virtual resources 1 to candidate virtual resources N. In the process of generating resource collection information, the resource transferor first determines the target virtual resources from each candidate virtual resource, specifically including target virtual resource 1 and target virtual resource 2. Then, the resource transferor determines the contract information of the smart contract that needs to be called to collect each target virtual resource. For example, the smart contract 1 and contract information 1 required to collect the target virtual resource 1, and the smart contract 2 and contract information 2 required to collect the target virtual resource 2. Finally, the resource transferor performs character encoding processing on the account information of the blockchain account, as well as contract information 1 and contract information 2, to obtain character encoding information.
[0107] In the above embodiment, the contract information corresponding to at least one target virtual resource is character encoded to obtain character encoding information, so that the resource collection information determined based on the character encoding information can correspond to multiple target virtual resources, which is conducive to improving the efficiency of virtual resource transfer.
[0108] In one embodiment, the blockchain virtual resource transfer method also includes: in response to a resource collection configuration request, obtaining resource collection configuration information for a blockchain account; based on the resource collection configuration information, deploying a smart contract required to collect at least a portion of the transferor's virtual resources.
[0109] Among them, the resource collection configuration information is used to configure the collection method of the transferor's virtual resources, which may specifically include the number of collections and the amount of resources collected in a single collection. The number of collections may be, for example, one or more times. In the process of multiple collections, the amount of resources collected each time may be random or a set amount. Exemplarily, taking the threshold-free coupons for commodities as an example, the transferor's virtual resources transferred to the blockchain account include threshold-free coupons with a total amount of A, then the collection method may be multiple collections, and the amount of coupons collected each time is the same. For example, the total number of collections is 10 times, and the amount collected each time is A / 10.
[0110] Specifically, the resource transferor can respond to the resource collection configuration request, obtain the resource collection configuration information for the blockchain account input by the user, and then, based on the resource collection configuration information, deploy the smart contract required to collect at least a part of the virtual resources of the transferor. It can be understood that different collection methods require different smart contracts to be configured. If multiple collections are made and the amount of coupons collected each time is the same, the resource transferor only needs to deploy one smart contract. If the amount of coupons collected each time is different, the resource transferor needs to deploy the corresponding smart contract for each amount.
[0111] In the above embodiment, based on the resource collection configuration information, the smart contract required to be called in the virtual resource collection process is deployed, which can adapt to the usage requirements in various virtual resource transfer scenarios, and is conducive to improving the flexibility of the blockchain virtual resource transfer method.
[0112] In some embodiments, Figure 4 As shown, a blockchain virtual resource transfer method is provided. This embodiment applies the method to Figure 1 Taking the resource recipient 103 in the example as an example, the following steps are included:
[0113] Step S402, obtaining resource collection information, and extracting account information of the blockchain account from the resource collection information.
[0114] Among them, the specific limitations on resource collection information can be found above and will not be repeated here. The account information of a blockchain account may include at least one of the blockchain identifier of the blockchain where the blockchain account is located, the address of the blockchain account, and the account private key for managing the blockchain account. Specifically, after the resource transferor generates the resource collection information, the generated resource collection information can be posted offline or online. Taking the case where the resource collection information is a QR code as an example, the resource transferor can print the generated QR code on a gift card. When the resource recipient obtains a gift card, he can scan the QR code on the gift card and extract the account information of the blockchain account from the QR code.
[0115] In a specific embodiment, the blockchain virtual resource transfer method also includes: obtaining blockchain information, extracting an information type identifier from the blockchain information, and determining that the blockchain information is resource collection information when the information type represented by the information type identifier is a resource collection type.
[0116] Specifically, blockchain information is obtained based on a coding protocol, and the coding protocol used in the blockchain system usually includes a protocol prefix indicating the information type, which can be used as an information type identifier. The information type may include, for example, a resource collection type, a resource issuance type, and so on. Exemplarily, the protocol prefix for resource collection is fixed to "receive_token", so that when the resource recipient obtains blockchain information, it can first read the information type identifier, and then perform subsequent resource collection operations when it is determined that the blockchain information is resource collection information based on the information type identifier.
[0117] Step S404: Based on the account information, a resource collection request is initiated to collect the target virtual resource from the blockchain account.
[0118] The target virtual resource includes at least a portion of the blockchain virtual resource stored in the blockchain account; the blockchain virtual resource is transferred from the resource transferor to the blockchain account by responding to the blockchain virtual resource transfer request. As mentioned above, in the blockchain system, only transactions that are packaged and uploaded to the chain can be executed, and the operation of packaging and uploading to the chain can be specifically performed by the uploading processing node. Specifically, the resource recipient can initiate a resource collection and uploading request to collect the target virtual resource from the blockchain account based on the account information.
[0119] Furthermore, since the on-chain processing node needs to consume its own computing resources during the process of packaging and chaining operations, the party initiating the on-chain request usually needs to transfer virtual resources that match the computing resources to the on-chain processing node to motivate the on-chain processing node to consume its own computing resources for on-chain processing. Specifically, similar to the resource transfer on-chain request, the resource recipient can estimate the amount of virtual resources required for the resource collection on-chain request to be initiated based on the resource consumption of each of the resource collection on-chain requests that have been responded to, and generate a resource collection on-chain request carrying the virtual resource amount; it can also obtain the current transaction volume of the blockchain system, and based on the current transaction volume, estimate the amount of virtual resources required for the resource collection on-chain request to be initiated, and generate a resource collection on-chain request carrying the virtual resource amount. Among them, the amount of virtual resources is positively correlated with the current transaction volume. The larger the current transaction volume, the busier the on-chain processing node is, and the more computing resources are consumed to process the resource collection on-chain request. In the process of resource collection, virtual resources matching the computing resources can be transferred from the blockchain account or the recipient's account to the on-chain processing node.
[0120] Step S406, when the resource collection on-chain request is responded to by the on-chain processing node, the target virtual resource transferred from the blockchain account is received.
[0121] Specifically, after the resource recipient initiates a resource collection on-chain request, it waits for the response of the on-chain processing node. The on-chain processing node responds to the resource transfer request, packages the resource transfer request into a block, and transfers the target virtual resource from the blockchain account through consensus. The resource recipient receives the target virtual resource transferred from the blockchain account.
[0122] The above blockchain virtual resource transfer method obtains resource collection information, extracts the account information of the blockchain account from the resource collection information; based on the account information, initiates a resource collection on-chain request to collect the target virtual resource from the blockchain account; the target virtual resource includes at least a portion of the blockchain virtual resource stored in the blockchain account; the blockchain virtual resource is transferred from the resource transferor to the blockchain account in response to the blockchain virtual resource transfer request; when the resource collection on-chain request is responded to by the on-chain processing node, the target virtual resource transferred from the blockchain account is received. In the above blockchain virtual resource transfer process, the transfer of blockchain virtual resources can be realized through the blockchain account, so that the resource recipient does not need to obtain the transferor account information in advance, nor does it need to interact directly with the resource transferor, which can avoid the leakage of the transferor account information and is conducive to improving security.
[0123] In one embodiment, the blockchain virtual resource transfer method further includes: based on the account information, querying the blockchain account for the available transferor virtual resources. In the case of this embodiment, initiating a resource collection request to collect the target virtual resource from the blockchain account includes: initiating a resource collection request to collect the target virtual resource from the blockchain account when the available transferor virtual resources include the target virtual resource.
[0124] Among them, the virtual resources of the transferor transferred from the resource transferor to the blockchain account can be collected in multiple times. In addition, in order to improve the efficiency of resource transfer, the resource collection information can be repeatedly released for the same target virtual resource in the transferor virtual resources. Then, in actual applications, as part of the transferor virtual resources in the blockchain account are collected, the transferor virtual resources that can be collected will decrease accordingly; similarly, for the same target virtual resource, due to the repeated release of the resource collection information associated with it, there may be multiple resource recipients requesting to collect it. In this case, the target virtual resource can be frozen when the first resource recipient requests to collect it. Then, for the subsequent resource recipients who request to collect it, the target virtual resource is an uncollectable transferor virtual resource.
[0125] Based on this, after extracting the account information of the blockchain account from the resource collection information, the resource recipient can first query the transferor virtual resources that can be collected in the blockchain account based on the account information, and initiate a resource collection request to collect the target virtual resources from the blockchain account when the transferor virtual resources that can be collected include the target virtual resources. Among them, the transferor virtual resources that can be collected refer to virtual resources that exist in the blockchain account and are not frozen. It can be understood that if the transferor virtual resources that can be collected do not include the target virtual resources, it means that the target virtual resources have been collected by other resource recipients. In this case, the resource recipient ends the resource collection and does not initiate a resource collection request to collect the target virtual resources from the blockchain account.
[0126] In this embodiment, when the target virtual resources are included in the virtual resources that can be collected by the transferor, a resource collection request is initiated to collect the target virtual resources from the blockchain account, which can ensure the smooth collection of the target virtual resources and is conducive to improving the reliability of the blockchain virtual resource transfer process.
[0127] In one embodiment, the blockchain virtual resource transfer method further includes: based on the account information, querying the available on-chain consumable resources in the blockchain account. In the case of this embodiment, when the available transferor virtual resources include the target virtual resources, initiating a resource collection on-chain request to collect the target virtual resources from the blockchain account, including: when the available transferor virtual resources include the target virtual resources, determining the target on-chain consumable resources required to collect the target virtual resources; when the available on-chain consumable resources include the target on-chain consumable resources, initiating a resource collection on-chain request to collect the target virtual resources from the blockchain account.
[0128] Among them, the on-chain consumption resources are transferred from the resource transferor to the blockchain account, and are used to compensate for the computing resources consumed by the on-chain processing node during the virtual resource collection process of the transferor. In this embodiment, the resource transferor transfers the virtual resources of the transferor to the blockchain account, and at the same time, transfers the on-chain consumption resources required to collect the virtual resources of the transferor to the blockchain account. In this way, the resource recipient does not need to transfer the on-chain consumption resources from its own account to the on-chain processing node during the process of collecting the virtual resources of the transferor from the blockchain account, which can motivate the resource recipient to collect.
[0129] In actual applications, the virtual resources of the transferor transferred from the resource transferor to the blockchain account can be collected in multiple times, and each collection requires the payment of the corresponding on-chain consumption resources to the on-chain processing node. Since the on-chain consumption resources required to be paid for each collection are not fixed, and usually fluctuate within a certain range, there may be a situation where the on-chain consumption resources are insufficient. Based on this, after the resource recipient extracts the account information of the blockchain account from the resource collection information, it can query the available on-chain consumption resources in the blockchain account based on the account information. In the case where the transferor virtual resources that can be collected include the target virtual resources, the target on-chain consumption resources required to collect the target virtual resources are determined, and in the case where the available on-chain consumption resources include the target on-chain consumption resources, a resource collection on-chain request to collect the target virtual resources from the blockchain account is initiated. Among them, the method for determining the target on-chain consumption resources is similar to the method for determining the on-chain consumption resources in the above text, and will not be repeated here.
[0130] In a specific embodiment, Figure 5 As shown in the figure, the process of the resource recipient initiating a resource collection and on-chain request includes:
[0131] Step S501, querying the blockchain account for the transferor's virtual resources that can be collected;
[0132] Step S502, determining whether the available transferor virtual resources include the target virtual resources; if not, executing step S503; if yes, executing step S504;
[0133] Step S503, outputting abnormal prompt information;
[0134] Step S504, determining the target on-chain consumable resources required to obtain the target virtual resources;
[0135] Step S505, querying the available on-chain consumption resources in the blockchain account;
[0136] Step S506, determining whether the available uplink consumption resources include the target uplink consumption resources; if not, executing step S503; if yes, executing step S507;
[0137] Step S507, initiate a resource collection and chain request.
[0138] Specifically, during the resource collection process, the resource recipient can obtain resource collection information and extract the account information of the blockchain account from the resource collection information. After extracting the account information of the blockchain account, the resource recipient can first query the blockchain account for the transferor virtual resources that can be collected based on the account information. If the transferor virtual resources that can be collected include the target virtual resources, the target on-chain consumption resources required to collect the target virtual resources are further determined, and the available on-chain consumption resources in the blockchain account are queried. If the available on-chain consumption resources include the target on-chain consumption resources, a resource collection on-chain request to collect the target virtual resources from the blockchain account is initiated; if the available on-chain consumption resources do not include the target on-chain consumption resources, an abnormal prompt message is output, and the resource collection is terminated. Further, if the transferor virtual resources that can be collected do not include the target virtual resources, an abnormal prompt message is output, and the resource collection is terminated.
[0139] In the above embodiment, when the virtual resources that can be collected by the transferor include the target virtual resources, and the available on-chain consumable resources include the target on-chain consumable resources, a resource collection on-chain request is initiated. On the one hand, it can ensure the smooth progress of the resource collection process, and on the other hand, it can ensure that the resource recipient can collect the virtual resources without paying the on-chain fee, which can lower the threshold for resource collection and help improve the efficiency of virtual resource transfer.
[0140] In a specific embodiment, Figure 6 As shown, the blockchain virtual resource transfer method includes the following steps:
[0141] Step S601: The resource transferor generates an account public key and an account private key in response to a blockchain virtual resource transfer request;
[0142] Step S602: The resource transferor encodes the account public key to obtain an encoded address;
[0143] Step S603: The resource transferor determines a target blockchain address that matches the encoded address from the available blockchain addresses, and generates a blockchain account corresponding to the target blockchain address;
[0144] Among them, the blockchain account is used to store blockchain virtual resources, and the blockchain account is managed based on the account private key;
[0145] Step S604, the resource transferor determines the transferor virtual resource requested to be transferred, and the on-chain consumable resources required to obtain the transferor virtual resource;
[0146] Step S605: The resource transferor initiates a resource transfer request to transfer the transferor's virtual resources and on-chain consumable resources to the blockchain account;
[0147] Among them, the sources of the resources consumed on the chain and the virtual resources of the transferor are the same;
[0148] Step S606, when the resource transfer request is responded to by the on-chain processing node and the virtual resources of the transferor and the on-chain consumable resources are transferred to the blockchain account, the resource transferor obtains the account information of the blockchain account and determines the contract information of the smart contract required to be called to claim at least a part of the virtual resources of the transferor;
[0149] Step S607, the resource transferor performs character encoding processing on the account information and contract information to obtain character encoding information;
[0150] Step S608, the resource transferor performs image encoding processing on the character encoding information to obtain resource collection information;
[0151] The resource collection information is used to instruct the resource recipient to collect at least a portion of the virtual resources of the transferor from the blockchain account;
[0152] Step S609, the resource recipient obtains resource receipt information, and extracts account information of the blockchain account from the resource receipt information;
[0153] Step S610: The resource recipient queries the blockchain account for available virtual resources of the transferor and available consumable resources on the blockchain based on the account information.
[0154] Step S611, when the available transferor virtual resources include the target virtual resources, the resource recipient determines the target on-chain consumable resources required to obtain the target virtual resources;
[0155] Step S612: When the available on-chain consumable resources include the target on-chain consumable resources, the resource recipient initiates a resource collection on-chain request to collect the target virtual resources from the blockchain account;
[0156] Step S613, when the resource collection on-chain request is responded to by the on-chain processing node, the resource recipient receives the target virtual resource transferred from the blockchain account.
[0157] In the above blockchain virtual resource transfer process, the transfer of blockchain virtual resources can be realized through the generated blockchain account, so that in the process of transferring virtual resources, the resource transferor does not need to obtain the account information of the recipient in advance, nor does it need to interact directly with the resource recipient, which can avoid the leakage of the recipient's account information; in the process of receiving virtual resources, the resource recipient does not need to obtain the transferor's account information in advance, nor does it need to interact directly with the resource transferor, which can avoid the leakage of the transferor's account information. Therefore, the above method can avoid the leakage of the recipient's account information and the transferor's account information, which is conducive to improving security.
[0158] In one embodiment, the resource collection information can be a QR code, and the blockchain virtual resource transfer process can be realized through the QR code. The resource transferor can make and issue a gift card including a QR code. When the resource recipient obtains the gift card, he can scan the QR code on the gift card to realize the collection of virtual resources. During the whole process, the resource recipient and the resource transferor do not need to interact directly. Both the resource recipient and the resource transferor can install an application software with a wallet function and realize the blockchain virtual resource transfer through the application software.
[0159] Specifically, Figure 7 As shown in the figure, during the resource transfer process, the resource recipient generates a blockchain account and manages the blockchain account through the account private key of the blockchain account. The entire blockchain account generation process does not need to be on-chain. Non-native virtual resources can be issued through smart contracts. Smart contracts for issuing non-native virtual resources are also called token smart contracts. Token smart contracts are a type of smart contract based on blockchain technology that is used to manage and issue digital assets (Tokens). Token smart contracts can automatically execute contract terms to ensure that the contract execution process is transparent, fair, and credible. In token smart contracts, Tokens can represent any digital assets, such as currency, stocks, commodities, game props, etc. Specifically, token smart contracts can be deployed by the resource transferor, and each deployment of a contract can issue a batch of virtual resources. Its contract standard will define various interfaces, such as casting interfaces and transfer interfaces, and the corresponding functions can be implemented by calling interfaces during the application process. The processing logic corresponding to the interface is determined by the contract publisher, and the contract code is public on the blockchain.
[0160] like Figure 7 As shown, the resource transferor initiates a resource transfer request to transfer the transferor's virtual resources in the transferor's account to the newly generated blockchain account. At the same time, in order to prevent the resource recipient from paying fees to the chain processing node when receiving the virtual resources, the resource transferor also requests that the chain consumable resources required to receive the transferor's virtual resources be transferred to the blockchain account. Then, the chain processing node responds to the resource transfer request and realizes the transfer of the transferor's virtual resources and chain consumable resources by calling the corresponding smart contract. Next, the resource transferor encodes the private key of the blockchain account and the contract address of the on-chain asset issuance into the QR code so that the resource recipient can receive the virtual resources in the blockchain account by scanning.
[0161] Furthermore, the QR code protocol refers to the HTTP URL protocol, including information such as the protocol prefix, blockchain identifier, contract standard, contract address, and account private key. Among them, the protocol prefix is fixed to receive_token, and the barcode scanner used by the resource recipient can distinguish various protocols. As long as the barcode is scanned and identified with this prefix, it can be judged as an operation to receive assets on the chain; the blockchain identifier in the coding protocol is used to identify which blockchain it is. Currently, there are hundreds of blockchains on the public network, and the chain_id (blockchain identifier) is different; the contract standard is similar to erc20, erc721, and erc1155, which have clear definitions and fixed interface methods. The contract code is issued to the blockchain and will have a unique identifier. The contract identifier can be the contract address. During the application process, the corresponding smart contract can be called through the contract identifier to realize business transactions; the account private key is the private key of the blockchain account holding these assets on the chain. Based on the account private key, the blockchain account can be managed to realize the transfer of blockchain virtual assets. It can be understood that since the blockchain account corresponds to the account private key one by one, the account private key can be used as the account information of the blockchain account and uniquely represents the blockchain account.
[0162] In a specific embodiment, the encoding information of the QR code may be “receive_token / 1 / erc20 / 0x1f9090aaE28b8a3dCeaDf281B0F12828e676c326 / 0x481e94c5dc2c0f843d4fcf1c7bd2d83cd838c63de313aac061738e3f663b614”, where “receive_token / 1 / erc20 / 0x1f9090aaE28b8a3dCeaDf281B0F12828e676c326 / 0x481e94c5dc2c0f843d4fcf1c7bd2d83cd838c63de313aac061738e3f663b614”. "e_token" is the protocol prefix, "1" is the blockchain identifier, "erc20" is the contract standard, "0x1f9090aaE28b8a3dCeaDf281B0F12828e676c326" is the contract address, and "0x481e94c5dc2c0f843d4fcf1c7bd2d83cd838c63de313aac061738e3f663b614" is the account private key of the blockchain account. By performing image encoding processing on the encoded information, the QR code corresponding to the encoded information can be obtained. Furthermore, multiple lines can be encoded in the QR code to realize scanning one code to receive multiple on-chain assets.
[0163] like Figure 8As shown, the resource recipient can obtain the gift card containing the QR code in various ways, and parse the protocol prefix, blockchain identifier, contract standard, contract address, account private key and other information by scanning the code. Then, find the corresponding blockchain through the blockchain identifier, calculate the account address of the blockchain account through the account private key, and query whether the virtual resources of the transferor that can be used in the blockchain account are sufficient, and whether the available on-chain consumption resources are sufficient. If both are sufficient, it means that there is no problem with the gift card, and the resource recipient constructs a contract transfer transaction, sets from to be the account address of the blockchain account that stores the virtual resources of the transferor, to is the blockchain address of the resource recipient, value and data are on-chain assets, configures the on-chain consumption resources, and puts the transaction on the chain, and initiates a resource collection on-chain request. If the chain is successful, the contract executes the asset transfer logic, and the asset is transferred to the resource recipient, then the user is prompted to receive successfully, and prints the list of received assets, the contract address where the asset is located, and other execution conditions. During the collection process, the resource recipient does not need to spend any fees, and all payments are made by the blockchain account associated with the QR code.
[0164] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0165] Based on the same inventive concept, the embodiment of the present application also provides a blockchain system for implementing the blockchain virtual resource transfer method involved above. The implementation scheme for solving the problem provided by the system is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more blockchain system embodiments provided below can refer to the limitations of the blockchain virtual resource transfer method above, and will not be repeated here.
[0166] In some embodiments, Fig. 9As shown, a blockchain system 900 is provided, including a resource transferor 901, an on-chain processing node 902, and a resource recipient 903. The resource transferor 901 generates a blockchain account for storing blockchain virtual resources in response to a blockchain virtual resource transfer request, determines the transferor virtual resource requested to be transferred, and initiates a resource transfer on-chain request to transfer the transferor virtual resource to the blockchain account; the on-chain processing node 902 responds to the resource transfer on-chain request and transfers the transferor virtual resource to the blockchain account; the resource transferor 901 generates resource collection information when the transferor virtual resource is transferred to the blockchain account; the resource recipient 903 obtains the resource collection information, extracts the account information of the blockchain account from the resource collection information, and initiates a resource collection on-chain request to collect the target virtual resource from the blockchain account based on the account information; the target virtual resource includes at least a part of the virtual resources stored in the blockchain account; the on-chain processing node 902 responds to the resource collection on-chain request and transfers the target virtual resource from the blockchain account; the resource recipient 903 receives the target virtual resource transferred from the blockchain account.
[0167] As mentioned above, the blockchain system includes multiple nodes (any form of computing devices in the access network, such as servers, user terminals) and clients, and the nodes form a peer-to-peer network. The peer-to-peer protocol is an application layer protocol running on the Transmission Control Protocol (TCP). The functions involved in each node in the blockchain system include routing functions for supporting communication between nodes, and application functions. Among them, the application is used to be deployed in the blockchain, implement specific services according to actual business needs, record data related to the implementation of functions to form record data, carry digital signatures in the record data to indicate the source of the task data, and send the record data to other nodes in the blockchain system for other nodes to add the record data to the temporary block when the source and integrity of the record data are successfully verified. For example, the services implemented by the application include: wallets, shared ledgers, and smart contracts. The wallet is used to provide the function of conducting electronic currency transactions, including initiating transactions (i.e., sending the transaction record of the current transaction to other nodes in the blockchain system. After the other nodes successfully verify, as a response to acknowledge the validity of the transaction, the transaction record data is stored in a temporary block of the blockchain; of course, the wallet also supports querying the remaining electronic currency in the electronic currency address. The embodiments of the present application involve the wallet function of the blockchain node. Therefore, the relevant functions of the resource transferor and the resource recipient in the blockchain system can be implemented based on the corresponding blockchain wallet. The blockchain wallet may include a transferor wallet and a recipient wallet.
[0168] Specifically, in the process of transferring blockchain virtual resources, the resource transferor 901 responds to the blockchain virtual resource transfer request, generates a blockchain account for storing blockchain virtual resources, determines the transferor virtual resources requested to be transferred, and initiates a resource transfer request to transfer the transferor virtual resources to the blockchain account. Then, the on-chain processing node 902 responds to the resource transfer request to transfer the transferor virtual resources to the blockchain account. Next, the resource transferor 901 generates resource collection information when the transferor virtual resources are transferred to the blockchain account. In the process of collecting the virtual resources of the blockchain account, the resource recipient 903 obtains the resource collection information, extracts the account information of the blockchain account from the resource collection information, and initiates a resource collection request to collect the target virtual resources from the blockchain account based on the account information. The target virtual resource includes at least a portion of the virtual resources stored in the blockchain account. Then, the on-chain processing node 902 responds to the resource collection request to transfer the target virtual resources from the blockchain account, and finally, the resource recipient 903 receives the target virtual resources transferred from the blockchain account.
[0169] The above blockchain system can realize the transfer of blockchain virtual resources through the generated blockchain account, so that in the process of transferring virtual resources, the resource transferor does not need to obtain the account information of the recipient in advance, nor does it need to interact directly with the resource recipient, which can avoid the leakage of the recipient's account information; in the process of receiving virtual resources, the resource recipient does not need to obtain the transferor's account information in advance, nor does it need to interact directly with the resource transferor, which can avoid the leakage of the transferor's account information. Therefore, the above method can avoid the leakage of the recipient's account information and the transferor's account information, which is conducive to improving security.
[0170] In one embodiment, the blockchain system 900 includes multiple resource transferors; each resource transferor generates its own matching blockchain account; the target virtual resource includes the sub-target virtual resources transferred from each resource transferor in each blockchain account. In the case of this embodiment, the resource recipient specifically extracts the account information of each blockchain account from the resource collection information, and initiates a resource collection on-chain request to collect each sub-target virtual resource from each blockchain account; the on-chain processing node specifically responds to the resource collection on-chain request, and transfers each sub-target virtual resource from the blockchain account to which it belongs.
[0171] In practical applications, multiple resource transferors can jointly transfer resources. For example, multiple merchants conduct joint promotions, or multiple institutions provide corresponding on-chain data. Specifically, each resource transferor can generate its own matching blockchain account, and transfer the sub-target virtual resources from its own account to the corresponding blockchain account. Then, a resource collection information matching each blockchain account is generated. The resource collection information carries the account information of each blockchain account, and the contract information of the smart contract that needs to be called to collect each sub-target virtual resource. Further, the resource collection information can be generated by one of the resource transferors and synchronized to other resource transferors. During the virtual resource collection process, the resource recipient specifically extracts the account information of each blockchain account from the resource collection information, and initiates a resource collection request to collect each sub-target virtual resource from each blockchain account. Then, the on-chain processing node specifically responds to the resource collection request, and transfers each sub-target virtual resource from the blockchain account to which it belongs.
[0172] In the above embodiment, multiple resource transferors generate their own matching blockchain accounts respectively, and transfer the corresponding sub-target virtual resources from their own accounts to the corresponding blockchain accounts respectively, and generate resource collection information matching each blockchain account. In this way, the resource recipient can collect multiple sub-target virtual resources from multiple blockchain accounts through resource collection information, which is conducive to expanding the application scenarios of the blockchain virtual resource transfer method and improving the efficiency of virtual resource transfer.
[0173] In one embodiment, the blockchain system further includes an accounting node that records historical collection information of the blockchain account. Specifically, the on-chain processing node responds to the resource collection on-chain request and transfers the target virtual resource from the blockchain account when it determines that the resource recipient meets the collection conditions based on the associated collection information of the resource recipient in the historical collection information.
[0174] The claiming conditions can be configured by the resource transferor according to the actual situation. For example, the claiming condition can only support the first claiming, that is, the resource recipient can only claim the virtual resource once from the same blockchain account; the claiming condition can also only support specific resource recipients to claim, for example, only support resource recipients above the target level to claim, or only support resource recipients whose historical transaction volume reaches the set transaction volume to claim.
[0175] Specifically, when the resource recipient receives the target virtual resource transferred from the blockchain account, the accounting node records the receipt information of this resource receipt and updates the historical receipt information of the blockchain account. The historical receipt information includes the account information of the blockchain account, the recipient information of the resource recipient, and the resource information of the received target virtual resource. In the subsequent resource receipt process, the on-chain processing node can determine whether the resource recipient meets the receipt conditions based on the associated receipt information of the resource recipient in the historical receipt information when the resource recipient initiates a resource receipt on-chain request, and respond to the resource receipt on-chain request when the resource recipient meets the receipt conditions, and transfer the target virtual resource from the blockchain account.
[0176] In this embodiment, when the resource recipient meets the conditions for receiving the resource, the resource collection chain request is responded to and the target virtual resource is transferred out of the blockchain account, which can ensure that the resource recipient has the collection authority and is conducive to further improving the security of the virtual resource transfer process.
[0177] Based on the same inventive concept, the embodiment of the present application also provides a blockchain virtual resource transfer device for implementing the blockchain virtual resource transfer method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more blockchain virtual resource transfer device embodiments provided below can refer to the limitations of the blockchain virtual resource transfer method above, and will not be repeated here.
[0178] In some embodiments, Fig.10 As shown, a blockchain virtual resource transfer device 1000 is provided, including: a blockchain account generation module 1002, a resource transfer request initiation module 1004 and a resource collection information generation module 1006, wherein:
[0179] The blockchain account generation module 1102 is used to generate a blockchain account for storing blockchain virtual resources in response to a blockchain virtual resource transfer request;
[0180] The resource transfer-out on-chain request initiating module 1104 is used to determine the transferor virtual resource requested to be transferred, and initiate a resource transfer-out on-chain request to transfer the transferor virtual resource to the blockchain account;
[0181] The resource collection information generation module 1106 is used to generate resource collection information when the resource transfer request is responded to by the chain processing node and the transferor's virtual resources are transferred to the blockchain account; the resource collection information is used to instruct the resource recipient to collect at least a part of the transferor's virtual resources from the blockchain account.
[0182] In one embodiment, the blockchain account generation module 1102 is specifically used to: generate an account public key and an account private key in response to a blockchain virtual resource transfer request; encode the account public key to obtain an encoded address; determine a target blockchain address that matches the encoded address from available blockchain addresses, and generate a blockchain account corresponding to the target blockchain address; the blockchain account is used to store blockchain virtual resources, and the blockchain account is managed based on the account private key.
[0183] In one embodiment, the blockchain virtual resource transfer device 1000 further includes an on-chain consumption resource determination module, which is used to determine the on-chain consumption resources required to collect the transferor's virtual resources. In the case of this embodiment, the resource transfer-out on-chain request initiation module 1004 is specifically used to: initiate a resource transfer-out on-chain request to transfer the transferor's virtual resources and on-chain consumption resources to a blockchain account; the on-chain consumption resources and the transferor's virtual resources have the same source.
[0184] In one embodiment, the resource collection information generation module 1006 includes: an information acquisition unit, which is used to obtain the account information of the blockchain account and determine the contract information of the smart contract required to be called to collect at least a part of the transferor's virtual resources; a character encoding unit, which is used to perform character encoding processing on the account information and the contract information to obtain character encoding information; and an image encoding unit, which is used to perform image encoding processing on the character encoding information to obtain resource collection information.
[0185] In one embodiment, the transferor virtual resource includes multiple candidate virtual resources. In this embodiment, the information acquisition unit is specifically used to: determine at least one target virtual resource from the multiple candidate virtual resources; determine the contract information of the smart contract that needs to be called to obtain each target virtual resource. The character encoding unit is specifically used to: perform character encoding processing on the account information and each contract information to obtain character encoding information.
[0186] In one embodiment, the blockchain virtual resource transfer device 1000 also includes a configuration module, which is used to: obtain resource collection configuration information for a blockchain account in response to a resource collection configuration request; and deploy a smart contract required to collect at least a portion of the transferor's virtual resources based on the resource collection configuration information.
[0187] In some embodiments, Fig.11 As shown, another blockchain virtual resource transfer device 1100 is provided, including: an information extraction module 1102, a resource collection and chain request initiation module 1104 and a virtual resource receiving module 1106, wherein:
[0188] An information extraction module 1102 is used to obtain resource collection information and extract account information of a blockchain account from the resource collection information;
[0189] The resource collection on-chain request initiating module 1104 is used to initiate a resource collection on-chain request to collect target virtual resources from a blockchain account based on account information; the target virtual resources include at least a portion of the blockchain virtual resources stored in the blockchain account; the blockchain virtual resources are transferred from the resource transferor to the blockchain account by responding to the blockchain virtual resource transfer request;
[0190] The virtual resource receiving module 1106 is used to receive the target virtual resources transferred from the blockchain account when the resource collection on-chain request is responded to by the on-chain processing node.
[0191] In one embodiment, the blockchain virtual resource transfer device 1100 further includes a query module for querying the transferor virtual resources available in the blockchain account based on the account information. In this embodiment, the resource collection on-chain request initiation module 1104 is specifically used to initiate a resource collection on-chain request for collecting the target virtual resource from the blockchain account when the transferor virtual resources available include the target virtual resource.
[0192] In one embodiment, the query module is also used to query the available on-chain consumable resources in the blockchain account based on the account information. In the case of this embodiment, the resource collection on-chain request initiation module 1104 is specifically used to: when the available transferor virtual resources include the target virtual resources, determine the target on-chain consumable resources required to collect the target virtual resources; when the available on-chain consumable resources include the target on-chain consumable resources, initiate a resource collection on-chain request to collect the target virtual resources from the blockchain account.
[0193] Each module in the above-mentioned blockchain virtual resource transfer device can be implemented in whole or in part by software, hardware and a combination thereof. Each of the above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory in the computer device in the form of software, so that the processor can call and execute the operations corresponding to each of the above modules.
[0194] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Fig.12As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. Among them, the processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data involved in the blockchain virtual resource transfer method. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a blockchain virtual resource transfer method is implemented.
[0195] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Fig.13 As shown. The computer device includes a processor, a memory, an input / output interface, a communication interface, a display unit and an input device. Among them, the processor, the memory and the input / output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless method can be implemented through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a blockchain virtual resource transfer method is implemented. The display unit of the computer device is used to form a visually visible image, and can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen. The input device of the computer device can be a touch layer covered on the display screen, or a button, trackball or touchpad set on the computer device casing, or an external keyboard, touchpad or mouse, etc.
[0196] Those skilled in the art will understand that Fig.12 and Fig.13The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0197] In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above-mentioned blockchain virtual resource transfer method when executing the computer program.
[0198] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the steps in the above-mentioned blockchain virtual resource transfer method are implemented.
[0199] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above-mentioned blockchain virtual resource transfer method when executed by a processor.
[0200] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data need to comply with relevant laws, regulations and standards of the relevant regions and areas.
[0201] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.
[0202] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0203] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A blockchain virtual resource transfer method, characterized in that: The method comprises: In response to the blockchain virtual resource transfer request, generating a blockchain account for storing the blockchain virtual resource; Determine the virtual resource of the transferor requested to be transferred, and initiate a resource transfer request to transfer the virtual resource of the transferor to the blockchain account; When the resource transfer request is responded to by the on-chain processing node and the virtual resources of the transferor are transferred to the blockchain account, resource collection information is generated; the resource collection information is used to instruct the resource recipient to collect at least a part of the virtual resources of the transferor from the blockchain account.
2. The method according to claim 1, characterized in that The step of generating a blockchain account for storing blockchain virtual resources in response to a blockchain virtual resource transfer request includes: In response to a blockchain virtual resource transfer request, generate an account public key and an account private key; Encode the account public key to obtain an encoded address; A target blockchain address matching the encoded address is determined from available blockchain addresses, and a blockchain account corresponding to the target blockchain address is generated; the blockchain account is used to store blockchain virtual resources, and the blockchain account is managed based on the account private key.
3. The method according to claim 1, characterized in that: The method further comprises: Determine the on-chain consumption resources required to claim the transferor's virtual resources; The initiating a resource transfer request to transfer the transferor's virtual resources to the blockchain account includes: Initiate a resource transfer request to transfer the transferor's virtual resources and the on-chain consumable resources to the blockchain account; the on-chain consumable resources and the transferor's virtual resources have the same source.
4. The method according to any one of claims 1 to 3, characterized in that The generating resource claiming information includes: Obtaining account information of the blockchain account, and determining contract information of a smart contract required to be called to claim at least a portion of the transferor's virtual resources; Performing character encoding processing on the account information and the contract information to obtain character encoding information; The character encoding information is subjected to image encoding processing to obtain resource collection information.
5. The method according to claim 4, characterized in that The transfer-out party virtual resource includes a plurality of candidate virtual resources; The contract information of the smart contract required to be called to determine the receipt of at least a portion of the transferor's virtual resources includes: Determining at least one target virtual resource from the plurality of candidate virtual resources; Determine the contract information of the smart contract that needs to be called to obtain each of the target virtual resources; The performing character encoding processing on the account information and the contract information to obtain character encoding information includes: The account information and each of the contract information are subjected to character encoding processing to obtain character encoding information.
6. The method according to claim 4, characterized in that The method further comprises: In response to the resource claim configuration request, obtaining resource claim configuration information for the blockchain account; Based on the resource collection configuration information, deploy a smart contract required to collect at least a portion of the transferor's virtual resources.
7. A blockchain virtual resource transfer method, characterized in that: The method comprises: Obtain resource collection information, and extract account information of the blockchain account from the resource collection information; Based on the account information, a resource collection and on-chain request is initiated to collect the target virtual resource from the blockchain account; the target virtual resource includes at least a portion of the blockchain virtual resource stored in the blockchain account; the blockchain virtual resource is transferred from the resource transferor to the blockchain account by responding to the blockchain virtual resource transfer request; When the resource collection on-chain request is responded to by the on-chain processing node, the target virtual resource transferred from the blockchain account is received.
8. The method according to claim 7, characterized in that The method further comprises: Based on the account information, query the blockchain account for the transferor virtual resources that can be collected; The initiating a resource collection and chaining request for collecting a target virtual resource from the blockchain account includes: In the case where the transferor virtual resources that can be collected include the target virtual resource, a resource collection and on-chain request is initiated to collect the target virtual resource from the blockchain account.
9. The method according to claim 8, characterized in that The method further comprises: Based on the account information, query the available on-chain consumable resources in the blockchain account; In the case where the transferor virtual resources that can be collected include the target virtual resource, initiating a resource collection and chaining request for collecting the target virtual resource from the blockchain account includes: In the case where the transferor virtual resources that can be collected include the target virtual resources, determining the target on-chain consumable resources that are required to collect the target virtual resources; In the case where the available on-chain consumable resources include the target on-chain consumable resources, a resource collection on-chain request is initiated to collect the target virtual resources from the blockchain account.
10. A blockchain system, characterized in that: Including resource transferors, resource recipients and on-chain processing nodes; The resource transferor generates a blockchain account for storing blockchain virtual resources in response to the blockchain virtual resource transfer request, determines the transferor virtual resources requested to be transferred, and initiates a resource transfer request to transfer the transferor virtual resources to the blockchain account; The on-chain processing node responds to the resource transfer-out on-chain request and transfers the transferor virtual resource to the blockchain account; The resource transferor generates resource collection information when the virtual resource of the transferor is transferred to the blockchain account; The resource recipient obtains the resource collection information, extracts the account information of the blockchain account from the resource collection information, and initiates a resource collection and on-chain request to collect the target virtual resource from the blockchain account based on the account information; the target virtual resource includes at least a part of the virtual resources stored in the blockchain account; The on-chain processing node responds to the resource collection on-chain request and transfers the target virtual resource from the blockchain account; The resource recipient receives the target virtual resource transferred from the blockchain account.
11. The system according to claim 10, characterized in that The system includes a plurality of resource transferors; each of the resource transferors generates a respective matching blockchain account; the target virtual resource includes a sub-target virtual resource in each blockchain account transferred from each of the resource transferors; The resource recipient specifically extracts the account information of each of the blockchain accounts from the resource collection information, and initiates a resource collection and chaining request to collect each of the sub-target virtual resources from each of the blockchain accounts; The on-chain processing node specifically responds to the resource collection on-chain request and transfers each of the sub-target virtual resources from the corresponding blockchain account.
12. The system according to claim 10, characterized in that The system also includes an accounting node; The accounting node records the historical receipt information of the blockchain account; The on-chain processing node specifically responds to the resource collection on-chain request and transfers the target virtual resource from the blockchain account when it determines that the resource recipient meets the collection conditions based on the associated collection information of the resource recipient in the historical collection information.
13. A blockchain virtual resource transfer device, characterized in that: The device comprises: A blockchain account generation module, used to generate a blockchain account for storing blockchain virtual resources in response to a blockchain virtual resource transfer request; A resource transfer-out on-chain request initiating module, used to determine the transferor virtual resource requested to be transferred, and initiate a resource transfer-out on-chain request to transfer the transferor virtual resource to the blockchain account; A resource collection information generation module is used to generate resource collection information when the resource transfer request is responded to by the chain processing node and the transferor's virtual resources are transferred to the blockchain account; the resource collection information is used to instruct the resource recipient to collect at least a part of the transferor's virtual resources from the blockchain account.
14. A blockchain virtual resource transfer device, characterized in that: The device comprises: An information extraction module, used to obtain resource collection information and extract account information of a blockchain account from the resource collection information; A resource collection on-chain request initiating module, configured to initiate a resource collection on-chain request for collecting a target virtual resource from the blockchain account based on the account information; the target virtual resource includes at least a portion of the blockchain virtual resource stored in the blockchain account; the blockchain virtual resource is transferred from the resource transferor to the blockchain account in response to the blockchain virtual resource transfer request; The virtual resource receiving module is used to receive the target virtual resource transferred from the blockchain account when the resource collection on-chain request is responded to by the on-chain processing node.
15. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 9 are implemented.
16. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 9 are implemented.
17. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 9 are implemented.