Import and export order tracking method and system based on blockchain

By adopting blockchain technology in import and export order management, public and private key pairs are generated and distributed, order information is encrypted and uploaded to blockchain storage, the import and export order information in the existing technology is solved. The low security and low credibility of import and export order information in the existing technology is solved. The problem of the order status has been trusted and transparently tracked.

CN117745168BActive Publication Date: 2025-02-18HANGZHOU HUILIAN TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311806794.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-12-26
Publication Date
2025-02-18
Estimated Expiration
2043-12-26

AI Technical Summary

Technical Problem

The existing import and export order management plans rely on paper documents, which poses the risk of forgery, and electronic data is easily tampered with, resulting in low security and low credibility of information.

Method used

Using a blockchain-based import and export order tracking method, by receiving order information submitted by the order initiator, a public-private key pair is generated and a private key is distributed, and the initial order information is generated based on the order ID and public key, and then encrypted and uploaded to the area. Blockchain storage. Participants can obtain initial and tracking information by viewing the request and update the order status through the status advancement instruction signed by the private key.

Benefits of technology

It has achieved trustworthy and transparent tracking of import and export orders, guaranteed the safety and reliability of order status, prevented forgery and tampering, and ensured the interests of all participants.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117745168B_ABST
    Figure CN117745168B_ABST
Patent Text Reader

Abstract

The embodiment of this specification discloses a method and system for tracking import and export orders based on blockchain, which includes: receiving order initiation information submitted by the initiator; generating a corresponding number of public-private key pairs based on the number of participating nodes, and distributing the private key to the corresponding participants; generating initial order information based on the order ID, order information and public key, encrypting the initial order information and uploading it to blockchain for storage; receiving a viewing request submitted by a participant, querying the blockchain, obtaining the initial order information and all tracking information, and the tracking information includes a state advancement instruction signed by the private key of the participant; generating the current order tracking information based on the decrypted initial order information and all tracking information as a response to the viewing request. The system includes: an order initiation module, an order generation module, and an order tracking module.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] One or more embodiments of this specification relate to the field of information technology, and specifically to a blockchain-based import and export order tracking method and system. Background Art

[0002] At present, all import and export orders adopt the management and tracking solutions of paper documents. For example, debts can be formed or paid based on paper bills, and goods can be picked up based on paper bills of lading or warehouse receipts. Since paper documents are likely to be forged, it brings the risk of loss of rights and interests to all parties involved in import and export trade. The industry has proposed an electronic import and export warehousing management solution, but electronic data is inherently easy to be tampered with and forged, which is not enough to solve the current problems of low security and low credibility of import and export order information.

[0003] The blockchain is a chain of blocks, each of which stores certain information. They are connected into a chain in the order of their generation. This chain is stored in all servers. These servers are called nodes in the blockchain system, and they provide storage space and computing power support for the entire blockchain system. If you want to modify the information in the blockchain, you must obtain the consent of more than half of the nodes and modify the information in all nodes. These nodes are usually in the hands of different entities, so it is extremely difficult to tamper with the information in the blockchain. Compared with traditional networks, blockchain has two core characteristics: one is that data is difficult to tamper with, and the other is decentralization. Based on these two characteristics, the information recorded in the blockchain is more authentic and reliable, which can help solve the problem of people's distrust. Summary of the invention

[0004] One or more embodiments of this specification describe a blockchain-based import and export order tracking method and system, which can use blockchain to achieve reliable and transparent tracking of import and export orders, helping to ensure the smooth completion of import and export orders.

[0005] In a first aspect, the embodiments of this specification provide a method for tracking import and export orders based on blockchain, comprising the steps of:

[0006] Receiving order initiation information submitted by the order initiator, the order initiation information includes order ID, order information, and participant information, the participant information includes the participant and the order status sequence of the participant;

[0007] Generate a corresponding number of public and private key pairs based on the number of participating nodes, and distribute the private keys to the corresponding participants;

[0008] Based on the order ID, order information and public key, generate initial order information, encrypt the initial order information and upload it to the blockchain for storage;

[0009] Receive a viewing request submitted by a participant, the viewing request includes an order ID, query the blockchain, obtain the initial order information and all tracking information, the tracking information is generated by the participant and encrypted and uploaded to the blockchain, and the tracking information includes a status advancement instruction signed by the participant's private key;

