A method and system for tracing port cargo based on big data

By using big data encryption and blockchain storage technologies, the problem of easily modified port cargo information has been solved, enabling efficient and secure port cargo traceability and improving port operational efficiency and cargo security.

CN118941308BActive Publication Date: 2026-01-30RIZHAO PORT GRP CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411420087.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-12
Publication Date
2026-01-30
Estimated Expiration
2044-10-12

AI Technical Summary

Technical Problem

Port cargo-related data is easily modified, resulting in poor reliability of traceability information and affecting port operational efficiency and cargo safety.

Method used

Big data technology is used to encrypt port cargo information, which is stored using blockchain. Multiple encryption algorithms are used to ensure data security, including hash functions, symmetric encryption algorithms, asymmetric encryption algorithms, and chaotic mapping models. Public and private keys are generated for data encryption and decryption.

Benefits of technology

It improves the credibility and security of port cargo traceability information, enhances the reliability of data storage and traceability efficiency, and ensures the accuracy and security of cargo management.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118941308B_ABST
    Figure CN118941308B_ABST
Patent Text Reader

Abstract

This invention relates to the field of cargo information traceability technology, specifically to a port cargo traceability method and system based on big data. The method includes the following steps: obtaining traceable information of port cargo based on big data technology; encrypting the traceable information to obtain ciphertext and a key; uploading the ciphertext to a blockchain network to obtain a unique blockchain address; generating a public key and a private key; using the public key to encrypt the unique blockchain address and the key to obtain ciphertext for port cargo traceability; and decrypting the ciphertext using the private key to obtain plaintext for port cargo traceability, thereby obtaining the traceability information of the port cargo. This invention, by obtaining relevant cargo information through big data technology and then encrypting and storing it in the blockchain, solves the problem of poor reliability of traceability information due to the ease with which relevant port cargo information can be modified using multiple encryption methods.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of cargo information traceability technology, specifically to a port cargo traceability method and system based on big data. Background Technology

[0002] Ports, as the link between sea and land, are key infrastructure for global trade and economic development, playing an irreplaceable role in promoting international trade, ensuring supply chain stability, enhancing regional competitiveness, and achieving sustainable development. With the increasing volume of business at my country's ports, the throughput of cargo is also growing, leading to greater pressure on cargo management. Cargo traceability is an important technical means for port cargo management. It enables real-time monitoring of cargo location and status, helping port operators better plan loading and unloading activities, reducing the possibility of cargo delays or loss, and thus improving port operational efficiency. It also allows for the timely detection and handling of potential safety hazards, ensuring the safety and legality of cargo, which is particularly important for the transportation of high-risk goods such as dangerous goods. Furthermore, it allows for tracing the origin and authenticity of cargo, preventing counterfeit and substandard products from entering the market, thereby safeguarding trade security and protecting consumer rights.

[0003] However, port cargo data is also sensitive to privacy, and data breaches could cause significant losses. Furthermore, malicious actors could modify the data, compromising its authenticity. Therefore, the ease with which port cargo information can be altered, leading to poor reliability of traceability information, is a pressing issue that needs to be addressed. Summary of the Invention

[0004] To address the shortcomings of existing methods and the needs of practical applications, and in order to improve port operational efficiency, ensure the safety and authenticity of port cargo, provide reliable guarantees for both trading parties, and solve the problem of poor reliability of traceability information due to the ease with which port cargo-related information can be modified, this invention provides a port cargo traceability method based on big data, comprising the following steps:

[0005] Based on big data technology, this invention obtains traceability information of port goods, encrypts the traceability information to obtain ciphertext and a key, uploads the ciphertext to a blockchain network to obtain a unique blockchain address, generates a public key and a private key, uses the public key to encrypt the unique blockchain address and the key, obtains ciphertext for port goods traceability, and decrypts the ciphertext using the private key to obtain plaintext for port goods traceability, thus obtaining the traceability information of the port goods. This invention uses big data technology to obtain relevant information about port goods, encrypts it, and then stores it in the blockchain. This multi-layered encryption solves the problem of easily modified information leading to poor reliability of traceability information, and also uses the blockchain as a data storage location to improve data traceability efficiency.

[0006] Optionally, encrypting the traceable information to obtain traceable information ciphertext and traceable information key includes the following steps:

[0007] The traceable information is processed using a hash function to obtain a message digest; this message digest is then used as the key for a symmetric encryption algorithm to encrypt the traceable information, obtaining the ciphertext of the traceable information; finally, an asymmetric encryption algorithm is used to encrypt the message digest, obtaining the key for the traceable information. This invention encrypts large amounts of data using symmetric encryption algorithms and important data using asymmetric encryption algorithms, thus accelerating the data encryption process and further improving the traceability efficiency and accuracy of the invention.

[0008] Optionally, generating the public and private keys includes the following steps:

[0009] Multiple prime numbers are randomly selected to obtain a first modulus; the prime numbers are then sorted and adjusted according to their magnitude; a second modulus and Euler's totient function are obtained based on the adjusted prime numbers; a positive integer is randomly selected by combining the second modulus and Euler's totient function; a third modulus is obtained by combining the positive integer and Euler's totient function; a private key is generated by combining the positive integer and the second modulus; and a public key is generated by combining the third modulus and the second modulus. This invention, by adaptively adjusting the number of prime numbers, generates a key pair adapted to the data to be encrypted, further improving data encryption efficiency.

[0010] Optionally, the first modulus obtained through the prime number satisfies the following formula:

[0011] ,in, Represents the first modulus. Indicates the first A prime number, Indicates the number of prime numbers. This represents an integer function;

[0012] The prime numbers are sorted and adjusted according to the first modulus and the size of the prime numbers to satisfy:

[0013] ,in, This indicates the length of the first modulus. This invention automatically adjusts the number of prime numbers based on the length of the first modulus, which helps balance encryption and decryption speeds.

[0014] Optionally, the second modulus and Euler's totient function are obtained based on the adjusted prime numbers, satisfying the following formula:

[0015] ,in, Represents the second modulus. Indicates the first A number of adjusted prime numbers. This indicates the number of prime numbers after adjustment. This represents an integer function;

[0016] ,in, This represents the Euler's totient function. The modulus and Euler's totient function obtained after determining the prime number in this invention are more suitable for current data encryption requirements.

[0017] Optionally, by combining the second modulus and the Euler's totient function, a positive integer is randomly selected that satisfies the following formula:

[0018] ,in, Represents the second modulus. Represents positive integers. Represents Euler's totient function. This represents the greatest common divisor function.

[0019] Optionally, the third modulus is obtained by combining the positive integer and the Euler's totient function, satisfying the following formula:

[0020] ,in, Represents the third modulus. Represents positive integers. Represents Euler's totient function. Let the new modulus be a given, and satisfy the following: , , Represents the second modulus. Indicates the first An adjusted prime number. This invention, by adjusting the constraints of the new modulus, further improves the reliability of port cargo traceability results.

[0021] Optionally, the step of encrypting the blockchain unique address and the traceability information key using the public key to obtain the port cargo traceability ciphertext includes the following steps:

[0022] The invention integrates the unique blockchain address and the traceability information key; maps the integration result using a chaotic mapping model to obtain a mapping result; and encrypts the mapping result and the parameters of the chaotic mapping model using the public key to obtain the port cargo traceability ciphertext. This invention further ensures the security of port cargo-related data through multiple encryption methods.

[0023] Optionally, the chaotic mapping model satisfies the following formula:

[0024] ,in, The parameters represent the first chaotic mapping. The parameters represent the second chaotic mapping. Indicated by The value is the result of iterating through the second chaotic mapping from the initial value. This indicates the initial value after the first chaotic mapping. One value, and This represents the parameter value that satisfies the chaotic mapping. This invention further diffuses the unique blockchain address and traceable information key through chaotic mapping, thus ensuring the security of the traceability data once again.

[0025] Secondly, to efficiently execute the port cargo traceability method based on big data provided by this invention, this invention also provides a port cargo traceability system based on big data, including a processor, an input device, an output device, and a memory. The processor, input device, output device, and memory are interconnected. The memory stores a computer program containing program instructions. The processor is configured to invoke the program instructions to execute the port cargo traceability method based on big data as described in the first aspect of this invention. This port cargo traceability system based on big data is compact, stable in performance, and can stably execute the port cargo traceability method based on big data provided by this invention, further enhancing the overall applicability and practical application capability of this invention. Attached Figure Description

[0026] Figure 1 A flowchart of a port cargo traceability method based on big data is provided for an embodiment of the present invention;

