A Method and System for Generating Order Numbers to Prevent Information Leakage in Cross-border E-commerce

Generating cross-border e-commerce order numbers through distributed nodes and blockchain technology solves the problems of information leakage and length redundancy, and achieves high concurrency, low latency and security requirements. Dynamic encryption and encoding technology are used to generate irreversible intermediate identifiers, which shortens the length of the order number.

CN120198204BActive Publication Date: 2025-08-01FUZHOU HONGHUI INFORMATION TECHNOLOGY CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510671627.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-05-23
Publication Date
2025-08-01
Estimated Expiration
2045-05-23

AI Technical Summary

Technical Problem

The cross-border e-commerce order number generation solution has the risk of information leakage and length redundancy, which is difficult to meet the needs of high concurrency processing capabilities, security and data security.

Method used

The consensus calculation of dynamic encryption fragments and basic identifiers is used to generate distributed nodes, and the blockchain-on-chain machine code generation is generated, combined with dual hash calculation and improved Byzantine fault tolerance algorithm, irreversible intermediate identifiers are generated and Base91 encoding is used to shorten the order number length.

Benefits of technology

It realizes the high concurrency and low latency demand for order numbers in cross-border e-commerce scenarios, improves information security, shortens the length of order numbers, resists Byzantine attacks at million-level nodes, and ensures data security.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120198204B_ABST
    Figure CN120198204B_ABST
Patent Text Reader

Abstract

The present invention relates to a method and system for generating a cross-border e-commerce order number with anti-information leakage, and belongs to the technical field of cross-border e-commerce business data processing. The method comprises the following steps: using a cross-border e-commerce order issuing server as a distributed node; when any distributed node receives an order number generation request, the corresponding distributed node obtains the corresponding original order information and performs obfuscation processing to generate a basic identifier; at the same time, each distributed node generates a dynamic encryption fragment according to the node information and the real-time network status, and calculates an intermediate identifier through each dynamic encryption fragment and the basic identifier; calling a smart contract to link the intermediate identifier to the blockchain, and obtaining the chain-up certificate returned by the smart contract, encoding the combination of the chain-up certificate and the intermediate identifier to generate a machine code; obtaining a business identifier through a business system that initiates an order number generation request to the corresponding distributed node, combining the machine code and the business identifier into a final order number and returning it to the requester.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a method and system for generating a cross-border e-commerce information leakage-proof order number, and belongs to the technical field of cross-border e-commerce data processing. Background Art

[0002] In cross-border e-commerce, the order number, as the core transaction identifier, must meet high concurrent processing capabilities, scalability, and security. Traditional order number generation solutions have the following drawbacks:

[0003] 1. Information leakage risk: Order numbers contain continuous timestamps or increasing sequences, which can easily be used by outsiders to deduce sensitive information such as daily transaction volume and sales volume.

[0004] 2. Length redundancy: Using a fixed-digit pure timestamp or random number combination results in an excessively long order number (usually exceeding 20 digits), increasing the system storage and transmission burden. Existing technologies, such as those based on UUID or snowflake algorithms, although they improve uniqueness, are still relatively long (usually 28-36 digits) and lack anti-information leakage design, making it difficult to meet the data security and short number segment requirements of cross-border e-commerce. Summary of the Invention

[0005] In order to solve the problems existing in the above-mentioned prior art, the present invention proposes a method and system for generating order numbers for cross-border e-commerce to prevent information leakage.

[0006] The technical solutions of the present invention are as follows:

[0007] In one aspect, the present invention provides a method for generating a cross-border e-commerce order number to prevent information leakage, comprising the following steps:

[0008] Use the cross-border e-commerce order issuing server as a distributed node;

[0009] When any distributed node receives an order number generation request, the corresponding distributed node obtains the corresponding original order information and performs obfuscation processing to generate a basic identifier;

[0010] At the same time, each distributed node generates a dynamic encryption segment based on the node information and real-time network status, and calculates the intermediate identifier through each dynamic encryption segment and the basic identifier;