[0010] Generate current order tracking information based on the decrypted initial order information and all tracking information as a response to the viewing request.

[0011] In a second aspect, the embodiments of this specification provide an import and export order tracking system based on blockchain, including:

[0012] An order initiation module is used to receive order initiation information submitted by an order initiator, wherein the order initiation information includes order ID, order information, and participant information, wherein the participant information includes the participant and the order status sequence in which the participant participates;

[0013] An order generation module is used to generate a corresponding number of public-private key pairs based on the number of participating nodes, distribute the private keys to the corresponding participants, and generate initial order information based on the order ID, order information and public key, and encrypt the initial order information and upload it to the blockchain for storage;

[0014] The order tracking module is used to receive a viewing request submitted by a participant, the viewing request includes an order ID, query the blockchain, obtain the initial order information and all tracking information, the tracking information is generated by the participant and uploaded to the blockchain after encryption, the tracking information includes a status advancement instruction signed by the participant's private key, and generate the current order tracking information based on the decrypted initial order information and all tracking information as a response to the viewing request.

[0015] In a third aspect, an embodiment of this specification provides an electronic device, including a processor and a memory;

[0016] The processor is connected to the memory;

[0017] The memory is used to store executable program code;

[0018] The processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the method described in any one of the above aspects.

[0019] In a fourth aspect, embodiments of this specification provide a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method described in one or more embodiments of this specification is implemented.

[0020] The beneficial effects brought by the technical solutions provided by some embodiments of this specification include at least:

[0021] In one or more embodiments of the present specification, the provided import and export order tracking method uses blockchain to store order tracking data, so that the order status promotion information of import and export orders is credible and transparent, which helps to ensure that the order status changes of import and export orders are safer, and also helps to ensure that import and export orders are promoted more reliably; with the help of improved tracking information generation and verification schemes, the changes in order status are strictly in accordance with the pre-configured order status order, thereby protecting the interests of all parties involved in the import and export orders.

[0022] Other features and advantages of one or more embodiments of the present specification will be further disclosed in the following detailed description and drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] In order to more clearly illustrate the technical solutions in the embodiments of this specification, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0024] Figure 1 This is a schematic diagram of an application scenario of the import and export order tracking method provided in the embodiments of this specification.

[0025] Figure 2 A schematic diagram of the order status sequence of import and export orders provided in the embodiments of this specification.

[0026] Figure 3 This is another order status sequence diagram of import and export orders provided in the embodiments of this specification.

[0027] Figure 4 This is a schematic diagram of the import and export order tracking method architecture provided in the embodiments of this specification.

[0028] Figure 5 This is a schematic diagram of the interface for implementing the import and export order tracking method provided in the embodiments of this specification.

[0029] Figure 6 This is a flow chart of the import and export order tracking method provided in the embodiments of this specification.

[0030] Figure 7 A flowchart of a method for distributing private keys provided in an embodiment of this specification.

[0031] Figure 8 This is a flow chart of a method for generating order tracking information provided in an embodiment of this specification.

[0032] Fig. 9A schematic diagram of effective tracking information provided in an embodiment of this specification.

[0033] Fig.10 A flowchart of a verification status advancement instruction method provided in an embodiment of this specification.

[0034] Fig.11 This is a schematic diagram of the import and export order tracking system provided in the embodiments of this specification.

[0035] Fig.12 A schematic diagram of an electronic device provided in an embodiment of this specification.

[0036] Among them: 11. Initiator, 12. Participants, 20. Order tracking system, 21. Self-tracking list, 22. Tracking list, 221. Agent purchase order list, 222. Autonomous purchase order list, 23. To-do reminder, 24. Tracking order, 30. Blockchain, 100. Order initiation module, 200. Order generation module, 201. Secret key generation submodule, 202. Alternative public key submodule, 203. Secret key distribution submodule, 204. Order information generation submodule, 300. Order tracking module, 1100. Electronic device, 1101. Processor, 1102. Communication bus, 1103. User interface, 1104. Network interface, 1105. Memory. DETAILED DESCRIPTION