[0027] Figure 2 A framework diagram of a port cargo traceability system based on big data is provided for an embodiment of the present invention;

[0028] Figure 3 This is a schematic diagram of a port cargo traceability device based on big data, provided as an embodiment of the present invention. Detailed Implementation

[0029] Specific embodiments of the present invention will now be described in detail. It should be noted that the embodiments described herein are for illustrative purposes only and are not intended to limit the invention. In the following description, numerous specific details are set forth in order to provide a thorough understanding of the invention. However, it will be apparent to those skilled in the art that these specific details are not necessary to practice the invention. In other instances, well-known circuits, software, or methods have not been specifically described to avoid obscuring the invention.

[0030] Throughout this specification, references to "an embodiment," "an embodiment," "an example," or "an example" mean that a particular feature, structure, or characteristic described in connection with that embodiment or example is included in at least one embodiment of the invention. Therefore, the phrases "in an embodiment," "in an embodiment," "an example," or "an example" appearing in various places throughout the specification do not necessarily refer to the same embodiment or example. Furthermore, specific features, structures, or characteristics can be combined in one or more embodiments or examples in any suitable combination and / or sub-combination. Moreover, those skilled in the art will understand that the illustrations provided herein are for illustrative purposes and are not necessarily drawn to scale.

[0031] Please see Figure 1 To improve port operational efficiency, ensure the safety and authenticity of port cargo, provide reliable protection for both trading parties, and address the problem of poor reliability of traceability information due to the ease with which port cargo information can be modified, this invention provides a port cargo traceability method based on big data. Figure 1 As shown, the method includes the following steps:

[0032] S1. Based on big data technology, obtain traceability information of port cargo, encrypt the traceability information, and obtain traceability information ciphertext and traceability information key.

[0033] In this embodiment, based on big data technology, multifaceted traceability information about port cargo can be obtained. This information is crucial for port operation management, cargo tracking, security, and efficiency improvement, and is of great significance for enhancing port operational efficiency, ensuring cargo safety, optimizing logistics and transportation, and promoting port trade development. Specifically, big data technology can provide the following traceability information about port cargo:

[0034] Basic cargo information, including cargo type and quantity, is used to understand the type, quantity, and distribution of cargo over different time periods; cargo origin and destination are used to trace the origin, transportation route, and final destination of cargo, which helps to optimize route planning.

[0035] Cargo dynamic information, including cargo loading and unloading status, real-time monitoring of cargo loading and unloading progress, ensuring timely and efficient completion of loading and unloading operations; cargo location tracking, using Internet of Things technology (such as RFID, GPS, etc.) to track the real-time location of cargo, understanding the specific location of cargo within the port and its movement trajectory during transportation.

[0036] Cargo safety and risk information includes cargo safety monitoring, which utilizes big data analytics to monitor the safety status of cargo during transportation, such as changes in environmental parameters like temperature, humidity, and vibration, and to promptly identify and warn of potential safety hazards; and cargo risk assessment, which combines historical and real-time data to assess the transportation risks of cargo, including risks such as damage, loss, and delays, providing decision support for cargo owners and port managers.

[0037] Goods warehousing and inventory information, including warehouse utilization, analysis of warehouse capacity, utilization rate and storage requirements of different goods, and optimization of warehouse layout and goods storage strategies; inventory management, real-time monitoring of inventory status, including information such as goods entering and leaving the warehouse, and inventory quantity, to ensure the accuracy and timeliness of inventory data.

[0038] Cargo logistics and transportation information, including logistics transportation routes, analyzes cargo transportation routes and modes of transportation, optimizes transportation paths and transportation costs; transportation time prediction, uses big data analysis to predict cargo transportation time, and provides cargo owners and port managers with reliable transportation time estimates.

[0039] Goods trade and market information, including goods trade data, collects and analyzes goods trade data, including trade volume, trade value, trading partners, etc., to provide trade statistics and analysis services for port managers and government departments; market demand forecasting, combines market trends and historical data to predict market demand for different goods, providing market reference information for port managers and cargo owners.

[0040] Further, the traceable information is encrypted to obtain traceable information ciphertext and traceable information key, including the following steps:

[0041] S11. The traceable information is processed using a hash function to obtain an information digest.