[0011] Call the smart contract to upload the intermediate identifier to the blockchain, obtain the on-chain proof returned by the smart contract, encode the combination of the on-chain proof and the intermediate identifier, and generate machine code;

[0012] The business system obtains the business identifier by initiating an order number generation request to the corresponding distributed node, and combines the machine code and business identifier into the final order number and returns it to the requester.

[0013] As a preferred embodiment, the step of the corresponding distributed node obtaining the corresponding original order information and performing obfuscation processing to generate a basic identifier is specifically as follows:

[0014] Obtain multiple metadata in the original order information and divide the multiple metadata into two groups;

[0015] Perform a first encryption operation on one group of metadata and a random number to obtain a first hash;

[0016] Perform a second encryption operation on the other group of metadata to obtain a second hash;

[0017] Wherein, the number of output characters of the first encryption operation and the second encryption operation is the same;

[0018] Perform a bitwise exclusive OR operation on the first hash and the second hash to obtain a basic identifier.

[0019] As a preferred embodiment, the step of each distributed node generating a dynamic encryption segment according to the node information and the real-time network status includes:

[0020] For any distributed node, measure the average round-trip time with randomly selected m other distributed nodes in the same region as the first network feature; query the clock deviation between the distributed node and the NTP server as the second network feature; at the same time, generate a true random number based on the trusted execution component of the distributed node;

[0021] Generate a dynamic encryption factor through the first network feature, the second network feature, and the true random number;

[0022] Generate a dynamic encryption segment through the dynamic encryption factor and the node identifier of the corresponding distributed node.

[0023] As a preferred embodiment, after the step of generating the dynamic encryption segment, it further includes:

[0024] Perform consensus verification on the dynamic encryption segment through the Byzantine fault tolerance algorithm.

[0025] As a preferred embodiment, the method of calculating the intermediate identifier through each dynamic encryption segment and the basic identifier is specifically as follows:

[0026] Use the basic identifier as the first character segment;

[0027] Calculate the bitwise exclusive OR accumulation result of each dynamic encryption segment as the second character segment;

[0028] Perform an encryption hash algorithm calculation on the data obtained by splicing the first character segment and the second character segment to generate an intermediate identifier.

[0029] As a preferred embodiment, the step of invoking the smart contract to upload the intermediate identifier to the blockchain and obtaining the upload proof returned by the smart contract includes:

[0030] The corresponding distributed node initiates an upload request, taking multiple metadata in the intermediate identifier, node information, and original order information as the upload information;

[0031] Use the private key of the corresponding distributed node to sign the upload information to obtain a digital signature; broadcast the upload information and the digital signature to the blockchain, and the blockchain performs a hash operation on the upload information and the digital signature to generate an upload hash;

[0032] Return the upload hash as the upload proof.

[0033] As a preferred embodiment, the step of encoding the combination of the upload proof and the intermediate identifier to generate machine code includes:

[0034] Intercept partial characters from the upload proof and the intermediate identifier respectively;

[0035] Encode the intercepted partial characters using the Base91 encoding scheme to obtain a first code segment;

[0036] Perform CRC redundancy check processing on the intercepted partial characters to generate a check code as the second code segment;

[0037] Combine the preset version identification code segment, the first code segment, and the second code segment into machine code.

[0038] On the other hand, the present invention also proposes a cross-border e-commerce order number generation system for preventing information leakage, including:

[0039] A node authentication module for authenticating the order-issuing servers of multiple cross-border e-commerce as distributed nodes;

[0040] An information desensitization module for, when any distributed node receives an order number generation request, the corresponding distributed node obtains the corresponding original order information and performs a confusion process to generate a basic identifier;

[0041] At the same time, each distributed node generates a dynamic encryption segment according to the node information and the real-time network status, and calculates an intermediate identifier through each dynamic encryption segment and the basic identifier;

[0042] A machine code generation module for invoking the smart contract to upload the intermediate identifier to the blockchain, obtaining the upload proof returned by the smart contract, and encoding the combination of the upload proof and the intermediate identifier to generate machine code;