[0037] The following is an explanation and description of the technical solutions of the embodiments of this specification in conjunction with the drawings of the embodiments of this specification, but the following embodiments are only preferred embodiments of this specification, not all. Based on the embodiments in the implementation mode, other embodiments obtained by those skilled in the art without creative work are all within the scope of protection of this specification.

[0038] The terms "first", "second", "third", etc. in the description and claims of this specification and the above-mentioned drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but optionally includes steps or units that are not listed, or optionally includes other steps or units inherent to these processes, methods, products or devices.

[0039] In the following description, terms such as "inside", "outside", "up", "down", "left", "right", etc. that indicate directions or positional relationships are only used to facilitate the description of the embodiments and simplify the description, and do not indicate or imply that the device or element referred to must have a specific direction, be constructed and operated in a specific direction, and therefore should not be understood as a limitation of this specification.

[0040] The data involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection of relevant data complies with the relevant laws, regulations and standards of relevant countries and regions.

[0041] Before introducing the technical solutions of the embodiments of this specification, the application scenarios of one or more embodiments of this specification are introduced.

[0042] Glossary

[0043] Initiator

[0044] The initiator referred to in this specification refers to the subject that initiates the tracking of import and export orders with the help of blockchain 30. The initiator 11 can still act as a participant 12, and after initiating order tracking, participate in order tracking as a participant 12. The initiator 11 can be a stakeholder involved in the import and export order, such as an industry party, a supply chain service provider, or a third party, such as an import and export order management platform, a regulator, an industry association, etc.

[0045] Participants

[0046] The participants referred to in this specification are the entities involved in the tracking process of import and export orders on the blockchain 30. Participants 12 can be the rights and interests parties involved in the import and export orders, such as the industry party, the supply chain service party, or a third party, such as the import and export order management platform, the regulator, the industry association, etc. Among them, when the participant 12 is the rights and interests party involved in the import and export order, it can promote the progress of the import and export order by uploading the tracking information including the state advancement instruction signed by the private key of the participant 12 to the blockchain 30. For example, the accepting bank can advance the import and export order from the order state of opening a letter of credit to the acceptance state by uploading the corresponding tracking information. Other participants 12 can view the state change. The initial order information and tracking information are both in encrypted form on the blockchain 30, and the initiator 11 and the participant 12 also need to perform identity authentication before they can view and decrypt the initial order information and tracking information. The identity authentication of the initiator 11 and the participant 12 can be performed using the public technology in the field, and one or more embodiments recorded in this specification do not make improvements to the identity authentication technology.

[0047] Status Advance Instructions

[0048] The state advancement instruction referred to in this specification refers to an identifier used to represent the downward advancement of the order state. The downward advancement refers to the advancement from the current order state to the next order state in the order state sequence. Exemplarily, the specific identification form can be expressed by a dynamic instruction, such as the order state is advanced downward by one order, or by a dynamic result instruction, such as the order state is advanced to acceptance.

[0049] Public-private key pair

[0050] The public-private key pair referred to in this specification involves the public key and private key in an asymmetric encryption algorithm. An asymmetric encryption algorithm refers to an encryption algorithm in which the encryption key and decryption key are different, or in other words, the encryption algorithm of one key cannot be derived from the other key. Asymmetric key is also called public key encryption, which uses two mathematically related keys to encode information. In this system, one of the keys is called the public key, which can be sent at will to anyone who wants to communicate securely with the key holder. The public key is used to encrypt information. The second key is the private key, which belongs to the key holder. The key holder uses the private key to decrypt the received information. Exemplary algorithms include the RSA algorithm, the DSA algorithm, the ECC algorithm, and the DH algorithm.

[0051] Application Scenario Introduction

[0052] The execution process of import and export orders involves multiple parties12, such as the industry as the buyer, the supplier as the seller, the supply chain service provider that undertakes comprehensive services such as freight, customs clearance, and payment, as well as the bank or other financial institution that provides financing or guarantees, and the warehousing party that provides warehousing during the process. Figure 1 , each participant 12 has a cooperative relationship, and each participant 12 also needs to check the order status. For example, the industry needs to pay the settlement money to the bank before the bank allows the warehouse to deliver the goods to the industry. If the warehouse delivers the goods to the industry without waiting for the industry to complete the settlement with the bank, it will cause the bank's debt realization to face the dilemma of increased difficulty, and even cause financial losses. For example, if the industry provides a forged settlement certificate to the warehouse and then delivers the goods, this situation will occur. For this reason, it is necessary to study a technology for advancing order status certificates that cannot be forged. The import and export order tracking method recorded in one or more embodiments provided in this specification is adopted, and the order status is tracked with the help of blockchain 30, so that the order status cannot be forged, and the change of the order status will also have a record that cannot be tampered with or erased, which can effectively deal with the problem of low credibility of import and export order tracking.