[0042] Hash functions can map traceable information from input data of any length to a fixed-length output, i.e., a message digest, and have the following key characteristics:

[0043] Determinism: The same input data always produces the same output summary;

[0044] One-wayness: It is almost impossible to deduce the original input data from the output summary (i.e., irreversibility).

[0045] Fast computation: For input data of any length, the hash function can quickly compute its digest;

[0046] Weak collision resistance: It is computationally difficult, but not impossible, to find two different input data that produce the same digest, depending on the specific hash function;

[0047] Strong collision resistance: For any given digest, finding the input data that can generate the digest is computationally extremely difficult, which is usually the main goal of hash function design.

[0048] In port cargo traceability, traceable information can include the cargo's production date, batch number, manufacturer information, transportation route, inspection report, etc. This information is collected and integrated into one or more data fields, which are then used as input to a hash function.

[0049] S12. Use the message digest as the key of the symmetric encryption algorithm to encrypt the traceable information to obtain the ciphertext of the traceable information.

[0050] Symmetric encryption algorithms, also known as symmetric key algorithms or single-key algorithms, offer fast encryption and decryption speeds and are suitable for encrypting large amounts of data. Common symmetric encryption algorithms include DES, 3DES, AES, RC4, RC5, and Blowfish. Among them, AES (Advanced Encryption Standard) is a widely used symmetric encryption algorithm that provides 128-bit, 192-bit, and 256-bit encryption strengths. In this embodiment, one of the following algorithms—DES, 3DES, AES, RC4, RC5, or Blowfish—is used as the symmetric encryption algorithm.

[0051] S13. Encrypt the message digest using an asymmetric encryption algorithm to obtain the traceable information key.

[0052] Asymmetric encryption algorithms, also known as public-key encryption algorithms, are a type of encryption that uses different keys for encryption and decryption. Encryption and decryption are relatively slow and only suitable for encrypting small amounts of data. The principle is to use a pair of keys: a public key and a private key. The public key can be made public to anyone, while the private key can only be accessed by the key holder. If data is encrypted with the public key, it can only be decrypted with the corresponding private key. This encryption method provides higher security because the private key does not need to be shared with others; only the person holding the private key can decrypt and sign.

[0053] The main algorithms for asymmetric encryption include:

[0054] The RSA algorithm is one of the earliest and most widely used asymmetric encryption algorithms. It is based on the problem of factoring large integers and achieves encryption and decryption by generating a pair of large prime numbers as private and public keys. The security of the RSA algorithm depends on the difficulty of factoring large integers. Therefore, with the improvement of computer computing power, the RSA algorithm may need a larger key length to ensure security.

[0055] Elliptic Curve Cryptography (ECC) is an asymmetric encryption algorithm based on elliptic curve mathematics. Compared to RSA, ECC provides the same security with a shorter key length, making it more suitable for resource-constrained environments. ECC offers higher efficiency and stronger security, and is therefore widely used in modern communications and information security.

[0056] The DSA algorithm (Digital Signature Algorithm) is an asymmetric encryption algorithm used for digital signatures. It generates a key pair: a private key is used to sign the message, and a public key is used to verify the validity of the signature. The DSA algorithm is primarily used to ensure the integrity of data and the authenticity of its source.

[0057] In the embodiments, the RSA algorithm, ECC algorithm, or DSA algorithm is used as the asymmetric encryption algorithm.

[0058] S2. Upload the encrypted traceable information to the blockchain network to obtain a unique blockchain address.

[0059] Specifically, choose a suitable blockchain platform based on your needs, such as Bitcoin or Ethereum. These platforms offer a wealth of development tools and documentation, which helps in uploading and storing data.

[0060] Before using a blockchain platform, you need to create a wallet to store your private and public keys. This wallet can be a software wallet or a hardware wallet, used to manage blockchain addresses and conduct transactions.

[0061] Create a smart contract according to the platform's rules. A smart contract is a self-executing code used to store and process data on the blockchain. Deploying the written smart contract to the blockchain platform typically involves uploading the smart contract code to the blockchain server and having it verified and confirmed on the network.

[0062] Connect to the blockchain server using developer tools or API, and write code to upload data based on the chosen blockchain platform and smart contract. The code needs to call smart contract functions to upload encrypted data.

[0063] After uploading the data, you need to wait for the blockchain network to confirm it to ensure the validity and integrity of the transaction. This usually involves waiting for a certain number of blocks to be mined to confirm the validity of the transaction.