[0043] The order number generation module is used to obtain the business identifier by initiating an order number generation request to the corresponding distributed node, and combine the machine code and the business identifier into the final order number and return it to the requester.

[0044] On the other hand, the present invention also proposes an electronic device, including a memory, a processor, and a computer program stored in the memory and runnable on the processor. When the processor executes the program, it implements the cross-border e-commerce anti-information leakage order number generation method as described in any embodiment of the present invention.

[0045] On the other hand, the present invention also proposes a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the cross-border e-commerce anti-information leakage order number generation method as described in any embodiment of the present invention.

[0046] The effective effects of the present invention include:

[0047] 1. The present invention uses the order issuing server as a distributed node, generates a consensus calculation between the dynamic encryption fragment and the irreversible basic identifier generated according to the order information through the distributed node, generates an intermediate identifier with irregular patterns and difficult to reverse engineer, and then generates the machine code through the blockchain. Under the premise of ensuring that the generated order number is irreversible, it realizes the high concurrency and low latency requirements of the order number in the cross-border e-commerce scenario.

[0048] 2. The present invention uses double hash calculation to generate two hashes with the same number of character bits, and then performs bitwise XOR on the two hashes to generate a basic identifier. A third party needs to crack both encryption operations at the same time to obtain the original information. At the same time, random numbers are introduced during the encryption operation, which further increases the difficulty of cracking by the third party and greatly improves the security of the original information.

[0049] 3. The present invention generates dynamic encryption fragments through network status, which greatly improves the randomness of the dynamic encryption fragments. At the same time, it performs consensus verification of the dynamic encryption fragments through an improved Byzantine fault-tolerant algorithm, which can resist Byzantine attacks from millions of nodes and further reduce the risk of order number information leakage.

[0050] 4. The present invention generates the core code segment of the final machine code by intercepting some characters in the chain proof and the intermediate identifier, and adopts the Base91 encoding scheme to improve the encoding efficiency and shorten the output character length. Compared with the existing UUID and snowflake algorithms, it takes into account the anti-collision strength of the order number while shortening the order number length, achieving a balance between security and efficiency in the high-concurrency scenario of cross-border e-commerce.

[0051] Additional aspects and advantages of the present invention will be set forth in the following description, and in part will be obvious from the description, or may be learned by practice of the present invention. Additionally, various aspects and advantages of the present invention may be realized and obtained by the methods steps and combinations particularly pointed out in the appended claims. Description of the Drawings

[0052] Figure 1 It is a flowchart of the method according to the first embodiment of the present invention. Detailed Embodiments

[0053] The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all of the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without making creative efforts belong to the scope of protection of the present invention.

[0054] It should be understood that the step numbers used herein are only for convenience of description and do not limit the order of execution of the steps.

[0055] It should be understood that the terms used in the specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. As used in the specification of the present invention and the appended claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to include the plural forms.

[0056] The terms "comprising" and "including" indicate the presence of the described features, wholes, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or their combinations.

[0057] The term "and / or" refers to any combination and all possible combinations of one or more of the associated listed items, and includes these combinations.

[0058] Embodiment 1:

[0059] Refer to Figure 1 , this embodiment proposes a method for generating order numbers to prevent information leakage in cross-border e-commerce, including the following steps:

[0060] S100. Take the order-issuing server of the cross-border e-commerce as a distributed node; each distributed node needs to perform admission authentication to the server, generate a hardware-level identity certificate through the trusted execution component of each node, and each distributed node has a globally unique node identifier.

[0061] S200. When any distributed node receives an order number generation request, the corresponding distributed node obtains the corresponding original order information (including user ID, product SKU, order address, order amount, etc.) and performs obfuscation processing through an encrypted hash function to generate an irreversible basic identifier.