[0053] For example, please see the attached Figure 2, the order status sequence of the import and export order is <initiate, freight forwarder, issue letter of credit, acceptance, customs declaration and unloading, exchange bill and pick up container, unpacking and sampling, customs release, settlement and invoicing, warehouse pick up>, and the participants 12 include the industry party, the freight party, the billing bank, the acceptance bank, the supply chain service provider, and the settlement bank. It should be noted that the freight party can be introduced by the supply chain service provider, or directly provided by the transportation capacity owned by the supply chain service provider. The billing bank and the settlement bank can be the same bank or different banks. The billing bank and the acceptance bank can also be branches of the same bank in different regions, or different banks. The billing bank, the acceptance bank and the settlement bank can also be other types of financial institutions that can provide corresponding services. The industry party is the buyer, and the freight party connects with the seller, receiving the goods and carrying them when the seller ships.

[0054] As another example, when the industry party does not need the involvement of the bank and directly completes the fund delivery with the seller, please refer to the attached Figure 3 The order status sequence of the import and export order is <initiate, freight forwarder, customs clearance and unloading, bill exchange and container pickup, unpacking and sampling, customs clearance, warehouse pickup>, and the participants 12 include the industry party, freight party, billing bank, acceptance bank, supply chain service party, and settlement bank. It should be noted that the freight party can be introduced by the supply chain service party, or directly provided by the transportation capacity owned by the supply chain service party.

[0055] This specification first provides a method for tracking import and export orders based on blockchain 30. Figure 4 The implementation architecture of the method is that an order tracking system 20 is configured between the initiator 11, the participant 12 and the blockchain 30, and the order tracking system 20 provides a login service. During the login service process, the identity authentication of the initiator 11 and the participant 12 is realized. After the login is completed, according to the different identities of the login person, the order tracking system 20 receives the interactive operations of the initiator 11 and the participant 12, and interacts with the blockchain 30 system based on the interactive operations, and uploads the corresponding data to the blockchain 30 for storage or downloads the corresponding data from the blockchain 30.

[0056] For example, please see the attached Figure 5 This specification provides a schematic diagram of the operation interface of an order tracking system 20. The top row includes a self-tracking list 21, a tracking list 22, and a to-do reminder 23. The self-tracking list 21 records import and export orders that do not require the participation of other participants 12, and is used to facilitate the management of its own orders. The tracking list 22 records the tracking of import and export orders that involve other participants. The import and export orders recorded in the tracking list 22 are classified into an agent purchase order list 221 and an independent purchase order list 222. The order status sequence of the import and export orders in the agent purchase order list 221 is shown in the attached figure. Figure 2 As shown, the order status sequence of the import and export orders in the autonomous purchase order list 222 is as shown in the attached Figure 3 As shown. The following shows the tracking orders 24 included in the selected list. Clicking on the tracking order 24 can initiate a viewing request. Based on the response obtained from the viewing request, the order information is displayed, and when the order information is displayed, an operation area for uploading the tracking information is provided. The to-do prompt 23 shows the current login user, the tracking orders 24 that can generate valid status advancement instructions, and other to-do items. Each login user can track multiple import and export orders.

[0057] Please refer to the attached Figure 6 , the import and export order tracking method based on blockchain 30 includes the steps of:

[0058] Step 102) receiving order initiation information submitted by the initiator 11, wherein the order initiation information includes order ID, order information, and participant 12 information, wherein the participant 12 information includes the participant 12 and the order status sequence in which the participant 12 participates;

[0059] Step 104) Generate a corresponding number of public-private key pairs based on the number of participants 12, and distribute the private keys to the corresponding participants 12;