[0064] After the data is uploaded and the transaction is confirmed, the blockchain network generates a unique blockchain address. This address is associated with the uploaded encrypted data and can be used for subsequent data retrieval and verification.

[0065] S3. Generate a public key and a private key, and use the public key to encrypt the unique address of the blockchain and the traceability information key to obtain the port cargo traceability ciphertext.

[0066] In this embodiment, step S3, generating the public and private keys, includes the following steps:

[0067] S31. Randomly select multiple prime numbers and obtain the first modulus through the prime numbers.

[0068] The first modulus obtained through the prime number satisfies the following formula:

[0069] ,in, Represents the first modulus. Indicates the first A prime number, Indicates the number of prime numbers. This represents the integer function.

[0070] S32. Sort the prime numbers according to the size of the first modulus and the prime numbers, and adjust the prime numbers accordingly.

[0071] The prime numbers are sorted and adjusted according to the first modulus and the size of the prime numbers to satisfy:

[0072] ,in, This indicates the length of the first modulus.

[0073] S33. Based on the adjusted prime numbers, obtain the second modulus and Euler's totient function.

[0074] Based on the adjusted prime numbers, the second modulus and Euler's totient function are obtained, satisfying the following formula:

[0075] ,in, Represents the second modulus. Indicates the first A number of adjusted prime numbers. This indicates the number of prime numbers after adjustment. This represents an integer function;

[0076] ,in, This represents the Euler totient function.

[0077] S34. Combining the second modulus and the Euler totient function, randomly select a positive integer.

[0078] By combining the second modulus and the Euler's totient function, a positive integer is randomly selected that satisfies the following formula:

[0079] ,in, Represents the second modulus. Represents positive integers. Represents Euler's totient function. This represents the greatest common divisor function.

[0080] S35. Combining the positive integer and the Euler totient function, obtain the third modulus.

[0081] By combining the positive integer and the Euler's totient function, the third modulus is obtained, which satisfies the following formula:

[0082] ,in, Represents the third modulus. Represents positive integers. Represents Euler's totient function. Let the new modulus be a given, and satisfy the following: , , Represents the second modulus. Indicates the first A number of adjusted prime numbers.

[0083] S36. Combine the positive integer and the second modulus to generate a private key.

[0084] In an embodiment, the private key is a combination or vector of the positive integer and the second modulus.

[0085] S37. Combine the third modulus and the second modulus to generate a public key.

[0086] In this embodiment, the public key is a combination or vector of the third modulus and the second modulus.

[0087] Furthermore, the step of encrypting the blockchain unique address and the traceability information key using the public key to obtain the port cargo traceability ciphertext includes the following steps:

[0088] S38. Integrate the blockchain unique address and the traceable information key.

[0089] The blockchain unique address and the traceable information key are merged according to a preset method. In this embodiment, the blockchain unique address and the traceable information key are cross-arranged to form new data as the fusion result.

[0090] S39. Use a chaotic mapping model to map the fusion results to obtain the mapping results;

[0091] Furthermore, the chaotic mapping model satisfies the following formula:

[0092] ,in, The parameters represent the first chaotic mapping. The parameters represent the second chaotic mapping. Indicated by The value is the result of iterating through the second chaotic mapping from the initial value. This indicates the initial value after the first chaotic mapping. One value, and This represents the parameter values ​​that satisfy the chaotic mapping.

[0093] The first and second chaotic mappings are chaotic mapping functions with control parameters. The chaotic behavior of the system can be adjusted by modifying the introduced control parameters. The following chaotic mapping functions are included in the embodiment:

[0094] The chaotic mappings are Logistic, Tent, Chebyshev, Circle, Henon, Cubic, Bernoulli, Piecewise, and Sine, with the first and second chaotic mappings being one or both.

[0095] For example, if the first chaotic map is a Logistic chaotic map, then... The value of is the control parameter range for the Logistic chaotic mapping, which is within (3.57, 4].

[0096] S310. Encrypt the mapping result and the parameters of the chaotic mapping model using the public key to obtain the port cargo traceability ciphertext.

[0097] S310 describes encrypting the mapping result and the parameters of the chaotic mapping model using the public key to obtain the port cargo traceability ciphertext, satisfying the following formula:

[0098] ,in, This indicates encrypted information for port cargo traceability. This represents the mapping result and the parameters of the chaotic mapping model. This represents the third modulus in the public key. The new modulus in the representation.

[0099] S4. Decrypt the port cargo traceability ciphertext using the private key to obtain the port cargo traceability plaintext, and then obtain the port cargo traceability information.

[0100] In this embodiment, the process of decrypting the ciphertext of port cargo traceability using the private key to obtain the plaintext of port cargo traceability satisfies the following formula:

[0101] , This represents the selected positive integer.

[0102] The mapping result and the parameters of the chaotic mapping model are obtained by decrypting with the private key. Then, the reverse mapping process is performed to obtain the unique blockchain address and the traceability information key. Finally, the data is decrypted again to obtain the plaintext of port cargo traceability.

[0103] Please see Figure 2 In an embodiment, to efficiently execute the port cargo traceability method based on big data provided by the present invention, the present invention also provides a port cargo traceability system based on big data, comprising: an input device, an output device, a processor, and a memory, wherein the input device, output device, processor, and memory are interconnected, and the memory contains program instructions for the steps of the port cargo traceability method based on big data. The port cargo traceability system based on big data of the present invention has a compact structure and stable performance, and can stably execute the port cargo traceability method based on big data of the present invention, further enhancing the overall applicability and practical application capability of the present invention.

[0104] In embodiments, the processor may be a Central Processing Unit (CPU), but it can also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor. Input devices can be used to acquire data information. Output devices can be used to output the results obtained by storing program instructions contained in a computer program in the memory provided by this invention. The memory may include read-only memory and random access memory, and provides instructions and data to the processor. A portion of the memory may also include non-volatile random access memory.

[0105] In yet another alternative embodiment, please refer to Figure 3 To efficiently implement the port cargo traceability method based on big data provided by this invention, this embodiment also provides a port cargo traceability device based on big data, such as... Figure 3 As shown, it includes:

[0106] The memory 10 stores the computer program; the processor 20 executes the computer program to implement the aforementioned port cargo traceability method based on big data. The system includes the memory 10, processor 20, communication interface 31, and communication bus 32. The memory 10, processor 20, and communication interface 31 all communicate with each other via the communication bus 32.

[0107] In this embodiment, the memory 10 is used to store one or more program instructions. The memory 10 may store program instructions for implementing the following functions:

[0108] Based on big data technology, traceability information of port cargo is obtained, and the traceability information is encrypted to obtain traceability information ciphertext and traceability information key;

[0109] Upload the encrypted traceability information to the blockchain network to obtain a unique blockchain address;

[0110] Generate a public key and a private key, and use the public key to encrypt the unique address of the blockchain and the traceability information key to obtain the port cargo traceability ciphertext;

[0111] The port cargo traceability ciphertext is decrypted using the private key to obtain the port cargo traceability plaintext, thereby obtaining the port cargo traceability information.

[0112] In one possible implementation, memory 10 may include a program storage area and a data storage area. The program storage area may store the operating system and applications required for at least one function; the data storage area may store data created during use. Furthermore, memory 10 may include read-only memory and random access memory, providing instructions and data to the processor. A portion of the memory may also include NVRAM. The memory stores the operating system and operating instructions, executable modules, or data structures, or subsets thereof, or extended sets thereof. The operating instructions may include various operation instructions for implementing various operations. The operating system may include various system programs for implementing various basic tasks and handling hardware-based tasks.

[0113] Processor 20 can be a Central Processing Unit (CPU), an application-specific integrated circuit, a digital signal processor, a field-programmable gate array, or other programmable logic device. Processor 20 can be a microprocessor or any conventional processor. Processor 20 can call programs stored in memory 10. Communication interface 31 can be an interface for a communication module, used to connect with other devices or systems.

[0114] Of course, it should be noted that, Figure 3The structure shown does not constitute a limitation on the port cargo traceability device based on big data in this embodiment. In practical applications, port cargo traceability devices based on big data can include more... Figure 3 More or fewer components as shown, or combinations of certain components.

[0115] The embodiment also provides a storage medium storing a computer program, which, when executed by a processor, implements the steps of the above-described port cargo traceability method based on big data.