[0062] S300. At the same time, each distributed node generates a dynamic encryption fragment based on the node information and real-time network status, and calculates the intermediate identifier through each dynamic encryption fragment and the basic identifier; this step generates the intermediate identifier through the consensus calculation of multiple nodes to prevent the overall information security from being affected when any node is compromised. At the same time, the real-time network status is used to generate the dynamic encryption fragment, which can destroy the regularity of the intermediate identifier and prevent a third party from obtaining the original data through reverse engineering or statistical analysis.

[0063] S400: Call the smart contract to upload the intermediate identifier to the blockchain, obtain the on-chain proof (on-chain hash) returned by the smart contract, encode the combination of the on-chain proof and the intermediate identifier to generate machine code; at the same time, write the machine code generation path and verification parameters (including the on-chain proof, the intermediate identifier, the final generated machine code, the on-chain timestamp, the node identifier of the distributed node, the original order information, etc.) into the smart contract.

[0064] S500. The business system that initiates an order number generation request to the corresponding distributed node obtains a business identifier (used to distinguish order types, such as PO for purchase orders and SO for sales orders). The system then combines the machine code and business identifier to create the final order number and returns it to the requester (the distributed node that initiated the order number generation request). For example, if the generated machine code is "6084537002" in decimal and the business identifier is "SO," the resulting order number is "SO6084537002."

[0065] This implementation achieves the high concurrency and low latency requirements for order numbers in cross-border e-commerce scenarios, while ensuring that generated order numbers are irreversible. In actual deployment, the underlying blockchain should be selected based on the scale of the business (small and medium-sized platforms can use Hyperledger Fabric, while large platforms can use their own proprietary consortium blockchain).

[0066] In one implementation of this embodiment, in order to perform information desensitization and anti-reverse engineering, in step S300, the corresponding distributed node obtains the corresponding original order information and performs obfuscation processing. The steps of generating a basic identifier are specifically as follows:

[0067] S311, obtain multiple metadata in the original order information. In this embodiment, the metadata obtained is ,in: For user ID, SKU code for the product, is the order address, is the order generation timestamp; the multiple metadata are divided into two groups. In this embodiment, is taken as a single group, and the other three metadata are taken as the second group.

[0068] S312. Perform a first encryption operation on and the random number generated by the trusted execution component of the corresponding distributed node to obtain the first hash , specifically:

[0069] ;

[0070] Among them, () represents the SHA3-256 encryption operation, is the random number generated by the trusted execution component, represents the concatenation operation.

[0071] S312. Perform a second encryption operation on the other group of metadata to obtain the second hash , specifically:

[0072] ;

[0073] Among them, () represents the SM3 encryption operation.

[0074] Among them, the number of characters output by the first encryption operation and the second encryption operation is the same;

[0075] S303. Perform a bitwise exclusive OR operation on the first hash and the second hash to obtain the basic identifier :

[0076] ;

[0077] Among them, represents the bitwise exclusive OR operation.

[0078] Based on the technical solution of the above embodiment, this embodiment generates two hashes with the same number of characters by using the double hash calculation method, and then performs a bitwise exclusive OR on the two hashes to generate the basic identifier. A third party needs to crack both the SHA3-256 and SM3 encryption operations at the same time to obtain the original information. At the same time, a random number is introduced in the first encryption operation, which further improves the cracking difficulty of the third party and greatly improves the security of the original information.

[0079] In an implementation manner of this embodiment, in step S300, the step of each distributed node generating a dynamic encryption segment according to the node information and the real-time network state includes:

[0080] S321. For any distributed node, measure the average round-trip time (RTT) between it and randomly selected m other distributed nodes in the same region as the first network feature. :

[0081] ;

[0082] Wherein, is the total number of other distributed nodes, represents the average round-trip time between the selected distributed node and the i-th other distributed node measured at time t.

[0083] Query the clock deviation between the distributed node and the NTP server as the second network feature :

[0084] ;

[0085] Wherein, represents the local clock query value of the selected distributed node at time t, represents the clock query value of the NTP server at time t.

[0086] Meanwhile, generate a true random number based on the trusted execution component of the distributed node .

[0087] S322. Generate a dynamic encryption factor through the first network feature , the second network feature and the true random number , specifically including:

[0088] Normalize the first network feature, the second network feature and the true random number, and map the three parameters to a unified numerical interval (such as the 0~1 interval):

[0089] Perform chaotic calculation on the three normalized parameters:

[0090] ;

[0091] Wherein, represents the chaotic input at the current moment (initial value = ), represents the chaotic input at the next moment, represents the chaotic output at the current moment; is the chaotic parameter, , the chaotic parameter is replaced every hour; is the noise injection coefficient, in this embodiment is set to 0.1; , , They are the first network feature, the second network feature, and the true random number after normalization, respectively; It represents the modulo operation.

[0092] The chaotic output is converted into a dynamic encryption factor through the following formula:

[0093] ;

[0094] Where, is the dynamic encryption factor at time t, represents the CPU load rate of the selected distributed node; in the above formula, when the CPU load rate is greater than or equal to 50%, the high 16 bits of the chaotic output are taken (the integer is taken after shifting 16 bits to the right), sacrificing some randomness to reduce the calculation overhead, which is applicable to high-load scenarios sensitive to performance. At the same time, through the modulo operation of ensures that the output range is fixed. When the CPU load rate is less than 50%, the chaotic output is XORed with itself after circularly shifting 8 bits to the left, and then 24 bits are taken to enhance the confusion intensity.

[0095] S323. A dynamic encryption segment is generated through the dynamic encryption factor and the node identifier of the corresponding distributed node:

[0096] ;

[0097] Where, represents the dynamic encryption segment generated by the i-th distributed node, · is a linear congruential generator, is a preset quantum-secure seed, is the node identifier of the i-th distributed node, is a preset large prime number. In this embodiment, is set to .

[0098] As a preferred implementation manner of this embodiment, after the step of generating the dynamic encryption segment, it further includes:

[0099] The consensus verification of the dynamic encryption segment is performed through the Byzantine fault tolerance algorithm. The specific verification formula is as follows:

[0100] ;

[0101] Where, represents the set of dynamic encryption segments, represents the reputation weight of the i-th distributed node, represents the total number of nodes participating in the verification ( ≥ 3f + 1, f is the set number of fault-tolerant nodes), Indicates a congruence relation, is a prime number for pre-trial;

[0102] The above formula indicates that only when the weighted sum of the dynamically encrypted fragments generated by all participating distributed nodes for verification is an integer multiple of modulo will the set of dynamically encrypted fragments be regarded as valid.

[0103] Among them, the reputation weight of the i-th distributed node is dynamically updated. According to the historical verification situation, if the success rate ratio of this distributed node in recent verifications is high, the reputation weight is higher. The specific formula can be set as:

[0104] ;

[0105] Among them, is the reputation weight of the i-th distributed node at the current moment, is the reputation weight of the i-th distributed node at the historical moment; is a preset historical weight decay factor, which is set to 0.8 in this embodiment; represents the number of times the i-th distributed node has successfully participated in verification recently, represents the total number of times the i-th distributed node has been requested for verification recently.

[0106] Based on the above implementation, this embodiment can resist Byzantine attacks of millions of nodes and further reduce the risk of order number information leakage through the methods of distributed sharding verification and dynamic allocation of node reputation weights.

[0107] As a preferred implementation of this embodiment, in step S300, the method for calculating the intermediate identifier by each dynamically encrypted fragment and the basic identifier is specifically as follows:

[0108] S331. Use the basic identifier as the first character segment;

[0109] S332. Calculate the bitwise exclusive OR accumulation result of each dynamically encrypted fragment as the second character segment;

[0110] S333. For the data obtained by splicing the first character segment and the second character segment, use an encrypted hash algorithm for calculation to generate an intermediate identifier. The specific formula is:

[0111] ;

[0112] Among them, represents the intermediate identifier, represents the Keccak-256 encrypted hash operation, Represents the bitwise exclusive-or accumulation result of each dynamic encryption segment.

[0113] As a preferred implementation manner of this embodiment, in step S400, the step of invoking the smart contract to upload the intermediate identifier to the blockchain and obtaining the upload proof returned by the smart contract includes:

[0114] S411. The corresponding distributed node initiates an upload request, and combines multiple metadata in the intermediate identifier, node information, and original order information into upload information ;

[0115] S412. Sign the upload information using the private key of the corresponding distributed node to obtain a digital signature :

[0116] ;

[0117] Wherein, is the elliptic curve digital signature algorithm, is the private key of the corresponding distributed node.

[0118] S413. Broadcast the upload information and the digital signature to the blockchain network (such as Hyperledger Fabric, Ethereum, etc.), and the blockchain performs a hash operation on the upload information and the digital signature to generate a unique upload hash:

[0119] ;

[0120] S414. Return the upload hash as the upload proof.

[0121] As a preferred implementation manner of this embodiment, in step S400, the step of encoding the combination of the upload proof and the intermediate identifier to generate a machine code includes:

[0122] S421. Intercept partial characters from the upload proof and the intermediate identifier respectively. Specifically, in this embodiment, the first 16 bytes (128 bits) are intercepted from the intermediate identifier , and the first 8 bytes (64 bits) are intercepted from the upload proof ;

[0123] S422. Encode the intercepted partial characters using the Base91 encoding scheme to obtain a first code segment:

[0124] ;

[0125] Wherein, is the first code segment, represents Base91 encoding, Represents the first 36 bytes intercepted from the middle identifier, Represents the first 16 bytes intercepted from the proof of uploading to the chain. After encoding with Base91, the length of the output characters is the input bit number / 13 × 2. In this example, the input bit number is 36 + 16 = 52 bits, and the calculated length of the output characters is 8 bits.

[0126] S423. For the intercepted partial characters, perform CRC redundancy check processing to generate a check code as the second code segment:

[0127] ;

[0128] Among them, is the second code segment, represents the CRC16 redundancy check algorithm, represents the first 2 bytes intercepted from the generated random number. The result of the second code segment is mapped to a 2-digit decimal number.

[0129] S424. Combine the preset version identification code segment, the first code segment, and the second code segment into a machine code, that is, the finally generated machine code is:

[0130] ;

[0131] Among them, is the finally generated machine code, is the preset 2-digit version identification code segment.

[0132] Through the above implementation method, the finally generated machine code in this embodiment is a 12-bit length character of 2 + 8 + 2. Compared with the 36-bit character length order number generated by the existing UUIDv4 algorithm and the 18-bit character length order number generated by the snowflake algorithm, the length of the order number is greatly shortened, and at the same time, the anti-collision strength of the order number is also taken into account. Achieve a balance between security and efficiency in the high-concurrency scenario of cross-border e-commerce.

[0133] At the same time, after successfully writing the generation path and verification parameters of the machine code, record the association between the generated machine code and the proof of uploading to the chain on the blockchain. All uploaded data is stored on the blockchain in a structured form to ensure immutability and public queryability. After uploading to the chain, any participating party can query on the blockchain through the machine code to verify its authenticity and validity.

[0134] Moreover, the validity of the machine code can be verified through zero-knowledge proof on the chain without disclosing specific order information.

[0135] Embodiment 2:

[0136] This embodiment proposes a cross-border e-commerce order number generation system for preventing information leakage, including:

[0137] A node authentication module, used to authenticate multiple cross-border e-commerce order issuing servers as distributed nodes; this module is used to implement the function of step S100 in the first embodiment and will not be described in detail here;

[0138] The information desensitization module is used to obtain the corresponding original order information and perform obfuscation processing to generate a basic identifier when any distributed node receives a request to generate an order number;

[0139] At the same time, each distributed node generates a dynamic encryption segment based on the node information and real-time network status, and calculates an intermediate identifier through each dynamic encryption segment and the basic identifier; this module is used to implement the functions of steps S200 and S300 in the first embodiment, and will not be repeated here;