[0060] Step 106) Based on the order ID, order information and public key, generate initial order information, encrypt the initial order information and upload it to the blockchain 30 for storage;

[0061] Step 108) receiving a viewing request submitted by the participant 12, the viewing request including the order ID, querying the blockchain 30, obtaining the initial order information and all tracking information, the tracking information generated by the participant 12 and encrypted and uploaded to the blockchain 30, the tracking information including the status advancement instruction signed by the private key of the participant 12;

[0062] Step 110 ) Generate current order tracking information based on the decrypted initial order information and all tracking information as a response to the viewing request.

[0063] The generation of the order ID is carried out using the technology already mastered in this field, and the order ID should be unique. Each participant 12 will be assigned a bunch of public and private keys in the tracking of each import and export order for tracking the import and export order. The order information includes the buyer, seller, name of the goods, quantity, total price, place of shipment, place of receipt, and type of insurance. The initial order information includes the order ID, order information, and public key. When encrypting the initial order information, the encryption and decryption technology already disclosed in this field can be used. The signature indicates encryption using a private key, and the corresponding public key can decrypt. Since the private key is only possessed by the corresponding participant 12, the signature can be used to indicate the identity.

[0064] On the other hand, in another embodiment, a corresponding number of public-private key pairs are generated based on the number of participants 12, and a method of distributing the private key to the corresponding participants 12 is shown in the attached Figure 7 , including the steps of:

[0065] Step 202) Generate a corresponding number of public-private key pairs, and assign a public-private key pair to each participant 12;

[0066] Step 204) sorting the public and private key pairs according to the order status of the participants 12;

[0067] Step 206) Starting from the second public-private key pair, calculate the quotient of each public key and the previous public key, and record it as the replacement public key;

[0068] Step 208) Distribute the first public-private key pair to the first participant 12 in the order status sequence, and send the replacement public key and the corresponding private key to the subsequent corresponding participants 12;

[0069] Step 210) The public key of the first party 12 in the order status sequence is included in the initial order information.

[0070] The private key and public key of the asymmetric encryption algorithm are both integers. For example, the secp256k1 algorithm in the ECC algorithm generates a private key length of 256 bits and a public key length of 512 bits. The quotient generated by dividing the public key has decimal places, that is, the replacement public key has a decimal. The replacement public key is kept with enough decimal places so that the product of the replacement public key and the previous public key can get the correct public key after rounding the decimal part.

[0071] When this embodiment is adopted, when the previous order status is not advanced, the corresponding substitute public key is not disclosed, so that the public key corresponding to the next order status cannot be calculated, resulting in that even if the corresponding participant 12 has signed the status advancement instruction, it cannot be verified due to the lack of the public key. Therefore, the jump change of the order status is technically prevented. That is, when one of the participants 12 does not sign the status advancement instruction, the subsequent participants 12 in the order status sequence are technically unable to sign a valid status advancement instruction. On the other hand, in another embodiment, the tracking information includes the substitute public key.

[0072] On the other hand, in another embodiment, please refer to the attached Figure 8 The method for generating current order tracking information based on the decrypted initial order information and all tracking information comprises the steps of:

[0073] Step 302) Sort the decrypted initial order information and all tracking information in the order of time of uploading blockchain 30, and record it as the tracking sequence;

[0074] Step 304) sequentially verifying the state advancement instructions of the tracking information contained in the tracking sequence, and recording the tracking information that passes the verification as valid tracking information;

[0075] Step 306) Generate current order tracking information based on the decrypted initial order information and all valid tracking information.

[0076] Please see attached Fig. 9 , when the freight forwarder signs the tracking information with the status advancement instruction for accepting the freight, the order status changes from initiation to freight forwarding status. After that, when the industry signs the tracking information with the status advancement instruction for picking up the goods and uploads it to the blockchain 30 for storage, it will be invalid because it cannot calculate the correct public key, and thus cannot decrypt and verify the status advancement instruction. The order status will not change. At this time, the order status will only be advanced when the issuing bank signs the tracking information with the status advancement instruction for approving the issuance of the letter of credit.

[0077] On the other hand, in another embodiment, please refer to the attached Fig.10 , the method for verifying the state advancement instruction contained in the tracking information comprises the steps of:

[0078] Step 402) traverse each tracking information starting from the first tracking information of the tracking sequence, and perform the following steps for each tracking information:

[0079] Step 404) After merging the same substitute public keys, calculate the product of the substitute public key included in the current tracking information and the substitute public key of the tracking information in the previous order, and then multiply it by the public key included in the initial order information, and record it as the current public key;

[0080] Step 406) Use the current public key to decrypt the state advancement instruction included in the current tracking information. If the decryption is successful, it is determined that the state advancement instruction included in the current tracking information has been verified. If the decryption is unsuccessful, the current tracking information is removed from the tracking sequence.

[0081] On the other hand, in another embodiment, the tracking information includes remarks information signed by the private key of the participant 12;

[0082] The method for generating current order tracking information based on the decrypted initial order information and all tracking information comprises the steps of:

[0083] Get the current order status based on all tracking information;

[0084] Generate current order tracking information based on current order status, initial order information, and all note information.

[0085] On the other hand, this specification provides an import and export order tracking system 20 based on blockchain 30, please refer to the attached Fig.11 ,include:

[0086] The order initiation module 100 is used to receive order initiation information submitted by the initiator 11, wherein the order initiation information includes order ID, order information, and participant 12 information, wherein the participant 12 information includes the participant 12 and the order status sequence in which the participant 12 participates;

[0087] The order generation module 200 is used to generate a corresponding number of public-private key pairs based on the number of participants 12, distribute the private key to the corresponding participants 12, and generate initial order information based on the order ID, order information and public key, and encrypt the initial order information and upload it to the blockchain 30 for storage;

[0088] The order tracking module 300 is used to receive a viewing request submitted by a participant 12, wherein the viewing request includes an order ID, query the blockchain 30, obtain the initial order information and all tracking information, wherein the tracking information is generated by the participant 12 and uploaded to the blockchain 30 after being encrypted, wherein the tracking information includes a status advancement instruction signed by the private key of the participant 12, and generates the current order tracking information based on the decrypted initial order information and all tracking information as a response to the viewing request.

[0089] On the other hand, in another embodiment, the order generation module 200 includes:

[0090] The key generation submodule 201 is used to generate a corresponding number of public and private key pairs, assign a public and private key pair to each participant 12, and sort the public and private key pairs according to the order status of the participants 12;

[0091] The replacement public key submodule 202 is used to calculate the quotient of each public key and the previous public key starting from the second public-private key pair, and record it as a replacement public key;

[0092] The key distribution submodule 203 is used to distribute the first public-private key pair to the first participant 12 in the order status sequence, and send the replacement public key and the corresponding private key to the subsequent corresponding participants 12;

[0093] The order information generation submodule 204 is used to include the public key of the first participant 12 in the order status sequence into the initial order information, and generate the initial order information based on the order ID, order information and public key, and encrypt the initial order information and upload it to the blockchain 30 for storage.

[0094] See also Fig.12 A schematic diagram of the structure of an electronic device provided in an embodiment of this specification is shown.

[0095] like Fig.12 As shown, the electronic device 1100 may include: at least one processor 1101, at least one network interface 1104, a user interface 1103, a memory 1105 and at least one communication bus 1102. Among them, the communication bus 1102 can be used to realize the connection and communication of the above-mentioned components. Among them, the user interface 1103 may include a button, and the optional user interface may also include a standard wired interface and a wireless interface. Among them, the network interface 1104 may include but is not limited to a Bluetooth module, an NFC module, a Wi-Fi module, etc. Among them, the processor 1101 may include one or more processing cores. The processor 1101 uses various interfaces and lines to connect the various parts of the entire electronic device 1100, and executes various functions and processes data of the routing device 1100 by running or executing instructions, programs, code sets or instruction sets stored in the memory 1105, and calling data stored in the memory 1105. Optionally, the processor 1101 can be implemented in at least one hardware form of DSP, FPGA, and PLA. The processor 1101 can integrate one or a combination of CPU, GPU, modem, etc. Among them, the CPU mainly handles the operating system, user interface, and applications; the GPU is responsible for rendering and drawing the content that needs to be displayed on the display; and the modem is used to handle wireless communications.

[0096] It is understandable that the above-mentioned modem may not be integrated into the processor 1101, but may be implemented by a separate chip.

