Product quality authentication and digital identity identification method and device
By timestamping product data and performing blockchain hash calculations during transportation, an immutable quality certification certificate is generated. Furthermore, by utilizing IoT and AI technologies to generate QR code identifiers, the problem of difficulty in real-time monitoring of product status under traditional quality certification models is solved, enabling efficient quality traceability throughout the entire product lifecycle.
Patent Information
- Application Number
- CN202511645944.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-11
- Publication Date
- 2026-02-13
AI Technical Summary
Traditional quality certification models struggle to monitor the true condition of products in real time within complex supply chain environments, especially for sensitive goods such as fresh food and pharmaceuticals that are susceptible to transportation conditions, making it difficult to fully reflect quality.
By monitoring and timestamping transportation data, using blockchain technology for hashing and digital signatures, and combining this with IoT technology to generate tamper-proof quality certification credentials, and using AI technology for quality traceability analysis, a QR code is generated to identify the product.
It enables real-time quality monitoring and certification throughout the entire product lifecycle, ensuring that quality records are tamper-proof and traceable, and providing efficient quality traceability analysis reports.
Smart Images

Figure CN121526408A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of blockchain technology, and in particular to a method and apparatus for product quality authentication and digital identity verification. Background Technology
[0002] With consumers increasingly demanding higher product quality and safety, product quality certification has become a crucial link in ensuring fair market competition and protecting consumer rights. Traditional quality certification models largely rely on static laboratory test reports or periodic on-site audits. This post-event traceability and random verification approach cannot fully reflect the true state of a product in a complex supply chain environment. This is especially true for sensitive commodities such as fresh food and pharmaceuticals, whose quality is easily deteriorated during distribution due to factors such as temperature and humidity changes and severe vibrations. Therefore, establishing a real-time quality monitoring and certification system that spans the entire product lifecycle, particularly covering dynamic aspects such as transportation, has become a critical area for improvement in current quality supervision. Summary of the Invention
[0003] The present invention aims to solve at least one of the technical problems existing in the prior art. To this end, the present invention proposes a method and apparatus for product quality certification and digital identity identification.
[0004] The technical solution adopted in this invention is: On one hand, embodiments of the present invention provide a product quality certification and digital identity verification method, including the following steps: Monitor the transportation process of the target product, obtain transportation link data, and timestamp the transportation link data to obtain time-series quality data; The authenticity of the time-series quality data is verified based on a preset authentication mechanism to obtain the data verification results. The data verification results are hashed and digitally signed using a pre-defined blockchain technology to obtain an immutable record. Consensus verification is then performed based on this immutable record to obtain a quality certification certificate. The quality certification certificate is graphically converted based on encoding conversion rules to obtain a QR code, and a quick retrieval identifier is added to the QR code using Internet of Things technology to obtain the product identity identifier. Based on the AI technology, the target product is analyzed for quality traceability based on the product identity identifier, resulting in a full-chain quality report.
[0005] Furthermore, the monitoring of the target product's transportation process yields transportation stage data, which is then timestamped to obtain time-series quality data, including: By collecting parameters from the transportation process and related production links of the target product through sensors, comprehensive raw data covering transportation environment parameters and original production parameters is obtained. Outlier identification and removal are performed on the comprehensive raw data to obtain transportation link data. The transportation data is timestamped by embedding a high-precision system clock to obtain time-stamped transportation data. The time-stamped transportation data is then sorted according to the transportation process nodes and their corresponding time sequence to form time-series quality data.
[0006] Furthermore, the authenticity verification of the time-series quality data based on the preset authentication mechanism is performed to obtain the data verification result, including: The time-series quality data is subjected to data integrity detection to obtain a data integrity index, and data is completed based on the data integrity index to obtain complete quality data; The complete quality data is compared for source consistency using data source verification rules to obtain data source verification records. The credibility of the data source verification records is then evaluated to obtain the source credibility. Using a pre-set authentication mechanism, the authenticity of the complete quality data is determined based on the credibility of the source, and the data verification result is obtained.
[0007] Furthermore, the step of performing hash calculations and digital signatures on the data verification results using preset blockchain technology to obtain an immutable record includes: The data verification results are hashed using a pre-defined blockchain technology to obtain a preliminary hash value of fixed length. The responsible entity's private key is used to digitally sign the initial hash value to obtain the signature ciphertext. The signature ciphertext is then appended to the end of the hash association data to obtain the signature data file. Obtain the public key of the responsible entity, perform digital signature verification on the ciphertext of the signature in the signature data file, obtain the signature verification result, and integrate the signature verification result with the signature data file to obtain an immutable record.
[0008] Furthermore, the consensus verification based on the immutable record to obtain the quality certification certificate includes: The immutable record is embedded with an authoritative institution identifier to obtain institution marker data, and the institution marker data is broadcast to multiple nodes to obtain the block to be verified. Based on the Byzantine fault tolerance mechanism, the block to be verified is voted on by nodes to obtain a consensus confirmation result, and the block to be verified is written to the main chain based on the consensus confirmation result to obtain an on-chain evidence record. The on-chain evidence records are formatted and encapsulated using a smart contract to obtain a standard certification document. The standard certification document is then digitally stamped with an authoritative seal to obtain a quality certification certificate.
[0009] Furthermore, the quality certification certificate is graphically converted based on encoding conversion rules to obtain a QR code, and a quick retrieval identifier is added to the QR code using Internet of Things (IoT) technology to obtain the product identification identifier, including: The quality certification certificate is used to extract search fields to obtain core search information. The core search information is then formatted to obtain a standard information string. Based on a preset encoding conversion rule, the standard information string is graphically converted to generate a QR code. Anti-counterfeiting features are embedded in the QR code to obtain an anti-counterfeiting QR code. The anti-counterfeiting QR code is combined with the product's basic information to obtain a composite identification image. A quick search identifier is added to the composite identification image using Internet of Things (IoT) technology to obtain the product identity identifier.
[0010] Furthermore, the step of performing graphical conversion on the standard information string based on preset encoding conversion rules to generate a QR code includes: Repeated fields are removed from the standard information string to obtain a simplified information string. The simplified information string is then compressed to obtain a compressed information string. Based on a preset information importance level, the compressed information string is classified into hierarchical information groups. These hierarchical information groups are then encoded using encoding rules with different densities to obtain hierarchical encoding dot matrices. Based on a preset encoding conversion rule, the hierarchical encoding dot matrices are arranged according to the QR code format specification to obtain a QR code.
[0011] The present invention also provides a product quality certification and digital identity identification device, comprising: The monitoring module is used to monitor the transportation process of the target product, obtain transportation link data, and timestamp the transportation link data to obtain time-series quality data. The verification module is used to verify the authenticity of the time-series quality data based on a preset authentication mechanism, and obtain the data verification result. The verification module is used to perform hash calculations and digital signatures on the data verification results using preset blockchain technology to obtain an immutable record, and to perform consensus verification based on the immutable record to obtain a quality certification certificate. An additional module is added to perform graphic conversion on the quality certification certificate based on encoding conversion rules to obtain a QR code, and to add a quick retrieval identifier to the QR code using Internet of Things technology to obtain the product identity identifier. The analysis module is used to perform quality traceability analysis on the target product based on the AI technology and the product identity identifier, and obtain a product full-chain quality report.
[0012] The present invention also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of any of the methods described above.
[0013] The present invention also provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of any of the methods described above.
[0014] This invention provides a product quality certification and digital identity identification method, comprising the following steps: monitoring the transportation process of a target product to obtain transportation link data, and timestamping the transportation link data to obtain time-series quality data; verifying the authenticity of the time-series quality data based on a preset authentication institution to obtain data verification results; performing hash calculations and digital signatures on the data verification results using preset blockchain technology to obtain an immutable record, and performing consensus verification based on the immutable record to obtain a quality certification certificate; performing graphic conversion on the quality certification certificate based on encoding conversion rules to obtain a QR code, and adding a quick retrieval identifier to the QR code using IoT technology to obtain a product identity identifier; and performing quality traceability analysis on the target product based on the product identity identifier using AI technology to obtain a full-chain quality report. This method solves the technical problem that traditional quality certification models cannot fully reflect the true state of products in complex supply chain environments. By performing hash calculations and digital signatures on the data verification results, combined with the consensus mechanism of blockchain, it ensures that all quality records are immutable and unforgeable once uploaded to the blockchain. Attached Figure Description
[0015] The above and / or additional aspects and advantages of the present invention will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which: Figure 1 This is a flowchart illustrating the steps of the product quality certification and digital identity verification method in an embodiment of the present invention. Figure 2 This is a structural block diagram of the product quality certification and digital identity identification device in an embodiment of the present invention; Figure 3 This is a schematic block diagram of the structure of a computer device according to an embodiment of the present invention.
[0016] The objectives, features, and advantages of this invention will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0017] Embodiments of the present invention are described in detail below. Examples of these embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and should not be construed as limiting the present invention.
[0018] In the description of this invention, it should be understood that the orientation descriptions, such as up, down, front, back, left, right, etc., are based on the orientation or positional relationship shown in the accompanying drawings. They are only for the convenience of describing this invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limiting this invention.
[0019] In the description of this invention, "several" means one or more, "more than" means two or more, "greater than," "less than," and "exceeding" are understood to exclude the stated number, while "above," "below," and "within" are understood to include the stated number. The use of "first" and "second" in the description is merely for distinguishing technical features and should not be construed as indicating or implying relative importance, or implicitly indicating the number of indicated technical features, or implicitly indicating the order of the indicated technical features.
[0020] In the description of this invention, unless otherwise explicitly defined, terms such as "set up," "install," and "connect" should be interpreted broadly, and those skilled in the art can reasonably determine the specific meaning of the above terms in this invention in conjunction with the specific content of the technical solution.
[0021] The embodiments of this application will be further described below with reference to the accompanying drawings.
[0022] Reference Figure 1 This invention provides a product quality certification and digital identity verification method, comprising the following steps: Step S1: Monitor the transportation process of the target product, obtain transportation link data, and timestamp the transportation link data to obtain time-series quality data.
[0023] Specifically, the process involves monitoring the transportation of the target product to obtain transportation data, and then timestamping this data to obtain time-series quality data. This process is achieved by deploying IoT devices with sensing capabilities for temperature, humidity, acceleration, and light in the transport containers or product packaging. These devices continuously collect environmental and physical state parameters during transportation, forming raw transportation data. Once the data is collected, the built-in time module of the sensing device immediately adds a precise timestamp according to a standard time source, ensuring that each data record contains time-series information strictly corresponding to its collection time. Subsequently, this timestamped transportation data is transmitted via wireless communication technologies such as NB-IoT. Alternatively, data can be transmitted via LoRa to a local or cloud data server, formatted, and then arranged and stored in a time sequence to form complete time-series quality data. This data not only reflects the actual experience of the product during transportation but also provides traceable time evidence for subsequent authenticity verification. For example, in the application scenario of cold chain transportation of medicines, temperature control sensors record the temperature value inside the compartment every 5 minutes and automatically add a UTC timestamp. If the temperature in a certain interval exceeds the preset threshold, the abnormal data point along with the timestamp will be completely retained as key evidence to determine whether the medicine has experienced a "temperature break" and used to form an undeniable quality record in the subsequent verification process of the authentication agency and blockchain evidence storage process.
[0024] Step S2: The authenticity of the time-series quality data is verified based on a preset authentication mechanism to obtain the data verification result.
[0025] Specifically, the authenticity of the time-series quality data is verified by a pre-defined authentication agency to obtain data verification results. This process is achieved by uploading the time-series quality data, collected and timestamped from the transportation stage, to a verification platform deployed by an authentication agency acting as a third-party certification center or industry regulatory body. This authentication agency is pre-configured with a list of legitimate sensing device identities, data format specifications, and communication encryption keys. Upon receiving the time-series quality data, it first verifies whether the data source device is registered in the trusted device library, then checks whether the digital signature of the data packet is valid to confirm that it has not been tampered with during transmission, and simultaneously compares the continuity and rationality of the timestamp sequence to eliminate time jumps. In case of anomalies such as skipped or duplicate records, combined with geographic location information and transportation route planning, it is determined whether the time and spatial logic of data collection matches. For example, in the application scenario of cold chain transportation of pharmaceuticals, if a certain temperature control record shows that the vehicle is in a high-speed driving state but the temperature data remains constant for a long time, or there is no temperature fluctuation during the loading and unloading period, it is considered suspicious data. The authentication agency will mark the time-series quality data as abnormal. Finally, by combining all verification rules, a unified data verification result is output. This result clearly identifies the authenticity status of each batch of data and serves as the input basis for subsequent blockchain evidence storage, ensuring that only credible data that has passed verification can enter the tamper-proof record generation process.
[0026] Step S3: The data verification result is hashed and digitally signed using a preset blockchain technology to obtain an immutable record. Consensus verification is then performed based on the immutable record to obtain a quality certification certificate.
[0027] Specifically, the data verification results are hashed and digitally signed using pre-defined blockchain technology to obtain an immutable record. Consensus verification is then performed based on this immutable record to obtain a quality certification certificate. This process first imports the data verification results output by the authentication agency into the node system connected to the blockchain network in a structured data format. A unique hash value is generated for the data verification results using encryption algorithms such as SHA-256. Then, the hash value is digitally signed using a private key to ensure the data source is traceable and has not been substituted. Next, the signed hash value, along with a timestamp and participating node information, is packaged into a transaction block and broadcast to a consortium blockchain network composed of producers, logistics providers, regulatory agencies, and other parties. Upon receiving the block, each consensus node... The pre-defined PBFT or RAFT consensus mechanism verifies the hash value and signature within the block. After a majority of nodes reach a consensus, the block is written into the distributed ledger of the blockchain, forming an immutable record that cannot be modified once recorded. For example, in the application scenario of cold chain transportation of medicines, the transportation data of a batch of vaccines is verified to be within the temperature range of 2℃~8℃ throughout the process without any abnormal interruptions. The corresponding data verification results are stored on the blockchain after the above-mentioned hash operation and digital signature process. All participants can query the record through the public interface. At the same time, the system automatically generates a quality certification certificate containing the blockchain address, transaction ID, and signature information, which serves as digital proof that the vaccine meets the quality requirements during transportation and is used for subsequent QR code generation and traceability.
[0028] Step S4: Based on the encoding conversion rules, the quality certification certificate is graphically converted to obtain a QR code, and a quick retrieval identifier is added to the QR code using Internet of Things technology to obtain the product identity identifier.
[0029] Specifically, the quality certification certificate is graphically converted based on encoding conversion rules to obtain a QR code. Then, using IoT technology, a quick retrieval identifier is added to the QR code to obtain the product identity. This process first serializes the quality certification certificate generated after blockchain consensus verification according to preset encoding conversion rules. These rules define field mapping relationships and data compression formats, converting the certificate content, including the blockchain address, transaction hash, signature information, and timestamp, into a standardized string or binary code stream. Subsequently, a QR code generation algorithm, such as QR Code, is called. The ISO / IEC 18004 standard uses image encoding to generate a scannable two-dimensional matrix. Simultaneously, a rapid retrieval identifier based on IoT technology is embedded in the QR code's data structure. This identifier is a uniquely bound UID or EPC code associated with the product and linked to a distributed indexing service. This allows scanning devices to directly locate the specific record in the blockchain ledger using this identifier, initiating a data query without fully parsing the QR code content. For example, in the application scenario of cold chain transportation of pharmaceuticals, the QR code on a vaccine package, when generated, not only contains the encoded data of its quality certification certificate but also embeds the unique electronic tag ID of the vaccine vial as a rapid retrieval identifier. When regulatory personnel scan the QR code with a handheld terminal, the system immediately obtains the vaccine's storage path from the IoT platform through this identifier and retrieves the immutable record on the blockchain in real time for efficient verification. Finally, the QR code is printed or affixed to the product itself, forming a product identity identifier with high security and machine readability.
[0030] Step S5: Based on the AI technology and the product identity identifier, perform quality traceability analysis on the target product to obtain a product full-chain quality report.
[0031] Specifically, based on the AI technology and the product identification identifier, a quality traceability analysis is performed on the target product to obtain a full-chain quality report. This process first involves scanning or reading the product identification identifier attached to the target product to obtain the encoded information and quick retrieval identifier contained therein. Using this quick retrieval identifier, the entire lifecycle data nodes of the product are located and associated in the IoT platform, including production batches, processing parameters, quality inspection records, warehousing environment, and time-series quality data and data verification results already uploaded to the blockchain during transportation. Subsequently, this multi-source heterogeneous data is input into a pre-trained AI analysis model. This model uses time series analysis algorithms and anomaly detection neural networks to parse the data stream and identify whether there are excessive temperatures, severe vibrations, or prolonged exposure during transportation. The system analyzes and addresses risks such as delays and disruptions, combining historical data and industry standards to assess the impact weight of each stage on the final quality. It also utilizes natural language generation technology to structure the analysis results, generating a complete text covering key indicators, risk warnings, and compliance status at each stage. For example, in the application scenario of cold chain transportation of pharmaceuticals, after scanning the product identification of a vaccine, the system retrieves data from its entire process from factory to delivery. The AI model discovers that during one segment of transportation, the refrigerated truck temperature remained above 8°C for three consecutive hours. Although no hard alarm was triggered, this was within a critical risk range. Based on this, the model determines this period as a potential quality hazard and clearly marks the abnormal range, duration, possible impact, and recommended handling methods in the generated product full-chain quality report. Finally, this report, along with a visualized trend, is presented in the report. Figure 1 It generates and stores data for use in regulatory, distribution, or consumption processes. Additionally, the AI model can be a linear regression model or an ARIMA model, etc.
[0032] In a specific embodiment, the monitoring of the target product's transportation process yields transportation stage data, and the transportation stage data is timestamped to obtain time-series quality data, including: By collecting parameters from the transportation process and related production links of the target product through sensors, comprehensive raw data covering transportation environment parameters and original production parameters is obtained. Outlier identification and removal are performed on the comprehensive raw data to obtain transportation link data. The transportation data is timestamped by embedding a high-precision system clock to obtain time-stamped transportation data. The time-stamped transportation data is then sorted according to the transportation process nodes and their corresponding time sequence to form time-series quality data.
[0033] Specifically, sensors collect parameters from the transportation process and related production stages of the target product, obtaining comprehensive raw data covering transportation environment parameters and original production parameters. Outlier identification and removal are performed on this comprehensive raw data to obtain transportation stage data. Time stamps are embedded into this transportation stage data based on a high-precision system clock, resulting in time-stamped transportation data. This time-stamped transportation data is then correlated and sorted according to transportation process nodes and their corresponding time sequences to form time-series quality data. This process first deploys sensors in the target product's production stage to collect original production parameters. On the filling line, the filling time, batch number, and initial temperature of the medicine are recorded. During the packaging stage, sealing integrity signals are collected. Simultaneously, temperature, humidity, vibration, and position sensors are deployed in the refrigerated containers during transportation to continuously collect transportation environment parameters. All collected data is uploaded to an edge computing gateway to form comprehensive raw data containing production and transportation information. Subsequently, statistical methods or machine learning models are used to analyze this data. Significant deviations in the raw data are identified. For example, if a temperature reading suddenly jumps from 4°C to 50°C within a short period and then returns to normal, it is determined to be caused by a momentary sensor malfunction and is discarded. Valid data is retained as transportation data. Then, a high-precision system clock with GPS synchronization adds a millisecond-accurate timestamp to each transportation data point, generating time-stamped transportation data. The data segments are classified and labeled according to transportation process nodes such as loading, en route, transshipment, and unloading. Finally, the data from each node are linked and integrated in chronological order to form a complete and clearly ordered time-series quality data. For example, in the application scenario of cold chain transportation of pharmaceuticals, the environmental parameters of a batch of vaccines are continuously collected and time-stamped at each stage from the time it leaves the pharmaceutical factory, including temporary storage in cold storage, loading and transportation, temperature control during en route, and arrival at the hospital's cold chain warehouse. After outlier cleaning, the data is sorted by time node to form a time-series data chain reflecting the quality changes throughout the entire transportation process, providing a basic input for subsequent authenticity verification.
[0034] In a specific embodiment, the authenticity verification of the time-series quality data based on a preset authentication mechanism, to obtain data verification results, includes: The time-series quality data is subjected to data integrity detection to obtain a data integrity index, and data is completed based on the data integrity index to obtain complete quality data; The complete quality data is compared for source consistency using data source verification rules to obtain data source verification records. The credibility of the data source verification records is then evaluated to obtain the source credibility. Using a pre-set authentication mechanism, the authenticity of the complete quality data is determined based on the credibility of the source, and the data verification result is obtained.
[0035] Specifically, the time-series quality data undergoes data integrity testing to obtain a data integrity index. Based on this index, data is completed to obtain complete quality data. The complete quality data is then compared for source consistency using data source verification rules to obtain data source verification records. These records are then evaluated for credibility to obtain source credibility. Finally, a pre-defined authentication agency determines the authenticity of the complete quality data based on the source credibility, resulting in a data verification result. This process first imports the time-series quality data generated during transportation and production into the authentication agency's data processing module, initiating the data integrity testing process. This process analyzes the time intervals between data points in the time series. The system determines whether missing data exists by checking if the data collection frequency matches a preset range. For example, in cold chain pharmaceutical transportation, if a temperature sensor is set to record temperature every 5 minutes, but only 4 records are recorded within a consecutive 30-minute period, a data breakpoint is identified. The system calculates a data integrity index, which reflects the ratio between the actual number of records and the theoretically expected number of records. When the data integrity falls below a threshold, a data completion mechanism is activated. Linear interpolation or a regression model based on historical trends is used to reasonably estimate and fill in the missing data, ensuring that subsequent analysis is not interrupted by data gaps, thus forming structurally complete and high-quality data. Subsequently, the system enters the data source verification stage, where the authentication agency calls the preset data source for verification. The verification rules perform source consistency comparison on complete quality data. These rules include device identity certificates, communication encryption keys, IP address attribution, and geographic location matching logic. The system verifies whether each piece of data comes from a registered, legitimate sensing device and checks the validity of its digital signature. It also compares the GPS trajectory with the predetermined transportation route. If a segment of temperature data is found to originate from an unauthorized device or its location drift exceeds a reasonable range, it is marked as abnormal, and a corresponding data source verification record is generated. Next, the data source verification record undergoes a credibility assessment. The assessment model assigns weights based on dimensions such as the device's historical compliance rate, network transmission stability, and multi-node cross-validation results, and calculates a quantified value as the source credibility. For example, a sensor's credibility over the past 1... If all transport missions have uploaded data on time without any tampering records, the source credibility score is relatively high. Finally, the preset authentication agency comprehensively judges the authenticity of the data based on the source credibility and the content logic of the complete quality data. If the source credibility is higher than the set threshold and there are no contradictions within the data (such as the temperature change rate not conforming to physical laws), the data is judged to be authentic and valid, and a data verification result of "pass" status is output. Otherwise, it is marked as "questionable" or "forged". In the application scenario of cold chain transportation of medicines, if a vaccine is transported and the equipment goes offline for a short time and then resumes uploading, the system will find a small amount of missing data after integrity detection. After interpolation to complete the missing data and combining it with the equipment's historical high credibility, the system will judge the overall authenticity and allow it to enter the blockchain evidence storage process.
[0036] In a specific embodiment, the step of performing hash calculations and digital signatures on the data verification results using preset blockchain technology to obtain an immutable record includes: The data verification results are hashed using a pre-defined blockchain technology to obtain a preliminary hash value of fixed length. The responsible entity's private key is used to digitally sign the initial hash value to obtain the signature ciphertext. The signature ciphertext is then appended to the end of the hash association data to obtain the signature data file. Obtain the public key of the responsible entity, perform digital signature verification on the ciphertext of the signature in the signature data file, obtain the signature verification result, and integrate the signature verification result with the signature data file to obtain an immutable record.
[0037] Specifically, the data verification results are hashed using pre-defined blockchain technology to obtain a fixed-length initial hash value. This process first serializes the data verification results output by the authentication agency using a standardized data structure to ensure that its field format meets the parsing requirements of the blockchain node. Then, the SHA-256 encryption algorithm is used to perform a one-way hash operation on the serialized data content, generating a fixed-length string of 256 bits as the initial hash value. This hash value has uniqueness and avalanche effect characteristics; even a small change in the original data will cause a significant change in the hash value, thus providing a mathematical basis for subsequent tamper-proofing. Next, the private key of the responsible entity is invoked. The initial hash value is digitally signed to obtain a signature ciphertext, which is then appended to the end of the hash association data to obtain a signature data file. The responsible entity refers to the specific entity involved in the product circulation process, such as a logistics company or a pharmaceutical manufacturer. Its private key is stored in a Hardware Security Module (HSM) or Trusted Execution Environment (TEE). By calling the encryption interface, the private key is used to perform asymmetric encryption on the initial hash value to generate the corresponding signature ciphertext. This process ensures the non-repudiation of the signing action. Subsequently, the system encapsulates the original data verification result, the initial hash value, and the signature ciphertext together into hash association data, and appends the signature ciphertext to the end of this data packet to form a signature data file. A complete signature data file is constructed; then, the public key of the responsible entity is obtained, and digital signature verification is performed on the ciphertext of the signature in the signature data file to obtain the signature verification result. The signature verification result is then integrated with the signature data file to obtain an immutable record. The public key is obtained from a Certificate Authority (CA) via a digital certificate or pre-registered in the trust list of the blockchain node. During the verification process, the public key is used to decrypt the ciphertext of the signature to restore the original hash value, which is then compared with the locally recalculated hash value of the data verification result. If they match, the signature is deemed valid, and a "verification passed" signature verification result is generated; otherwise, it is marked as "verification failed." Finally, the system will transfer the signature... The authentication result, along with the complete signature data file, is packaged together as an immutable record with identity authentication, integrity verification, and non-repudiation capabilities, ready to be submitted to the blockchain network for consensus verification. For example, in the application scenario of cold chain transportation of pharmaceuticals, after a vaccine transportation task is completed, the logistics company, as the responsible party, processes the data verification result that has passed authentication. After the system generates a preliminary hash value, it calls the company's exclusive private key to complete the signature, forming a signature data file. The regulatory node uses the company's registered public key to verify the validity of the signature. After confirming that there are no errors, it writes the complete data containing the verification result into the consortium blockchain, forming an immutable record, ensuring the authenticity and traceability of the vaccine transportation quality information.
[0038] In a specific embodiment, the step of performing consensus verification based on the immutable record to obtain a quality certification credential includes: The immutable record is embedded with an authoritative institution identifier to obtain institution marker data, and the institution marker data is broadcast to multiple nodes to obtain the block to be verified. Based on the Byzantine fault tolerance mechanism, the block to be verified is voted on by nodes to obtain a consensus confirmation result, and the block to be verified is written to the main chain based on the consensus confirmation result to obtain an on-chain evidence record. The on-chain evidence records are formatted and encapsulated using a smart contract to obtain a standard certification document. The standard certification document is then digitally stamped with an authoritative seal to obtain a quality certification certificate.
[0039] Specifically, the immutable record is embedded with an authoritative institution identifier to obtain institution-marked data. This institution-marked data is then broadcast across multiple nodes to obtain blocks to be verified. This process begins by automatically embedding the unique identifier of the authoritative institution participating in the authentication into the record's metadata field after the immutable record is generated. This identifier is a digital identity code pre-registered in the blockchain network, representing a credible entity such as an authentication agency, regulatory body, or industry certification center. The embedding operation is performed using encryption to prevent tampering, forming institution-marked data with institutional identity information. Subsequently, this institution-marked data is packaged into candidate blocks and transmitted to the blockchain network via a P2P communication protocol. Multiple consensus nodes are initially configured to broadcast information across various stakeholders, including producers, logistics providers, third-party testing agencies, and regulatory bodies, ensuring transparency and visibility to all parties. After broadcasting, all nodes receive the same block to be verified and prepare for the consensus phase. Based on a Byzantine fault tolerance mechanism, the block to be verified is voted on by nodes to obtain a consensus confirmation result. This result is then used to write the block to the main chain, creating an on-chain notarized record. Specifically, the Practical Byzantine Fault Tolerance (PBFT) algorithm is used, with the master node organizing view switching and message synchronization. Each consensus node independently verifies the immutable records in the block to be verified, including verifying digital signatures. After verifying the validity of the name, hash consistency, and the legitimacy of the organization identifier, the system returns three-stage voting messages—"pre-preparation," "preparation," and "commit"—to the master node. Consensus is reached when more than two-thirds of the nodes return the same response, generating a consensus confirmation result of "pass." Conversely, if a majority of nodes return error or rejection signals, it is considered a "failure." Once consensus is reached, all nodes sequentially append the block to be verified to the end of their locally maintained blockchain main chain, forming a globally consistent on-chain evidence record, ensuring that this data is permanently and irreversibly stored in the distributed ledger. A smart contract formats and encapsulates the on-chain evidence record to obtain a standard authentication file, and then authoritatively seals the standard authentication file. The process involves digitally affixing a seal to obtain a quality certification certificate. The smart contract, an automated program deployed on the blockchain, is triggered by a consensus confirmation result of "pass." During contract execution, it automatically reads key fields from the on-chain evidence records, such as product batch number, transportation start and end times, temperature compliance status, and responsible party information. It then generates a structured standard certification document according to a preset template, conforming to the industry's common data exchange format. Subsequently, the system calls the digital seal module of an authoritative institution. This module generates a legally valid electronic signature based on the PKI system and overlays it onto the designated position on the standard certification document, completing the digital affixing of the authoritative seal. Finally, it outputs a quality certification certificate with legal validity and anti-counterfeiting features.For example, in the application scenario of cold chain transportation of pharmaceuticals, the tamper-proof record of a vaccine, after being embedded with the identification of the drug regulatory authority, is broadcast to the pharmaceutical supply chain consortium blockchain. Each node confirms the data's authenticity and validity through PBFT consensus, successfully writing it into the main chain. The smart contract then triggers the generation of a quality certification certificate containing the vaccine number, a conclusion of compliance with temperature control throughout the process, and an electronic regulatory stamp, for subsequent QR code generation and circulation.
[0040] In a specific embodiment, the step of performing graphic conversion on the quality certification certificate based on encoding conversion rules to obtain a QR code, and then using Internet of Things (IoT) technology to add a quick retrieval identifier to the QR code to obtain a product identity identifier, includes: The quality certification certificate is used to extract search fields to obtain core search information. The core search information is then formatted to obtain a standard information string. Based on a preset encoding conversion rule, the standard information string is graphically converted to generate a QR code. Anti-counterfeiting features are embedded in the QR code to obtain an anti-counterfeiting QR code. The anti-counterfeiting QR code is combined with the product's basic information to obtain a composite identification image. A quick search identifier is added to the composite identification image using Internet of Things (IoT) technology to obtain the product identity identifier.
[0041] Specifically, the quality certification certificate is used to extract retrieval fields to obtain core retrieval information. This core retrieval information is then formatted to obtain a standard information string. This process first parses key fields closely related to subsequent queries and verifications from the blockchain-generated quality certification certificate, including product batch number, production date, transportation start and end times, temperature compliance status, responsible entity name, on-chain storage address, and transaction hash value. This information constitutes the core retrieval information. Subsequently, each field is uniformly formatted according to a preset data encoding standard. For example, the time field is converted to the ISO 8601 standard format, the batch number is padded to a fixed length, the Boolean compliance status is mapped to "Y / N" identifiers, and all fields are connected with a specific delimiter to form a standard information string with a consistent structure and controllable length, ensuring compatibility with the input requirements of the subsequent QR code generation algorithm. Based on preset encoding conversion rules, the standard information string is graphically converted to generate a QR code, and anti-counterfeiting features are embedded in the QR code to obtain an anti-counterfeiting QR code. Specifically, the international QR code standard (ISO / IEC) is adopted during execution. Using 18004 as the encoding rule, an image generation engine is invoked to convert the standard information string into a two-dimensional matrix image composed of black and white modules. Simultaneously, multiple anti-counterfeiting mechanisms are introduced during the generation process, including embedding an invisible watermark in the error correction code area of the QR code, adding microtext patterns to the module edges, or using color layering technology to display hidden marks under specific light sources. These anti-counterfeiting features do not interfere with normal scanning functions but can be identified by dedicated equipment to prevent copying and counterfeiting. The final output is an anti-counterfeiting QR code with visual readability and security protection capabilities. The anti-counterfeiting QR code is then combined with basic product information to obtain a composite identifier image. IoT technology is used to add a fast retrieval identifier to the composite identifier image to obtain the product identity identifier. The basic product information includes... The system overlays static content such as product name, specifications, manufacturer logo, and instructions for use around the anti-counterfeiting QR code in a graphic layout to form a complete product label image, i.e., a composite identifier. Then, through the IoT identifier resolution system, a unique and resolvable quick-retrieval identifier is bound to the data layer of this composite identifier image. This identifier is an Electronic Product Code (EPC) conforming to the EPCglobal standard or a GTIN-14 code under the GS1 system. It is stored in the IoT name resolution server and establishes a mapping relationship with the product files in the backend database. When a terminal device scans the QR code, it can directly read the quick-retrieval identifier and initiate a distributed query, quickly locating the on-chain evidence record and the full-chain quality report without parsing all the content.For example, in the application scenario of cold chain transportation of pharmaceuticals, the quality certification certificate of a vaccine, after field extraction and formatting, generates a standard information string, which is encoded into an anti-counterfeiting QR code containing batch number, temperature control conclusion, and on-chain address. This QR code is then combined with information such as the "target product" name, manufacturer, and expiration date to form a label image, and the corresponding EPC code of the vaccine vial is embedded as a quick retrieval identifier. Finally, it is printed on the packaging surface to form a product identification mark, achieving efficient, safe, and traceable digital management.
[0042] In a specific embodiment, the step of performing graphic conversion on the standard information string based on preset encoding conversion rules to generate a QR code includes: Repeated fields are removed from the standard information string to obtain a simplified information string. The simplified information string is then compressed to obtain a compressed information string. Based on a preset information importance level, the compressed information string is classified into hierarchical information groups. These hierarchical information groups are then encoded using encoding rules with different densities to obtain hierarchical encoding dot matrices. Based on a preset encoding conversion rule, the hierarchical encoding dot matrices are arranged according to the QR code format specification to obtain a QR code.
[0043] Specifically, duplicate fields are removed from the standard information string to obtain a simplified information string. This simplified information string is then compressed to obtain a compressed information string. This process first compares each field of the standard information string extracted and formatted from the quality certification document, identifying identical content that appears repeatedly in multiple stages. For example, if a product batch number is recorded in multiple stages such as production, warehousing, and transportation, or if the name of the responsible entity appears multiple times in different data segments, the system automatically identifies and retains the first occurrence of the field using a string matching algorithm, deleting the remaining duplicates to form a simplified information string without redundant information. Subsequently, character compression is performed on this simplified information string, using the LZ77 compression algorithm combined with Huffman coding to perform lossless compression of the character sequence. Common fields such as "temperature compliance," "normal," and "cold chain logistics" are mapped to preset short codes. Redundant separators and spaces between fields are removed to further reduce data volume, generating a compact and efficient compressed information string, ensuring that more key information can be carried within the limited capacity of the QR code. Based on a preset information importance level, the compressed information string is classified into tiered information groups, and these groups are encoded using different density encoding rules to obtain a tiered encoding matrix. Specifically, according to drug regulatory standards, field priorities are set, with product batch number, temperature compliance status, and transportation start and end times listed as high priority, carrier name and packaging specifications as medium priority, and other auxiliary information as low priority. The system thus divides the compressed information string into high, medium, and low-level tiered information groups based on importance. Different encoding parameters are configured for different levels of information groups, with high-priority fields assigned higher error correction levels (e.g., QR codes). The code uses an H-level error correction scheme (which can recover 30% of damaged data) and employs a denser module layout to enhance anti-interference capabilities. Medium-priority fields use M-level error correction (15%), while low-priority fields use L-level error correction (7%) to save space. Data at each level is encoded and converted to generate corresponding binary dot matrix blocks, which are then stitched together according to their hierarchical weights to form a hierarchical encoding dot matrix with varying densities. Based on preset encoding conversion rules, the hierarchical encoding dot matrix is arranged according to the QR code format specifications to obtain the QR code. This process strictly follows the layout structure defined by the ISO / IEC 18004 standard, filling the data area with the hierarchical encoding dot matrix while retaining fixed areas such as position detection graphics, alignment patterns, timing lines, and format information areas to ensure the overall graphic can be accurately recognized by general-purpose scanning devices. During the layout process, the module distribution is dynamically adjusted to avoid excessive concentration of high-density areas leading to scanning failures. The final output is a QR code image with a complete structure, hierarchical information, and strong anti-damage capabilities.For example, in the application scenario of cold chain transportation of pharmaceuticals, the standard information string generated after processing the quality certification certificate of a certain vaccine includes "Batch Number: VAC20250401", "Temperature Range: 2℃~8℃", "Compliance Status: Y", "Carrier: ColdChain Logistics Co.", etc. The system removes duplicate carrier names, compresses the data, and prioritizes it according to importance. The batch number and compliance status are given high priority and encoded with high density, while the transportation time is given medium priority and encoded appropriately. Finally, it is integrated into a standardized QR code graphic output.
[0044] The product quality authentication and digital identity identification method in the embodiments of the present invention has been described above. The product quality authentication and digital identity identification device in the embodiments of the present invention will be described below. Please refer to [link / reference]. Figure 2 One embodiment of the product quality certification and digital identity identification device of the present invention includes: The monitoring module 21 is used to monitor the transportation process of the target product, obtain transportation link data, and timestamp the transportation link data to obtain time-series quality data. The verification module 22 is used to verify the authenticity of the time-series quality data based on a preset authentication mechanism, and obtain the data verification result. The verification module 23 is used to perform hash calculation and digital signature on the data verification result through preset blockchain technology to obtain an immutable record, and to perform consensus verification based on the immutable record to obtain a quality certification certificate. Add module 24 to perform graphic conversion on the quality certification certificate based on encoding conversion rules to obtain a QR code, and use Internet of Things technology to add a quick search identifier to the QR code to obtain the product identity identifier; Analysis module 25 is used to perform quality traceability analysis on the target product based on the AI technology and the product identity identifier, and obtain a product full-chain quality report.
[0045] In this embodiment, the specific implementation of each unit in the above device embodiment is described in the above method embodiment, and will not be repeated here.
[0046] like Figure 3 As shown in the diagram, this embodiment of the invention provides a structural schematic block diagram of a computer device, including: At least one processor; At least one memory for storing at least one program; When the at least one program is executed by the at least one processor, the at least one processor implements the above-described product quality certification and digital identity identification method.
[0047] It is evident that the content of the above method embodiments is applicable to this device embodiment. The specific functions implemented in this device embodiment are the same as those in the above method embodiments, and the beneficial effects achieved are also the same as those achieved in the above method embodiments.
[0048] Furthermore, this application also discloses a computer program product or computer program stored in a computer-readable storage medium. A processor of a computer device can read the computer program from the computer-readable storage medium and execute the computer program, causing the computer device to perform the aforementioned product quality authentication and digital identity verification method. Similarly, the content of the above method embodiments is applicable to this storage medium embodiment. The specific functions implemented in this storage medium embodiment are the same as those in the above method embodiments, and the beneficial effects achieved are also the same as those achieved in the above method embodiments.
[0049] The above is a detailed description of the preferred embodiments of the present invention. However, the present invention is not limited to the embodiments described. Those skilled in the art can make various equivalent modifications or substitutions without departing from the spirit of the present invention. All such equivalent modifications or substitutions are included within the scope defined by the claims of this application.
Claims
1. A product quality certification and digital identity identification method, characterized in that, The method comprises the following steps: monitoring the transportation process of the target product to obtain transportation link data, and time stamping the transportation link data to obtain time sequence quality data; verifying the authenticity of the time sequence quality data based on a preset authentication mechanism to obtain a data verification result; performing hash operation and digital signature on the data verification result through a preset blockchain technology to obtain an unalterable record, and performing consensus verification based on the unalterable record to obtain a quality certification voucher; performing graphic conversion on the quality certification voucher based on a coding conversion rule to obtain a two-dimensional code, and adding a quick search identifier to the two-dimensional code by using Internet of Things technology to obtain a product identity; based on the AI technology, performing quality traceability analysis on the target product based on the product identity to obtain a product whole-chain quality report.
2. The product quality certification and digital identity identification method according to claim 1, characterized in that, The monitoring the transportation process of the target product to obtain transportation link data, and time stamping the transportation link data to obtain time sequence quality data comprises: collecting parameters of the transportation process of the target product and associated production links through a sensor to obtain comprehensive raw data covering transportation environment parameters and production raw parameters, identifying and removing outliers of the comprehensive raw data to obtain transportation link data; embedding time stamps in the transportation link data based on a high-precision system clock to obtain time-stamped transportation data, and associating and sorting the time-stamped transportation data according to transportation process nodes and corresponding time sequence to form time sequence quality data.
3. The product quality certification and digital identity identification method according to claim 1, characterized in that, The verifying the authenticity of the time sequence quality data based on a preset authentication mechanism to obtain a data verification result comprises: performing data integrity detection on the time sequence quality data to obtain a data integrity index, and performing data completion based on the data integrity index to obtain complete quality data; performing source consistency comparison on the complete quality data through a data source verification rule to obtain a data source verification record, and performing credibility evaluation on the data source verification record to obtain source credibility; using a preset authentication mechanism, performing true-false judgment on the complete quality data based on the source credibility to obtain a data verification result.
4. The product quality certification and digital identity identification method according to claim 1, characterized in that, The performing hash operation and digital signature on the data verification result through a preset blockchain technology to obtain an unalterable record comprises: performing hash operation on the data verification result through a preset blockchain technology to obtain a preliminary hash value of fixed length; calling a private key of a responsible subject to perform digital signature on the preliminary hash value to obtain signature ciphertext, and appending the signature ciphertext to the end of hash associated data to obtain a signature data file; obtaining a public key of the responsible subject, performing digital signature verification on the signature ciphertext in the signature data file to obtain a signature verification result, and integrating the signature verification result and the signature data file to obtain an unalterable record. 5.The product quality certification and digital identity identification method according to claim 1, characterized in that, The performing consensus verification based on the unalterable record to obtain a quality certification voucher comprises: embedding an authority institution identifier in the unalterable record to obtain institution marked data, and performing multi-node broadcast on the institution marked data to obtain a block to be verified. The Byzantine fault-tolerant mechanism is used for node voting of the to-be-verified block to obtain a consensus confirmation result, and the to-be-verified block is written into a main chain based on the consensus confirmation result to obtain an on-chain record; The chain record is formatted and encapsulated by the smart contract to obtain a standard authentication file, and the standard authentication file is digitally stamped with an authoritative seal to obtain a quality certification voucher.
6. The product quality certification and digital identity identification method according to claim 1, characterized in that, The quality certification voucher is subjected to a graphical conversion based on a preset encoding conversion rule to obtain a two-dimensional code, and a product identity is obtained by adding a quick search identifier to the two-dimensional code using Internet of Things technology, including: The core search information is obtained by extracting the search field of the quality certification voucher, and the core search information is formatted to obtain a standard information string; the standard information string is subjected to a graphical conversion based on a preset encoding conversion rule to generate a two-dimensional code, and a two-dimensional code is embedded with an anti-counterfeiting feature to obtain an anti-counterfeiting two-dimensional code; the anti-counterfeiting two-dimensional code and the product basic information are subjected to a graphic-text synthesis to obtain a synthesis identification map, and a quick search identifier is added to the synthesis identification map using Internet of Things technology to obtain a product identity.
7. The product quality certification and digital identity identification method according to claim 6, characterized in that, The quality certification voucher is subjected to a graphical conversion based on a preset encoding conversion rule to obtain a two-dimensional code, including: The standard information string is subjected to a graphical conversion based on a preset encoding conversion rule to generate a two-dimensional code, including:
8. A product quality certification and digital identity marking device, characterized by, A monitoring module is configured to monitor the transportation process of a target product to obtain transportation link data, and the transportation link data is time-stamped to obtain time-series quality data; A verification module is configured to verify the authenticity of the time-series quality data based on a preset authentication mechanism to obtain a data verification result; A verification module is configured to verify the authenticity of the time-series quality data based on a preset authentication mechanism to obtain a data verification result; An adding module is configured to convert the quality certification voucher into a two-dimensional code based on an encoding conversion rule, and add a quick search identifier to the two-dimensional code using Internet of Things technology to obtain a product identity; An analysis module is configured to perform quality traceability analysis on the target product based on the product identity based on the AI technology to obtain a product full-chain quality report. The processor executes the computer program to realize the steps of the method of any one of claims 1 to 7. 9.A computer device, comprising a memory and a processor, wherein the memory stores a computer program, and the computer device is configured to perform the method according to any one of claims 1-8. The computer program is executed by the processor to realize the steps of the method of any one of claims 1 to 7.
10. A computer-readable storage medium having stored thereon a computer program, characterized in that,