[0140] A machine code generation module is used to call the smart contract to upload the intermediate identifier to the blockchain, obtain the on-chain proof returned by the smart contract, encode the combination of the on-chain proof and the intermediate identifier, and generate a machine code. This module is used to implement the function of step S400 in Example 1 and will not be repeated here.

[0141] The order number generation module is used to obtain the business identifier by initiating an order number generation request from the business system of the corresponding distributed node, and combine the machine code and the business identifier into a final order number and return it to the requester; this module is used to implement the function of step S500 in Example 1 and will not be repeated here.

[0142] Example 3:

[0143] This embodiment proposes an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the method for generating a cross-border e-commerce order number to prevent information leakage as described in any embodiment of the present invention is implemented.

[0144] Example 4:

[0145] This embodiment provides a computer-readable storage medium having a computer program stored thereon. When the program is executed by a processor, the method for generating a cross-border e-commerce order number with anti-information leakage as described in any embodiment of the present invention is implemented.

[0146] In the embodiments of the present application, "at least one" means one or more, and "a plurality" means two or more. "And / or" describes the relationship between associated objects and indicates that there can be three relationships. For example, A and / or B can represent the cases where A exists alone, A and B exist simultaneously, and B exists alone. Here, A and B can be singular or plural. The character " / " generally represents an "or" relationship between the associated objects before and after. "At least one of the following" and its similar expressions refer to any combination of these items, including any combination of single items or plural items. For example, at least one of a, b, and c can represent: a, b, c, a and b, a and c, b and c, or a and b and c, where a, b, and c can be single or multiple.

[0147] Those of ordinary skill in the art can realize that the units and algorithm steps described in the embodiments disclosed herein can be implemented by a combination of electronic hardware, computer software, and electronic hardware. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Professional technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present application.

[0148] Those skilled in the art can clearly understand that for the convenience and brevity of description, the specific working processes of the systems, devices, and units described above can refer to the corresponding processes in the foregoing method embodiments and will not be elaborated herein.

[0149] In several embodiments provided by the present application, if any function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, in essence, or the part that contributes to the prior art or a part of this technical solution can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present application. The foregoing storage medium includes: various media such as USB flash drives, mobile hard disks, read-only memories (hereinafter referred to as ROM), random access memories (hereinafter referred to as RAM), magnetic disks, or optical discs that can store program codes.

[0150] The above are only the embodiments of the present invention and do not limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the specification and drawings of the present invention, or directly or indirectly applied in other related technical fields, shall be equally included in the patent protection scope of the present invention.

Claims

1. A method for generating order numbers to prevent information leakage in cross-border e-commerce, characterized in that, The following steps are involved: Use the cross-border e-commerce order server as a distributed node; When any distributed node receives an order number generation request, the corresponding distributed node obtains the corresponding original order information and performs obfuscation processing to generate a basic identifier, specifically: Obtain multiple metadata in the original order information and divide the multiple metadata into two groups; Performing a first encryption operation on one of the sets of metadata and the random number to obtain a first hash; performing a second encryption operation on the other set of metadata to obtain a second hash; The first encryption operation and the second encryption operation output the same number of character digits; Perform a bitwise XOR operation on the first hash and the second hash to obtain a base identifier; At the same time, each distributed node generates a dynamic encryption fragment based on the node information and real-time network status, and calculates the intermediate identifier through each dynamic encryption fragment and the basic identifier, specifically: Use the basic identifier as the first character segment; Calculate the bitwise exclusive OR accumulation result of each dynamic encryption segment as the second character segment; The data obtained by concatenating the first character segment and the second character segment is calculated using a cryptographic hash algorithm to generate an intermediate identifier; Call the smart contract to upload the intermediate identifier to the blockchain, obtain the on-chain proof returned by the smart contract, encode the combination of the on-chain proof and the intermediate identifier, and generate machine code, including: Extract some characters from the on-chain proof and the intermediate identifier respectively; The intercepted characters are encoded using the Base91 encoding scheme to obtain the first code segment; For the intercepted part of the characters, CRC redundancy check is used to generate a check code as the second code segment; Combining the preset version identification code segment, the first code segment, and the second code segment into a machine code; The business system obtains the business identifier by initiating an order number generation request to the corresponding distributed node, and combines the machine code and business identifier into the final order number and returns it to the requester.