[0097] Among them, the memory 1105 may include RAM or ROM. Optionally, the memory 1105 includes a non-transitory computer-readable medium. The memory 1105 can be used to store instructions, programs, codes, code sets or instruction sets. The memory 1105 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the above-mentioned various method embodiments, etc.; the data storage area may store data involved in the above-mentioned various method embodiments, etc. The memory 1105 may also be at least one storage device located away from the aforementioned processor 1101. The memory 1105 as a computer storage medium may include an operating system, a network communication module, a user interface module and an application. The processor 1101 may be used to call the application stored in the memory 1105 and execute the method in one or more of the above-mentioned embodiments.

[0098] The embodiments of this specification also provide a computer-readable storage medium, which stores instructions, and when the instructions are executed on a computer or a processor, the computer or the processor executes one or more steps in the above embodiments. If the components of the above electronic device are implemented in the form of software functional units and sold or used as independent products, they can be stored in the computer-readable storage medium.

[0099] In the absence of conflict, the technical features in this embodiment and implementation scheme can be combined arbitrarily.

[0100] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented by software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of this specification is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted through the computer-readable storage medium. The computer instructions can be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (Digital Subscriber Line, DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode. The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server or data center that includes one or more available media integrated. The available medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a digital versatile disc (DVD)), or a semiconductor medium (eg, a solid state drive (SSD)).

[0101] When implemented by hardware or firmware, the aforementioned method flow is programmed into the hardware circuit to obtain the corresponding hardware circuit structure and realize the corresponding function. For example, a programmable logic device (PLD) (such as a field programmable gate array (FPGA)) is such an integrated circuit, and its logic function is determined by the user programming the device. The designer programs by himself to "integrate" a digital system on a PLD, without asking a chip manufacturer to design and make a dedicated integrated circuit chip. Moreover, nowadays, instead of manually making integrated circuit chips, this programming is mostly implemented by "logic compiler" software, which is similar to the software compiler used when writing program development, and the original code before compilation must also be written in a specific programming language, which is called hardware description language (HDL), and HDL is not just one, but many. Those skilled in the art should also be aware that it is only necessary to program the method flow slightly in the above-mentioned hardware description languages ​​and program it into the integrated circuit to easily obtain the hardware circuit that implements the logical method flow.

[0102] The embodiments described above are merely preferred embodiments of this specification and are not intended to limit the scope of this specification. Without departing from the design spirit of this specification, various modifications and improvements made to the technical solutions of this specification by ordinary technicians in this field should fall within the scope of protection determined by the claims of this specification.

Claims

1. The import and export order tracking method based on blockchain is characterized by: Includes steps: Receiving order initiation information submitted by the initiator, the order initiation information includes order ID, order information, and participant information, the participant information includes the participant and the order status sequence of the order in which they participate; Generate a corresponding number of public and private key pairs based on the number of participants, and distribute the private keys to the corresponding participants; Based on the order ID, order information and public key, generate initial order information, encrypt the initial order information and upload it to the blockchain for storage; Receive a viewing request submitted by a participant, the viewing request includes an order ID, query the blockchain, obtain the initial order information and all tracking information, the tracking information is generated by the participant and encrypted and uploaded to the blockchain, and the tracking information includes a status advancement instruction signed by the participant's private key; generating current order tracking information based on the decrypted initial order information and the decrypted complete tracking information as a response to the viewing request; The method of generating a corresponding number of public-private key pairs based on the number of participants and distributing the private keys to the corresponding participants comprises the steps of: Generate a corresponding number of public-private key pairs and assign one public-private key pair to each participant; Sort the public and private key pairs according to the order status of the participants; Starting from the second public-private key pair, calculate the quotient of each public key and the previous public key, and record it as the replacement public key; Distribute the first public-private key pair to the first participant in the order status sequence, and send the replacement public key and the corresponding private key to the subsequent corresponding participants; Include the public key of the first party in the order status sequence in the initial order information; The method for generating current order tracking information based on the decrypted initial order information and the decrypted complete tracking information comprises the steps of: Sort the decrypted initial order information and all decrypted tracking information in the order of uploading the blockchain, and record it as the tracking sequence; Verifying the state advancement instructions of the tracking information contained in the tracking sequence in sequence, and recording the tracking information that passes the verification as valid tracking information; Generate current order tracking information based on the decrypted initial order information and all decrypted valid tracking information; The method for verifying the state advancement instruction included in the tracking information comprises the steps of: Starting from the first tracking information of the tracking sequence, traverse each tracking information and perform the following steps for each tracking information: After merging the same substitute public keys, calculate the product of the substitute public key contained in the current tracking information and the substitute public key of the tracking information that is sorted first, and then multiply it by the public key contained in the initial order information, and record it as the current public key; The state advancement instruction contained in the current tracking information is decrypted using the current public key. If the decryption is successful, it is determined that the state advancement instruction contained in the current tracking information has been verified. If the decryption is unsuccessful, the current tracking information is removed from the tracking sequence.

