Directional freight payment method and system based on block chain
Through blockchain technology and smart contracts, the timed and targeted payment of freight in the logistics industry has been achieved, the financing difficulties of logistics companies and the security of freight payment are solved, and the security and transparency of capital circulation have been improved.
Patent Information
- Application Number
- CN202411768033.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-04
- Publication Date
- 2025-05-06
- Estimated Expiration
- 2044-12-04
AI Technical Summary
In the logistics industry, logistics companies find it difficult to meet the credit conditions of traditional financial institutions, resulting in the problems of difficulty and high cost of financing. The existing technology is difficult to ensure special and targeted payments for freight, and cannot guarantee the safety of payment.
The blockchain-based freight targeted payment method is adopted to generate and publish the first smart contract through the smart contract platform to realize batch transfer of freight from logistics companies to drivers, and in the second smart contract, the driver can only use freight in designated consumption scenarios.
It improves the security of capital circulation, reduces the possibility of fraud or abuse, effectively controls risks, and ensures that funds are used strictly in accordance with the agreed purposes of the smart contract.
Smart Images

Figure CN119941242A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to blockchain technology, and in particular to a blockchain-based freight directional payment method and system. Background Art
[0002] In the logistics industry, most logistics operators are small in scale, scattered in distribution, large in number, and weak in operation, making it difficult to meet the credit conditions of traditional financial institutions. Therefore, problems such as difficulty in financing and high financing costs are particularly prominent, which brings great troubles to the development of physical logistics companies. The freight settlement cycle between shippers and logistics companies is getting longer and longer, and 60 days, 90 days, or even half a year's account period has become the industry rule. In order to maintain the normal operation of the business, logistics companies must bear the pressure of downstream freight advance payment. In response to the above scenarios, the financial service platform and financial institutions have launched freight loan products. Based on real business data, logistics companies can solve the account period problem between upstream delayed payment and downstream instant payment. In addition, after the logistics company obtains the loan, according to the current loan policy and regulatory requirements, the logistics company needs to pay the freight to the driver in a timely manner. However, the existing technology uses traditional payment methods, which makes it difficult to ensure that funds are used for specific purposes and targeted payments, and cannot guarantee the security of payment. Summary of the invention
[0003] The main purpose of the present invention is to provide a blockchain-based freight targeted payment method and system, which can change the traditional payment model, improve the security of capital circulation, and reduce the possibility of fraud or abuse, while effectively controlling risks.
[0004] The technical solution adopted by the present invention is:
[0005] A blockchain-based freight directional payment method is provided, comprising the following steps:
[0006] S1. The smart contract platform generates the first smart contract based on the loan contract information of the logistics company applying for a special freight loan and publishes it to the blockchain network;
[0007] S2. The financial service platform obtains the loan result information and queries the corresponding first smart contract from the blockchain network according to the smart contract identifier, verifies the key content in the first smart contract, and if the verification passes, requests to call the first smart contract to transfer the driver's freight from the logistics company wallet to the corresponding driver wallet in batches through the first smart contract;
[0008] S3. The financial service platform obtains the execution record of the first smart contract. If the execution is successful, the smart contract platform generates a second smart contract based on the loan contract information and key information in the first smart contract and publishes it to the blockchain network;
[0009] S4. The financial service platform obtains a payment request sent by the driver, where the payment request is a payment request sent by the driver when using the freight in the driver's wallet in a specified consumption scenario;
[0010] S5. The financial service platform queries the corresponding second smart contract from the blockchain network according to the smart contract identifier, and compares the received payment request with the key information in the second smart contract;
[0011] S6. If the comparison result matches, a request is made to call the second smart contract, and the payment amount is transferred from the driver's wallet to the merchant's payment account according to the second smart contract.
[0012] Following the above technical solution, the first smart contract includes multiple information of the logistics company, financial institution and driver, as well as loan rules and conditions. It stipulates that when the financial institution disburses the designated loan amount for freight to the logistics company wallet, the payment terms are triggered. The payment terms stipulate that the freight is paid from the logistics company wallet to the driver wallet.
[0013] According to the above technical solution, the payment request sent by the driver includes the driver's information, payment amount and merchant information. The driver's information includes the driver's name and driver's wallet, and the merchant information includes the merchant's name, merchant category code and merchant collection account.
[0014] Following the above technical solution, the designated consumption scenarios include paying for refueling, gas or highway tolls, etc.
[0015] Following the above technical solution, in step S2, the process of verifying the first smart contract specifically includes:
[0016] The financial service platform requests to call the first smart contract. The first smart contract assembles data messages according to the payment terms, generates batch payment requests and sends them to the financial institution. The payment request includes the smart contract identifier, the logistics company wallet and the driver's freight collection.
[0017] The financial institution obtains the batch payment request, queries the corresponding first smart contract on the blockchain network according to the smart contract identifier, verifies the key content in the first smart contract, and verifies the signed hash value using the contract public key. If the verification result is correct, the driver's freight will be transferred from the logistics company wallet to the driver's wallet in batches.
[0018] Following the above technical solution, in step S2, the corresponding smart contract identifier is specifically queried through the loan number. When the financial institution issues the freight payment to the logistics company wallet, the financial institution notifies the financial service platform of the loan result information, and the financial service platform obtains the loan number from the loan result information.
[0019] Following the above technical solution, step S5 is specifically as follows:
[0020] Query the corresponding second smart contract from the blockchain network according to the smart contract identifier;
[0021] Based on the key information obtained from the second smart contract, the signed Hash value is verified using the contract public key;
[0022] After verification, the driver information in the received payment request is compared with the driver freight set in the second smart contract;
[0023] If they are inconsistent, a corresponding prompt message is generated;
[0024] If they are consistent, the merchant information in the payment request will continue to be compared with the merchant category code set in the second smart contract. If they are inconsistent, a corresponding prompt message will be generated; if they are consistent, the driver's wallet balance will be obtained, and the payment amount will be compared with the driver's wallet balance. When the payment amount is greater than the driver's wallet balance, a corresponding prompt message will be generated; when the payment amount is less than or equal to the driver's wallet balance, the final comparison result is considered to match.
[0025] Following the above technical solution, generating the first smart contract in step S1 specifically includes the following steps:
[0026] Based on the homomorphic encryption algorithm, configure all symmetric keys and unique smart contract identifiers of the first smart contract, generate a contract private key and a corresponding contract public key, use the contract private key to generate a signed hash value, verify the business logic of the contract, verify the accuracy of the contract, and compile the contract file;
[0027] After the contract is compiled successfully, it is submitted for review and the first smart contract is approved according to the preset approval process;
[0028] After the first smart contract is reviewed and approved, the contract is deployed and published to the blockchain network through access management.
[0029] The present invention also provides a blockchain-based freight directional payment system, including a financial service platform and a smart contract platform, wherein:
[0030] A smart contract platform is used to generate a first smart contract based on the loan contract information of the logistics company applying for a special freight loan and publish it to the blockchain network; and when the first smart contract is successfully executed, a second smart contract is generated based on the loan contract information and key information in the first smart contract and published to the blockchain network;
[0031] The financial service platform is used to obtain the loan result information of the financial institution and query the corresponding first smart contract from the blockchain network according to the smart contract identifier, verify the key content in the first smart contract, and if the verification passes, request to call the first smart contract to transfer the driver's freight from the logistics company wallet to the corresponding driver wallet in batches through the first smart contract;
[0032] The financial service platform is also used to obtain the payment request sent by the driver, which is the payment request sent by the driver when using the freight in the driver's wallet in a designated consumption scenario; query the corresponding second smart contract from the blockchain network according to the smart contract identifier, and compare the received payment request with the key information in the second smart contract; if the comparison result matches, request to call the second smart contract, and transfer the payment amount from the driver's wallet to the merchant's payment account according to the second smart contract.
[0033] The present invention also provides a computer storage medium, which stores a computer program that can be executed by a processor, and the computer program executes the blockchain-based targeted freight payment method described in the above technical solution.
[0034] The beneficial effects of the present invention are as follows: the blockchain-based freight targeted payment method of the present invention can realize the timed and targeted payment of funds with the support of smart contracts, ensure that the funds are strictly used in accordance with the agreed purposes of the smart contracts, improve the security of fund circulation, and reduce the possibility of fraud or abuse, while effectively controlling risks.
[0035] Of course, any product implementing the present invention does not necessarily need to achieve all of the advantages described above at the same time. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0037] Figure 1 This is a flow chart of a blockchain-based freight directional payment method according to an embodiment of the present invention;
[0038] Figure 2 is a flow chart of a blockchain-based freight directional payment method according to another embodiment of the present invention;
[0039] Figure 3 It is a relationship diagram between the subjects in implementing blockchain-based directional freight payment according to an embodiment of the present invention. DETAILED DESCRIPTION
[0040] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention 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 invention and are not used to limit the present invention.
[0041] It should be noted that the illustrations provided in the embodiments of the present invention are only used to illustrate the basic concept of the present invention in a schematic manner. Therefore, the drawings only show components related to the present invention rather than being drawn according to the number, shape and size of components in actual implementation. In actual implementation, the type, quantity and proportion of each component may be changed arbitrarily, and the component layout type may also be more complicated.
[0042] In the present invention, it is also necessary to explain that, if the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inner", "outer", etc. appear, the orientation or position relationship indicated is based on the orientation or position relationship shown in the drawings, which is only for the convenience of describing the present application and simplifying the description, and does not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation on the present application. In addition, if the terms "first" and "second" appear, they are only used for description and distinction purposes, and cannot be understood as indicating or implying relative importance.
[0043] Example 1
[0044] like Figure 1 As shown, the blockchain-based freight directional payment method of the embodiment of the present invention mainly includes the following steps:
[0045] S1. The smart contract platform generates the first smart contract based on the loan contract information of the logistics company applying for a special freight loan and publishes it to the blockchain network;
[0046] S2. The financial service platform obtains the loan result information and queries the corresponding first smart contract from the blockchain network according to the smart contract identifier, verifies the key content in the first smart contract, and if the verification passes, requests to call the first smart contract to transfer the driver's freight from the logistics company wallet to the corresponding driver wallet in batches through the first smart contract;
[0047] S3. The financial service platform obtains the execution record of the first smart contract. If the execution is successful, the smart contract platform generates a second smart contract based on the loan contract information and key information in the first smart contract and publishes it to the blockchain network;
[0048] S4. The financial service platform obtains a payment request sent by the driver, where the payment request is a payment request sent by the driver when using the freight in the driver's wallet in a specified consumption scenario;
[0049] S5. The financial service platform queries the corresponding second smart contract from the blockchain network according to the smart contract identifier, and compares the received payment request with the key information in the second smart contract;
[0050] S6. If the comparison result matches, a request is made to call the second smart contract, and the payment amount is transferred from the driver's wallet to the merchant's payment account according to the second smart contract.
[0051] This embodiment is based on a blockchain-based targeted freight payment method. With the support of smart contracts, it can achieve timed and targeted payment of funds, ensure that funds are used strictly in accordance with the agreed purposes of the smart contract, improve the security of fund circulation, and reduce the possibility of fraud or abuse, while effectively controlling risks.
[0052] Furthermore, specifically, the first smart contract includes multi-party information of the logistics company, the financial institution and the driver, as well as loan rules and conditions. It stipulates that when the financial institution disburses the designated loan amount for freight to the logistics company wallet, the payment terms are triggered. The payment terms stipulate that the freight is paid from the logistics company wallet to the driver's wallet.
[0053] The payment request sent by the driver includes the driver's information, payment amount and merchant information. The driver's information includes the driver's name and driver's wallet. The merchant information includes the merchant name, merchant category code and merchant payment account, etc.
[0054] Designated consumption scenarios include paying for refueling, gas or highway tolls, etc.
[0055] Furthermore, generating the first smart contract in step S1 specifically includes the following steps:
[0056] Based on the homomorphic encryption algorithm, configure all symmetric keys and unique smart contract identifiers of the first smart contract, generate a contract private key and a corresponding contract public key, use the contract private key to generate a signed hash value, verify the business logic of the contract, verify the accuracy of the contract, and compile the contract file;
[0057] After the contract is compiled successfully, it is submitted for review and the first smart contract is approved according to the preset approval process;
[0058] After the first smart contract is reviewed and approved, the contract is deployed and published to the blockchain network through access management.
[0059] In step S2, the process of verifying the first smart contract specifically includes:
[0060] The financial service platform requests to call the first smart contract. The first smart contract assembles data messages according to the payment terms, generates batch payment requests and sends them to the financial institution. The payment request includes the smart contract identifier, the logistics company wallet and the driver's freight collection.
[0061] The financial institution obtains the batch payment request, queries the corresponding first smart contract on the blockchain network according to the smart contract identifier, verifies the key content in the first smart contract, and verifies the signed hash value using the contract public key. If the verification result is correct, the driver's freight will be transferred from the logistics company wallet to the driver's wallet in batches.
[0062] Among them, the corresponding smart contract identifier can be specifically queried through the loan number. When the financial institution pays the freight to the logistics company's wallet, the financial institution will notify the financial service platform of the loan result information, and the financial service platform will obtain the loan number from the loan result information.
[0063] Step S5 is specifically as follows:
[0064] Query the corresponding second smart contract from the blockchain network according to the smart contract identifier;
[0065] Based on the key information obtained from the second smart contract, the signed Hash value is verified using the contract public key;
[0066] After verification, the driver information in the received payment request is compared with the driver freight set in the second smart contract;
[0067] If there is no inconsistency, a corresponding prompt message is generated; if there is consistency, the merchant information in the payment request is compared with the merchant category code set in the second smart contract. If there is no inconsistency, a corresponding prompt message is generated; if there is consistency, the driver's wallet balance is obtained, and the payment amount is compared with the driver's wallet balance. When the payment amount is greater than the driver's wallet balance, a corresponding prompt message is generated; when the payment amount is less than or equal to the driver's wallet balance, the final comparison result is considered to match.
[0068] Example 2
[0069] This embodiment is an application example of Embodiment 1.
[0070] like Figure 3 As shown, under the matchmaking of the financial service platform, the logistics company signs a logistics loan contract with the financial institution, and uses a smart contract to pay the freight to the driver in a targeted manner, and stipulates that the driver can only use the freight in designated consumption scenarios.
[0071] Among them, smart contracts are self-executing computer programs that automatically execute the terms of an agreement between parties. Blockchain is a decentralized distributed ledger technology used to record and verify transactions. Smart contracts are built on blockchain technology, allowing multiple parties to access and update distributed ledgers in a secure and transparent manner, and ensuring that their records are tamper-proof, thereby improving data and system security.
[0072] The financial service platform is mainly responsible for the processing of freight loan business and the use of smart contracts. Smart contract generation is completed by the smart contract platform. The blockchain network provides data services such as trusted storage, transaction verification, and multi-party consensus for all participating institutions. It adopts decentralized file storage, and the blockchain network deploys multiple nodes. The nodes use consensus algorithms as consensus mechanisms to achieve transaction consensus. The smart contract platform mainly includes modules such as user management, contract management, contract records, access management, contract operation, and blockchain browser. User management provides functions such as user registration, authentication, key management, user role and permission management. Contract management includes functions such as contract warehouse, contract development, contract review, and contract deployment. The contract warehouse is used to store smart contract templates and smart contracts; contract development provides a web version of the contract IDE to develop smart contracts, including creating or uploading contract templates, creating or editing contracts, static analysis, saving, compiling, and submitting for review; contract review supports viewing the list of contracts submitted for review by all users, and reviews the contracts; contract deployment deploys the contracts that have passed the review, and can view the contract details. Contract records provide conditional queries on contract content, status, and execution records. Access management is used to connect with various participating institutions and verify the legitimacy of data. Contract operations include contract loaders and business condition triggers, which provide users with services such as contract signing, contract execution or termination, contract condition registration, and contract cancellation. The contract loader is used to monitor external smart contract call requests; business condition triggers provide various events triggered by external trusted data, such as timed events. The blockchain browser provides data overview, block information query, and transaction information query, and can query information such as the number of nodes, number of transactions, number of blocks, number of deployed contracts, and transaction statistics.
[0073] Based on the above application background, Figure 2 As shown, the freight directional payment method of this embodiment mainly includes the following steps:
[0074] S1. The smart contract platform generates the first smart contract based on the loan contract information of the logistics company applying for a special freight loan and publishes it to the blockchain network.
[0075] Logistics companies applying for freight-specific loans must first register on the platform and undergo real-name authentication. After real-name authentication, the platform submits the logistics company information to the smart contract platform and obtains and saves the logistics company's unique user ID in the smart contract platform. The loan contract information for logistics companies applying for freight-specific loans mainly includes user ID, loan number, loan date, loan amount, logistics company wallet, driver freight collection, loan purpose and targeted use scenarios. The driver freight collection includes the driver's name, driver wallet and driver freight.
[0076] Generate the first smart contract based on the loan contract information. The smart contract platform is responsible for the development, review and deployment of smart contracts. The financial service platform passes the loan contract information to the smart contract platform through access management. When developing smart contracts, you need to create or import a contract template first. The contract template is a pre-written template code that is customized for different use case types. It can simplify the development process of smart contracts and reduce the risk of errors or vulnerabilities. The contract template includes key content such as contract details, rules and conditions, payment terms, and security measures. The contract details include information about the parties to the transaction. The rules and conditions include the completion standards of specific activities and the conditions that must be met for the payment of funds. The payment terms include the amount to be paid and the time frame. The security measures ensure that the smart contract is secure and cannot be tampered with, including multi-factor authentication, encryption and other security protocols. By determining these key contents, the smart contract makes targeted payments of funds in a safe, efficient and transparent manner, ensuring that the special funds are used for their intended purposes and reducing the possibility of fraud or abuse. Further, according to business needs, a specific contract template is selected from the contract warehouse, and the key information is matched and filled with the contract template. The contract details include information about the logistics company, financial institution, and driver. The rules and conditions stipulate that the payment terms are triggered when the financial institution issues the specified freight, i.e., the loan amount, to the logistics company's wallet. The payment terms stipulate that the freight is paid from the logistics company's wallet to the driver's wallet. Based on the homomorphic encryption algorithm, all symmetric keys and unique smart contract identifiers of the first smart contract are configured, the contract private key and the corresponding contract public key are generated, the contract private key is used to generate the hash value of the signature, and the business logic of the contract is verified to verify the accuracy of the contract, and the contract file is compiled. If the contract compilation fails, it can be modified according to the prompt information until the compilation is successful. After the contract is successfully compiled, it is submitted for review, and the smart contract is approved according to the preset approval flow. After the smart contract is reviewed and passed, the contract is deployed. When deploying the contract, it is necessary to ensure that the contract code is consistent with the contract text, and the first smart contract is published to the blockchain network through access management. Specifically, a smart contract deployment transaction is initiated to broadcast the first smart contract to the blockchain network. The blockchain network includes N consensus nodes, where N is an integer greater than or equal to 3. The blockchain network is configured to store the first smart contract in the blockchain when the verification results of the N consensus nodes meet the deployment consensus conditions. N consensus nodes can reach transaction consensus according to any consensus mechanism such as Proof of Work (POW), Proof of Stake (POS), Delegated Proof of Stake (DPOS), Practical Byzantine Fault Tolerance (PBFT) and Proof of Participation (Proof of Participation), and upload the transaction to the chain after reaching consensus.
[0077] S2. The financial service platform obtains the loan result information and queries the corresponding first smart contract from the blockchain network according to the smart contract identifier, verifies the key content in the smart contract, and calls the first smart contract through the verification request, and the freight is paid to the driver's wallet in a targeted manner.
[0078] Step S2 is specifically as follows: when the financial institution issues the freight payment to the logistics company wallet, the financial institution notifies the financial service platform of the loan result information, and the financial service platform obtains the loan number in the loan result information, and queries the corresponding smart contract identifier according to the loan number. Further, the financial service platform queries the corresponding first smart contract from the blockchain network according to the smart contract identifier, verifies the key content in the smart contract, specifically, verifies whether the logistics company wallet, loan number, loan date, and loan amount match, and uses the contract public key to verify the signed Hash value. After the verification is passed, the platform requests to call the first smart contract, and the contract loader monitors the external smart contract call request in real time. According to the smart contract identifier in the request, the first smart contract is pulled and verified from the contract warehouse, and then the corresponding contract execution body is pulled and loaded. The smart contract platform assembles the data message according to the payment terms in the first smart contract to generate a batch payment request, and sends the batch payment request to the financial institution. The payment request includes the smart contract identifier, the logistics company wallet, and the driver freight collection. The financial institution receives the batch payment request, queries the corresponding first smart contract on the blockchain network according to the smart contract identifier, verifies the key content in the smart contract, and verifies the signature hash value using the contract public key. If the verification result is correct, the driver's freight will be transferred from the logistics company wallet to the driver's wallet in batches.
[0079] S3. The financial service platform obtains the execution record of the first smart contract. If the execution is successful, the smart contract platform generates a second smart contract based on the loan contract information and the key information in the first smart contract and publishes it to the blockchain network.
[0080] Step S3 is specifically as follows: the financial service platform obtains the execution record of the first smart contract. If the first smart contract is successfully executed, that is, the freight is paid to the driver's wallet, the smart contract platform is called to generate a second smart contract based on the loan contract information and the key information in the first smart contract. The second smart contract stipulates that the driver can only use the freight in the specified consumption scenario. The key information in the first smart contract includes the driver's freight set, the loan purpose and the targeted use scenario. The merchant category code can identify the merchant's main business scope and industry affiliation, determine the merchant category code set according to the loan purpose and the targeted use scenario, and stipulate that the freight can only be used in the specified consumption scenario according to the merchant category code set. Similarly, smart contract generation includes steps such as contract development, contract review and contract deployment. According to business needs, a specific contract template is selected from the contract warehouse, and the key information is matched and filled with the contract template. The contract details include the merchant category code, financial institutions and driver multi-party information. The rules and conditions stipulate that the payment terms are triggered in the specified consumption scenario, and the payment terms stipulate that the freight is paid by the driver's wallet to the specified consumption scenario. Based on the homomorphic encryption algorithm, all symmetric keys and unique smart contract identifiers of the second smart contract are configured, the contract private key and the corresponding contract public key are generated, the signature hash value is generated using the contract private key, and the contract file is compiled. After the contract is successfully compiled, it is submitted for review and the smart contract is approved according to the preset approval flow. After the smart contract is reviewed and approved, the contract is deployed on the chain, and the second smart contract is published to the blockchain network through access management.
[0081] S4. The financial service platform obtains the payment request sent by the driver, including the driver's information, payment amount and merchant information. When the driver uses freight in a designated consumption scenario, such as paying for refueling, gas or highway tolls, the platform obtains the payment request sent by the driver. The payment request includes the driver's information, payment amount and merchant information. The driver's information includes the driver's name and driver's wallet. The merchant information includes the merchant name, merchant category code and merchant collection account.
[0082] S5. The financial service platform queries the corresponding second smart contract from the blockchain network according to the smart contract identifier, compares the received payment request with the key information in the second smart contract, and obtains the comparison result.
[0083] Step S5 is specifically as follows: the financial service platform queries the corresponding second smart contract from the blockchain network according to the smart contract identifier, obtains key information in the second smart contract, including the driver freight set and the merchant category code set, and uses the contract public key to verify the signed Hash value. After verification, the driver information in the received payment request is compared with the driver freight set in the second smart contract. If the driver name and driver wallet in the driver information are inconsistent with the driver freight set, a corresponding prompt message is generated. If the driver name and driver wallet in the driver information are consistent with the driver freight set, the merchant information in the payment request is continued to be compared with the merchant category code set in the second smart contract, and the merchant category code in the payment request is compared with the merchant category code set in the second smart contract. If the result does not match, a corresponding prompt message is generated. If the result matches, the driver wallet balance is obtained, and the payment amount is compared with the driver wallet balance. When the payment amount is greater than the driver wallet balance, the result does not match and a corresponding prompt message is generated. When the payment amount is less than or equal to the driver wallet balance, the result matches.
[0084] S6. The financial service platform calls the second smart contract based on the comparison result. If the result matches, the second smart contract transfers the payment amount from the driver's wallet to the merchant's payment account.
[0085] Step S6 is specifically as follows: the financial service platform obtains the comparison result of the payment request and the key information in the second smart contract. If the result matches, the financial service platform requests to call the second smart contract. The contract loader monitors the external smart contract call request, and pulls and verifies the second smart contract from the contract warehouse according to the smart contract identifier in the request, and then pulls and loads the corresponding contract execution body. According to the payment terms of the second smart contract, assemble the data message, and send the payment request to the financial institution. The payment request includes the smart contract identifier, payment amount, driver wallet and merchant payment account. The financial institution obtains the payment request, queries the corresponding second smart contract from the blockchain network according to the smart contract identifier, verifies the key content in the smart contract, and verifies the signed Hash value using the contract public key. After the verification is passed, the payment amount is transferred from the driver wallet to the merchant payment account.
[0086] It can be seen that this embodiment achieves precise control over the flow of loan funds, ensures that the funds are used strictly in accordance with the agreed purpose, improves the security of fund circulation, and reduces the possibility of fraud or abuse, while effectively controlling risks.
[0087] Example 3
[0088] This embodiment is a system for implementing the above method embodiment.
[0089] The blockchain-based freight directional payment system of this embodiment includes a financial service platform and a smart contract platform, wherein:
[0090] A smart contract platform is used to generate a first smart contract based on the loan contract information of the logistics company applying for a special freight loan and publish it to the blockchain network; and when the first smart contract is successfully executed, a second smart contract is generated based on the loan contract information and key information in the first smart contract and published to the blockchain network;
[0091] The financial service platform is used to obtain the loan result information of the financial institution and query the corresponding first smart contract from the blockchain network according to the smart contract identifier, verify the key content in the first smart contract, and if the verification passes, request to call the first smart contract to transfer the driver's freight from the logistics company wallet to the corresponding driver wallet in batches through the first smart contract;
[0092] The financial service platform is also used to obtain the payment request sent by the driver, which is the payment request sent by the driver when using the freight in the driver's wallet in a designated consumption scenario; query the corresponding second smart contract from the blockchain network according to the smart contract identifier, and compare the received payment request with the key information in the second smart contract; if the comparison result matches, request to call the second smart contract, and transfer the payment amount from the driver's wallet to the merchant's payment account according to the second smart contract.
[0093] The main functions of the financial service platform and the smart contract platform are to implement the various steps of the method implementation example, which will not be described here one by one.
[0094] The present application also provides a computer-readable storage medium, such as a flash memory, a hard disk, a multimedia card, a card-type memory (e.g., SD or DX memory, etc.), a random access memory (RAM), a static random access memory (SRAM), a read-only memory (ROM), an electrically erasable programmable read-only memory (EEPROM), a programmable read-only memory (PROM), a magnetic memory, a disk, an optical disk, a server, an App application store, etc., on which a computer program is stored, and when the program is executed by a processor, a corresponding function is realized. When the computer-readable storage medium of this embodiment is executed by a processor, the blockchain-based freight directional payment method of the method embodiment is realized.
[0095] It should be pointed out that, according to the needs of implementation, the various steps / components described in this application can be split into more steps / components, and two or more steps / components or partial operations of steps / components can be combined into new steps / components to achieve the purpose of the present invention.
[0096] The order of execution of each step in the above embodiment does not mean the order of execution. The order of execution of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present application.
[0097] It should be understood that those skilled in the art can make improvements or changes based on the above description, and all these improvements and changes should fall within the scope of protection of the appended claims of the present invention.
Claims
1. A blockchain-based freight directional payment method, characterized in that: The following steps are involved: S1. The smart contract platform generates the first smart contract based on the loan contract information of the logistics company applying for a special freight loan and publishes it to the blockchain network; S2. The financial service platform obtains the loan result information and queries the corresponding first smart contract from the blockchain network according to the smart contract identifier, verifies the key content in the first smart contract, and if the verification passes, requests to call the first smart contract to transfer the driver's freight from the logistics company wallet to the corresponding driver wallet in batches through the first smart contract; S3. The financial service platform obtains the execution record of the first smart contract. If the execution is successful, the smart contract platform generates a second smart contract based on the loan contract information and key information in the first smart contract and publishes it to the blockchain network; S4. The financial service platform obtains a payment request sent by the driver, where the payment request is a payment request sent by the driver when using the freight in the driver's wallet in a specified consumption scenario; S5. The financial service platform queries the corresponding second smart contract from the blockchain network according to the smart contract identifier, and compares the received payment request with the key information in the second smart contract; S6. If the comparison result matches, a request is made to call the second smart contract, and the payment amount is transferred from the driver's wallet to the merchant's payment account according to the second smart contract.
2. The blockchain-based freight directional payment method according to claim 1, characterized in that: The first smart contract includes multi-party information of the logistics company, financial institution and driver, as well as loan rules and conditions. It stipulates that when the financial institution disburses the designated loan amount for freight to the logistics company wallet, the payment terms are triggered. The payment terms stipulate that the freight will be paid from the logistics company wallet to the driver wallet.
3. The blockchain-based freight directional payment method according to claim 1, characterized in that: The payment request sent by the driver includes the driver's information, payment amount and merchant information. The driver's information includes the driver's name and driver's wallet. The merchant information includes the merchant's name, merchant category code and merchant payment account.
4. The blockchain-based freight directional payment method according to claim 1, characterized in that: Designated consumption scenarios include paying for refueling, gas or highway tolls, etc.
5. The blockchain-based freight directional payment method according to claim 1, characterized in that: In step S2, the process of verifying the first smart contract specifically includes: The financial service platform requests to call the first smart contract. The first smart contract assembles data messages according to the payment terms, generates batch payment requests and sends them to the financial institution. The payment request includes the smart contract identifier, the logistics company wallet and the driver's freight collection. The financial institution obtains the batch payment request, queries the corresponding first smart contract on the blockchain network according to the smart contract identifier, verifies the key content in the first smart contract, and verifies the signed hash value using the contract public key. If the verification result is correct, the driver's freight will be transferred from the logistics company wallet to the driver's wallet in batches.
6. The blockchain-based freight directional payment method according to claim 1, characterized in that: In step S2, the corresponding smart contract identifier is specifically queried through the loan number. When the financial institution issues the freight payment to the logistics company wallet, the financial institution notifies the financial service platform of the loan result information, and the financial service platform obtains the loan number from the loan result information.
7. The blockchain-based freight directional payment method according to claim 1, characterized in that: Step S5 is specifically as follows: Query the corresponding second smart contract from the blockchain network according to the smart contract identifier; Based on the key information obtained from the second smart contract, the signed Hash value is verified using the contract public key; After verification, the driver information in the received payment request is compared with the driver freight set in the second smart contract; If they are inconsistent, a corresponding prompt message is generated; If they are consistent, the merchant information in the payment request will continue to be compared with the merchant category code set in the second smart contract. If they are inconsistent, a corresponding prompt message will be generated; if they are consistent, the driver's wallet balance will be obtained, and the payment amount will be compared with the driver's wallet balance. When the payment amount is greater than the driver's wallet balance, a corresponding prompt message will be generated; when the payment amount is less than or equal to the driver's wallet balance, the final comparison result is considered to match.
8. The blockchain-based freight directional payment method according to claim 1, characterized in that: Generating the first smart contract in step S1 specifically includes the following steps: Based on the homomorphic encryption algorithm, configure all symmetric keys and unique smart contract identifiers of the first smart contract, generate a contract private key and a corresponding contract public key, use the contract private key to generate a signed hash value, verify the business logic of the contract, verify the accuracy of the contract, and compile the contract file; After the contract is compiled successfully, it is submitted for review and the first smart contract is approved according to the preset approval process; After the first smart contract is reviewed and approved, the contract is deployed and published to the blockchain network through access management.
9. A blockchain-based freight directional payment system, characterized in that: Including financial service platform and smart contract platform, among which: A smart contract platform is used to generate a first smart contract based on the loan contract information of the logistics company applying for a special freight loan and publish it to the blockchain network; and when the first smart contract is successfully executed, a second smart contract is generated based on the loan contract information and key information in the first smart contract and published to the blockchain network; The financial service platform is used to obtain the loan result information of the financial institution and query the corresponding first smart contract from the blockchain network according to the smart contract identifier, verify the key content in the first smart contract, and if the verification passes, request to call the first smart contract to transfer the driver's freight from the logistics company wallet to the corresponding driver wallet in batches through the first smart contract; The financial service platform is also used to obtain the payment request sent by the driver, which is the payment request sent by the driver when using the freight in the driver's wallet in a designated consumption scenario; query the corresponding second smart contract from the blockchain network according to the smart contract identifier, and compare the received payment request with the key information in the second smart contract; if the comparison result matches, request to call the second smart contract, and transfer the payment amount from the driver's wallet to the merchant's payment account according to the second smart contract.
10. A computer storage medium, characterized in that: A computer program executable by a processor is stored therein, and the computer program executes the blockchain-based targeted freight payment method described in any one of claims 1 to 8.
Citation Information
Patent Citations
Logistics platform commercial-operation mode
CN108364154A
Logistics distribution and cash flow payment method and system based on block chain
CN111047260A
Marine freight data processing method, device, equipment and system
CN113191865A
Operation execution method, device and equipment of transportation task and storage medium
CN117172636A
Independent detachable parts prefabricated clothes dryer
KR1020210099394A