2. The method for generating an order number for preventing information leakage in cross-border e-commerce according to claim 1, wherein, The step of each distributed node generating a dynamic encryption segment according to the node information and the real-time network status includes: For any distributed node, measure the average round-trip time between it and m random other distributed nodes in the same area as the first network feature; query the clock deviation between the distributed node and the NTP server as the second network feature; and generate a true random number based on the trusted execution component of the distributed node; Generate a dynamic encryption factor using the first network feature, the second network feature, and a true random number; A dynamic encryption fragment is generated by using a dynamic encryption factor and a node identifier of a corresponding distributed node.

3. A method for generating an order number for preventing information leakage in cross-border e-commerce according to claim 1, characterized in that, After the step of generating the dynamic encryption fragment, it also includes: Consensus verification of dynamic encrypted fragments is performed through the Byzantine fault tolerance algorithm.

4. A method for generating an order number for preventing information leakage in cross-border e-commerce according to claim 1, characterized in that, The steps of calling the smart contract to upload the intermediate identifier to the blockchain and obtaining the on-chain proof returned by the smart contract include: The corresponding distributed node initiates an on-chain request, using the intermediate identifier, node information, and multiple metadata in the original order information as on-chain information; Use the private key of the corresponding distributed node to sign the chain information to obtain a digital signature; broadcast the chain information and digital signature to the blockchain, and the blockchain performs a hash operation on the chain information and digital signature to generate a chain hash; Return the on-chain hash as proof of on-chain.

5. A cross-border e-commerce order number generation system for preventing information leakage, characterized in that, include: Node authentication module, used to authenticate multiple cross-border e-commerce order-issuing servers as distributed nodes; The information desensitization module is used to obtain the corresponding original order information and perform obfuscation processing when any distributed node receives an order number generation request, and generate a basic identifier, specifically: Obtain multiple metadata in the original order information and divide the multiple metadata into two groups; Performing a first encryption operation on one of the sets of metadata and the random number to obtain a first hash; performing a second encryption operation on the other set of metadata to obtain a second hash; The first encryption operation and the second encryption operation output the same number of character digits; Perform a bitwise XOR operation on the first hash and the second hash to obtain a base identifier; At the same time, each distributed node generates a dynamic encryption fragment based on the node information and real-time network status, and calculates the intermediate identifier through each dynamic encryption fragment and the basic identifier, specifically: Use the basic identifier as the first character segment; Calculate the bitwise exclusive OR accumulation result of each dynamic encryption segment as the second character segment; The data obtained by concatenating the first character segment and the second character segment is calculated using a cryptographic hash algorithm to generate an intermediate identifier; The machine code generation module is used to call the smart contract to upload the intermediate identifier to the blockchain, obtain the chain-up certificate returned by the smart contract, encode the combination of the chain-up certificate and the intermediate identifier, and generate machine code, including: Extract some characters from the on-chain proof and the intermediate identifier respectively; The intercepted characters are encoded using the Base91 encoding scheme to obtain the first code segment; For the intercepted part of the characters, CRC redundancy check is used to generate a check code as the second code segment; Combining the preset version identification code segment, the first code segment, and the second code segment into a machine code; The order number generation module is used to obtain the business identifier by initiating an order number generation request to the corresponding distributed node, and combine the machine code and the business identifier into the final order number and return it to the requester.

6. An electronic device, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the program, the cross-border e-commerce anti-information leakage order number generation method as described in any one of claims 1 to 4 is implemented.

7. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by a processor, the cross-border e-commerce information leakage prevention order number generation method as described in any one of claims 1 to 4 is implemented.

Citation Information

Patent Citations

  • Online shopping privacy protection method based on distributed digital identity

    CN113901504A

  • Method for high-performance distributed storage of block data and timestamp, cross-chain communication and data collaboration

    WO2023050555A1