2. The blockchain-based import and export order tracking method according to claim 1 is characterized in that: The tracking information includes the replacement public key.

3. The blockchain-based import and export order tracking method according to any one of claims 1 to 2, characterized in that: The tracking information includes remarks information signed by the private key of the participant; The method for generating current order tracking information based on the decrypted initial order information and the decrypted complete tracking information comprises the steps of: Get the current order status based on all tracking information; Generate current order tracking information based on current order status, initial order information, and all note information.

4. The blockchain-based import and export order tracking system is characterized by: include: An order initiation module is used to receive order initiation information submitted by an initiator, wherein the order initiation information includes order ID, order information, and participant information, wherein the participant information includes the participant and the order status sequence of the participant; An order generation module is used to generate a corresponding number of public-private key pairs based on the number of participants, distribute the private keys to the corresponding participants, and generate initial order information based on the order ID, order information and public key, and encrypt the initial order information and upload it to the blockchain for storage; An order tracking module is used to receive a viewing request submitted by a participant, the viewing request includes an order ID, query the blockchain, obtain the initial order information and all tracking information, the tracking information is generated by the participant and uploaded to the blockchain after encryption, the tracking information includes a status advancement instruction signed by the participant's private key, and generate the current order tracking information based on the decrypted initial order information and the decrypted all tracking information as a response to the viewing request; The order generation module includes: The key generation submodule is used to generate a corresponding number of public and private key pairs, assign a public and private key pair to each participant, and sort the public and private key pairs according to the order status of the participants; The alternative public key submodule is used to calculate the quotient of each public key and the previous public key starting from the second public-private key pair, which is recorded as the alternative public key; The key distribution submodule is used to distribute the first public-private key pair to the first participant in the order status sequence, and send the replacement public key and the corresponding private key to the subsequent corresponding participants; An order information generation submodule, used to include the public key of the first participant in the order status sequence into the initial order information, and generate the initial order information based on the order ID, order information and public key, and encrypt the initial order information and upload it to the blockchain for storage; The method for generating current order tracking information based on the decrypted initial order information and the decrypted complete tracking information comprises the steps of: Sort the decrypted initial order information and all decrypted tracking information in the order of uploading the blockchain, and record it as the tracking sequence; Verifying the state advancement instructions of the tracking information contained in the tracking sequence in sequence, and recording the tracking information that passes the verification as valid tracking information; Generate current order tracking information based on the decrypted initial order information and all decrypted valid tracking information; The method for verifying the state advancement instruction included in the tracking information comprises the steps of: Starting from the first tracking information of the tracking sequence, traverse each tracking information and perform the following steps for each tracking information: After merging the same substitute public keys, calculate the product of the substitute public key contained in the current tracking information and the substitute public key of the tracking information that is sorted first, and then multiply it by the public key contained in the initial order information, and record it as the current public key; The state advancement instruction contained in the current tracking information is decrypted using the current public key. If the decryption is successful, it is determined that the state advancement instruction contained in the current tracking information has been verified. If the decryption is unsuccessful, the current tracking information is removed from the tracking sequence.

5. Electronic equipment, including processor and memory; The processor is connected to the memory; The memory is used to store executable program code; The processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the method according to any one of claims 1 to 3.

6. A computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the method according to any one of claims 1 to 3.

Citation Information

Patent Citations

  • Logistics tracking method based on block chain

    CN106022681A

  • Workflow engine system and implementation method of workflow engine system

    CN111831988A