[0116] The storage medium can include various media that can store program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0117] In summary, this invention obtains relevant information about port cargo using big data technology, encrypts it, and then stores it in the blockchain. The use of multiple encryption methods solves the problem that the relevant information about port cargo is easily modified, resulting in poor reliability of traceability information. Furthermore, the use of blockchain as a data storage site improves the efficiency of data traceability.

[0118] Therefore, this invention effectively overcomes the various shortcomings of the prior art and has high industrial application value.

[0119] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention, and they should all be covered within the scope of the present invention.

Claims

1. A big data based port cargo traceability method, characterized in that, The port cargo traceability method based on big data comprises the following steps: Based on big data technology, obtain the traceable information of the port cargo, encrypt the traceable information, obtain the traceable information ciphertext and the traceable information secret key; Upload the traceable information ciphertext to the block chain network to obtain a unique block chain address; Generate a public key and a private key, encrypt the unique block chain address and the traceable information secret key using the public key, and obtain the port cargo traceability ciphertext; Decrypt the port cargo traceability ciphertext using the private key to obtain the port cargo traceability plaintext, and further obtain the traceability information of the port cargo; The traceable information is encrypted to obtain the traceable information ciphertext and the traceable information secret key, comprising the following steps: Obtain an information digest using a Hash function; Encrypt the traceable information using the information digest as the secret key of the symmetric encryption algorithm to obtain the traceable information ciphertext; Encrypt the information digest using an asymmetric encryption algorithm to obtain the traceable information secret key; The public key is used to encrypt the unique block chain address and the traceable information secret key to obtain the port cargo traceability ciphertext, comprising the following steps: Fuse the unique block chain address and the traceable information secret key; Map the fusion result using a chaotic mapping model to obtain a mapping result; Encrypt the mapping result and the parameters of the chaotic mapping model using the public key to obtain the port cargo traceability ciphertext; Randomly select a plurality of prime numbers to obtain a first modulus from the prime numbers; Sort the first modulus and the prime numbers according to their sizes, and adjust the prime numbers; Obtain a second modulus and an Euler function according to the adjusted prime numbers; Randomly select a positive integer in combination with the second modulus and the Euler function; Combine the positive integer and the Euler function to obtain a third modulus; Combine the positive integer and the second modulus to generate a private key; Combine the third modulus and the second modulus to generate a public key; The first modulus is obtained from the prime numbers, which satisfies the following formula: wherein, denotes the first modulus, denotes the first prime number, denotes the number of prime numbers, denotes the floor function; The first modulus and the prime numbers are sorted according to their sizes, and the prime numbers are adjusted, which satisfies: wherein, denotes the length of the first modulus; The second modulus and the Euler function are obtained according to the adjusted prime numbers, which satisfy the following formula: wherein, denotes the second modulus, denotes the adjusted prime number, denotes the number of adjusted prime numbers, denotes the floor function; wherein denotes the Euler function; A positive integer is randomly selected in combination with the second modulus and the Euler function, which satisfies the following formula: wherein, denotes the second modulus, denotes a positive integer, denotes the Euler function, denotes the greatest common divisor function; The third modulus is obtained in combination with the positive integer and the Euler function, which satisfies the following formula: wherein, denotes a third modulus, denotes a positive integer, denotes the Euler function, denotes a new modulus and satisfies: , , denotes a second modulus, denotes a adjusted prime number; The private key is the combination or vector of the positive integer and the second modulus; The public key is the combination or vector of the third modulus and the second modulus; The chaotic mapping model satisfies the following formula: wherein, denotes a parameter of the first chaotic map, denotes a parameter of the second chaotic map, denotes a value iterated out of the second chaotic map with as an initial value, denotes the n-th value of the initial value iterated through the first chaotic map, denotes the n-th value of the initial value iterated through the first chaotic map, and denotes a parameter value satisfying the chaotic map; The first chaotic mapping and the second chaotic mapping are chaotic mapping functions with control parameters, and the chaotic behavior of the system can be adjusted by modifying the introduced control parameters.

2. A big data based port cargo traceability system characterized in that, The port cargo traceability system based on big data comprises an input device, an output device, a processor, and a memory, which are connected to each other. The memory comprises program instructions for executing the port cargo traceability method based on big data.

Citation Information

Patent Citations

  • Privacy protection bidding method based on blockchain

    CN108650073A

  • Energy data tracing method and device based on block chain technology

    CN115860757A