Batch digital signature verification processing apparatus and method
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- BEIJING MICROCHIP EDGE COMPUTING RES INST
- Filing Date
- 2026-02-06
- Publication Date
- 2026-06-26
AI Technical Summary
In existing technologies, digital signature verification is inefficient and consumes a lot of CPU resources, which cannot meet the performance requirements of blockchain services.
A batch digital signature verification processing device implemented entirely in hardware includes a processor module, a communication module, a message queue module, a data transfer module, and a hardware configuration module. By combining multiple hash engines and signature verification engines and through the reasonable coordination of the modules, batch digital signature verification can be achieved.
This improves the efficiency of digital signature verification, reduces server CPU utilization, allows the server more time to process other tasks, and improves overall performance.
Smart Images

Figure CN122293330A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular to a batch digital signature verification processing device and method. Background Technology
[0002] As a novel technology, blockchain is increasingly being applied to our daily lives, but its performance significantly limits its application scenarios. Digital signature verification, as a crucial step in blockchain transactions, plays a vital role in security.
[0003] In current applications, digital signature verification is implemented using software methods or a combination of software and hardware encryption machines. However, these two methods are inefficient and increasingly fail to meet the performance requirements of blockchain applications. Furthermore, pure software processing consumes significant amounts of CPU resources on the host computer. While the software-plus-hardware encryption machine approach includes a hardware algorithm engine, the hash algorithm module and the digital signature verification engine within the hardware algorithm engine are coupled in software, which also impacts processing efficiency and consumes CPU resources. Summary of the Invention
[0004] This application provides a batch digital signature verification processing apparatus and method to improve the efficiency of digital signature verification. The technical solution of this application is as follows: According to a first aspect of the embodiments of this application, a batch digital signature verification processing device is provided, including a processor module and a communication module, a message queue module, a data transfer module and a hardware configuration module electrically connected thereto, wherein the hardware configuration module is electrically connected to a hash algorithm module and a signature verification algorithm module. The communication module is used to interact with the outside world, store the message data received from the outside world into the message queue module, and interact with the processor module to exchange relevant information of the message data. The processor module is used to configure the hardware configuration module and control the data transfer module to work based on the relevant information of the message data. The hardware configuration module is used to store relevant parameters of the hash algorithm module and the signature verification algorithm module, and to configure the working status of the hash algorithm module and the signature verification algorithm module according to the control instructions of the processor module. The data transfer module is used to interact with the message queue module, the hash algorithm module, and the signature verification algorithm module. The message queue module is used to buffer the data of the communication module and the data transfer module.
[0005] In some embodiments of this application, the hash algorithm module includes multiple hash engines, and the signature verification algorithm module includes multiple signature verification engines; The hardware configuration module is also used to determine the number of hash engines and signature verification engines to be started.
[0006] In some embodiments of this application, the hash algorithm module includes a hash engine selector, multiple hash engines, and a hash result output selector. The hash engine selector is used to determine the first target hash engine for processing the current task based on the working status of the plurality of hash engines. The hash engine is used to calculate the hash value of the original text corresponding to the message data; The hash result output selector is used to determine the second target hash engine to which the output hash result is sent from the signature verification algorithm module.
[0007] In some embodiments of this application, the signature verification algorithm module includes a signature verification engine selector, multiple signature verification engines, and a signature verification result output selector. The signature verification engine selector is used to determine the first target signature verification engine for processing the current task based on the working status of the plurality of signature verification engines. The signature verification engine is used to verify whether the digital signature of the hash result output by the hash algorithm module is correct; The signature verification result output selector is used to determine the second target signature verification engine to output the signature verification result to the data transfer module.
[0008] In some embodiments of this application, a verification success data output channel and a verification failure data output channel are provided between the signature verification algorithm module and the data transfer module. The signature verification result output selector is also used to select either the successful verification data output channel or the failed verification data output channel to output the signature verification result according to the type of the signature verification result.
[0009] In some embodiments of this application, the processor module is further configured to: Based on the relevant information of the message data, identify the message type of the message data; and configure the hardware configuration module and control the data transfer module to work according to the message type.
[0010] In some embodiments of this application, the processor module is further configured to: Once it is detected that all the message data has been processed, a processing completion notification is sent to the outside via the communication module.
[0011] In some embodiments of this application, the data transfer module is a direct memory access (DMA) module.
[0012] According to a second aspect of the embodiments of this application, a batch digital signature verification processing method is provided. The method is used in a batch digital signature verification processing apparatus, which includes a processor module and electrically connected to it a communication module, a message queue module, a data transfer module, and a hardware configuration module. The hardware configuration module is electrically connected to a hash algorithm module and a signature verification algorithm module. The method includes: The communication module receives message data sent from the outside, stores the message data in the message queue module, and sends relevant information about the message data to the processor module; The processor module parses the message type of the message data according to the relevant information of the message data. When the message type is a signature verification message, the hardware configuration module is configured to make the hash algorithm module and the signature verification algorithm module ready to work; and the data transfer module is started to transfer the data from the message queue module to the hash algorithm module. When the hash algorithm module detects data input, it starts processing the input data and outputs the processing result to the signature verification algorithm module. The signature verification algorithm module processes the output of the hash algorithm module and returns the processing result to the message queue module through the data transfer module; Once the processor module detects that all message data has been processed, it sends a processing completion notification to the outside via the communication module.
[0013] In some embodiments of this application, the hash algorithm module includes multiple hash engines, and the signature verification algorithm module includes multiple signature verification engines; the method further includes: The processor module determines the number of hash engines and signature verification engines to be started through the hardware configuration module.
[0014] The technical solution provided in this application has at least the following beneficial effects: By implementing batch digital signature verification using pure hardware, the efficiency of batch digital signature verification is effectively improved through the reasonable coordination of various hardware modules. Furthermore, the pure hardware implementation can reduce the utilization of the server CPU, allowing the server CPU to have more time to handle other tasks.
[0015] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and do not limit this application. Attached Figure Description
[0016] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application, and do not constitute an undue limitation of this application.
[0017] Figure 1 This is a structural block diagram of a batch digital signature verification processing device according to an embodiment.
[0018] Figure 2 This is a structural block diagram of a batch digital signature verification processing device according to another embodiment.
[0019] Figure 3 This is a flowchart illustrating a batch digital signature verification process according to an embodiment. Detailed Implementation
[0020] To enable those skilled in the art to better understand the technical solutions of this application, the technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings.
[0021] Figure 1 This is a structural block diagram of a batch digital signature verification processing apparatus according to an embodiment of this application. Figure 1 As shown, the batch digital signature verification processing device may include a processor module and a communication module, a message queue module, a data transfer module and a hardware configuration module electrically connected thereto. The hardware configuration module is electrically connected to the hash algorithm module and the signature verification algorithm module.
[0022] The main function of this communication module is to send and receive data. It receives external data and sends data processed by internal modules to external devices. It interacts with external devices, such as a host computer, receiving message data and storing it in a message queue module for buffering. It also sends events related to received message data from external devices, along with relevant information, to the processor module.
[0023] In other words, after receiving external message data, the communication module caches the message data on the one hand, and notifies the processor module to process the message data accordingly on the other hand.
[0024] The processor module is responsible for interacting with other modules of the device, configuring the hardware configuration module based on relevant information from message data obtained from the communication module, and controlling the operation of the data transfer module.
[0025] After receiving notification from the communication module, the processor module needs to configure the hardware configuration module to put the hash algorithm module and the signature verification algorithm module into a working ready state, and start the data transfer module to move data from the message queue module to the hash algorithm module, so that the hash algorithm module and the signature verification algorithm module can start processing the hashing of message data and verifying digital signatures.
[0026] In other words, the main function of the processor module is to control the data transfer module, hardware configuration module, hash algorithm module and signature verification algorithm module to process the message data according to the notification from the communication module, and to notify the external device of the processing result.
[0027] This hardware configuration module is also used to store relevant parameters for the hash algorithm module and the signature verification algorithm module, such as the hash algorithm type, digital signature algorithm type, and other configuration information for the hash algorithm module and the signature verification algorithm module. This hardware configuration module can be a register; the processor module sets the register values to complete the configuration of the hash algorithm module and the signature verification algorithm module.
[0028] This data transfer module is used to interact with the message queue module, hash algorithm module, and signature verification algorithm module. For example, the data transfer module is used to move unprocessed message data from the message queue module to the hash algorithm module, and to move processed data from the signature verification algorithm module back to the message queue module.
[0029] In other words, the data migration module is mainly used to migrate external data and data processed by internal modules.
[0030] Optionally, the data transfer module can be DMA (Direct Memory Access), which offers high efficiency for data transfer.
[0031] The message queue module is primarily used to buffer external data and data processed by internal modules to prevent data loss. For example, it can be used to buffer data from communication modules and data transfer modules.
[0032] The hash algorithm module is used to calculate the hash value of the original message, and the signature verification algorithm module is used to verify whether the digital signature is correct.
[0033] It should be noted that the digital signature verification process includes calculating the hash value of the original message, that is, applying the same hash algorithm to the original message file to obtain a new digital digest, and then verifying whether the digital signature is correct, that is, verifying whether the new digital digest obtained is consistent with the digital digest obtained by decrypting the digital signature using the public key. If they are consistent, the verification is successful; if they are inconsistent, the verification fails. Finally, the verification result of success or failure is returned to the host computer.
[0034] The batch digital signature verification processing device of this application embodiment adopts pure hardware to implement batch digital signature verification. Through the reasonable cooperation of various modules of pure hardware, the efficiency of batch digital signature verification is effectively improved. Moreover, the pure hardware implementation scheme can reduce the utilization of server CPU, allowing the server CPU to have more time to process other tasks.
[0035] Based on the above embodiments, in order to further improve the performance of the device, Figure 2 This is a structural block diagram of a batch digital signature verification processing apparatus according to another embodiment of this application. Figure 2 As shown, the hash algorithm module includes multiple hash engines, and the signature verification algorithm module includes multiple signature verification engines. The number of hash engines and signature verification engines to be activated can be determined through the hardware configuration module. For example, the hash algorithm module includes 4 hash engines, and the signature verification algorithm module includes 5 signature verification engines. Depending on the message processing requirements, 2 hash engines and 2 signature verification engines can be selected; that is, different numbers of hash engines and signature verification engines can be selected to process signature verification messages based on different verification needs.
[0036] In some possible embodiments, the hash algorithm module includes a hash engine selector (MUX1), multiple hash engines, and a hash result output selector (MUX2). The hash engine selector is used to determine the first target hash engine for processing the current task based on the working status of the multiple hash engines. The hash engine is used to calculate the hash value of the original text corresponding to the message data. The hash result output selector is used to determine the second target hash engine to output the hash result to the signature verification algorithm module.
[0037] This can be understood as follows: the hash engine selector determines which hash engine to use for processing the current task based on information such as the busy / idle status of multiple hash engines. After the determined target hash engine obtains the hash value of the original message, the hash result output selector determines which hash engine's hash result to output to the signature verification algorithm module.
[0038] In some possible embodiments, the signature verification algorithm module includes a signature verification engine selector (MUX3), multiple signature verification engines, and a signature verification result output selector (MUX4). The signature verification engine selector is used to determine the first target signature verification engine for processing the current task based on the working status of the multiple signature verification engines. The signature verification engine is used to verify whether the digital signature of the hash result output by the hash algorithm module is correct. The signature verification result output selector is used to determine the second target signature verification engine to output the signature verification result to the data transfer module.
[0039] This can be understood as follows: the signature verification engine selector determines which signature verification engine to use for processing the current task based on information such as the busy / idle status of multiple signature verification engines. After the determined target signature verification engine obtains its verification result, the signature verification result output selector determines which signature verification engine's result to output.
[0040] In some possible embodiments, a successful verification data output channel and a failed verification data output channel are provided between the signature verification algorithm module and the data transfer module. The successful verification data output channel is used to output the signature verification result if successful, and the failed verification data output channel is used to output the signature verification result if failed. That is, the signature verification result output selector is also used to select either the successful verification data output channel or the failed verification data output channel to output the signature verification result based on the type of signature verification result.
[0041] In some possible embodiments, the processor module is also configured to identify the message type of the message data based on relevant information of the message data; and configure the hardware configuration module and control the data transfer module to operate according to the message type. When the processor module parses the message type as a signature verification message based on the relevant information of the received message data, it configures the hardware configuration module to control the operating status of the hash algorithm module and the signature verification algorithm module.
[0042] In some possible embodiments, the processor module is also configured to send a processing completion notification to the outside via the communication module after detecting that all message data has been processed.
[0043] This can be understood as follows: once the processor module detects that all the data in the received message has been processed, it sends a data processing completion signal to the host computer through the communication module, waits for the host computer to retrieve the processing result of the completed data, and then processes the next message.
[0044] The batch digital signature verification processing device of this application embodiment adopts pure hardware to implement batch digital signature verification. Through the reasonable cooperation of various modules of pure hardware, the efficiency of batch digital signature verification is effectively improved. Moreover, the pure hardware implementation can reduce the utilization of server CPU, allowing the server CPU to have more time to process other tasks. The hash algorithm module and the signature verification algorithm module each include multiple algorithm engines. This device can dynamically adjust the number of various algorithm engines for digital signature verification to optimize the device's performance and further improve the efficiency of digital signature verification.
[0045] Figure 3 This is a flowchart of a batch digital signature verification processing method according to an embodiment of this application, the method being used for Figure 2The batch digital signature verification processing device shown includes a processor module and, electrically connected to it, a communication module, a message queue module, a data transfer module, and a hardware configuration module. The hardware configuration module is electrically connected to a hash algorithm module and a signature verification algorithm module. Figure 3 As shown, the method includes: In step S301, the communication module receives message data sent from the outside, stores the message data in the message queue module, and sends relevant information about the message data to the processor module.
[0046] As an example, when the communication module receives a message from the host computer, it notifies the processor module and simultaneously stores the message in the message queue module.
[0047] In step S302, the processor module parses the message type of the message data according to the relevant information of the message data. When the message type is a signature verification message, the hardware configuration module is configured to make the hash algorithm module and the signature verification algorithm module ready to work; and the data transfer module is started to transfer the data from the message queue module to the hash algorithm module.
[0048] This can be understood as follows: when the processor module parses the message type as a signature verification message, it configures the hardware configuration module to put the hash algorithm module and the signature verification algorithm module into a ready state, and starts the data transfer module to send the message data from the message queue module to the hash algorithm module.
[0049] In step S303, when the hash algorithm module detects data input, it starts processing the input data and outputs the processing result to the signature verification algorithm module.
[0050] As one possible implementation, the hash algorithm module includes a hash engine selector, multiple hash engines, and a hash result output selector. The hash engine selector determines which hash engine to use for processing the current task based on information such as the busy / idle status of each hash engine. After the determined target hash engine obtains the hash value of the original message, the hash result output selector determines which hash engine's hash result to output to the signature verification algorithm module.
[0051] In step S304, the signature verification algorithm module processes the output of the hash algorithm module and returns the processing result to the message queue module through the data transfer module.
[0052] As one possible implementation, the signature verification algorithm module includes a signature verification engine selector, multiple signature verification engines, and a signature verification result output selector. The signature verification algorithm module and the data transfer module are connected by a successful verification data output channel and a failed verification data output channel. The signature verification engine selector determines which signature verification engine to use for the current task based on information such as the busy / idle status of each of the multiple signature verification engines. After the determined target signature verification engine obtains its verification result, the signature verification result output selector determines which signature verification engine's result to output, and selects either the successful verification data output channel or the failed verification data output channel to output the signature verification result based on the type of the verification result.
[0053] In step S305, after detecting that all message data has been processed, the processor module sends a processing completion notification to the outside via the communication module.
[0054] In other words, once the processor module detects that all data for the current message has been processed, it sends a data processing completion signal to the host computer via the communication module, waits for the host computer to retrieve the data processing result, and then processes the next message.
[0055] The batch digital signature verification processing method of this application embodiment adopts pure hardware to implement batch digital signature verification. Through the reasonable cooperation of various modules of pure hardware, the efficiency of batch digital signature verification is effectively improved. Moreover, the pure hardware implementation can reduce the utilization of server CPU, allowing the server CPU to have more time to handle other tasks. The hash algorithm module and the signature verification algorithm module each include multiple algorithm engines. This device can dynamically adjust the number of various algorithm engines for digital signature verification to optimize the device's performance and further improve the efficiency of digital signature verification.
[0056] It should also be noted that the exemplary embodiments mentioned in this invention describe methods or systems based on a series of steps or apparatus. However, this invention is not limited to the order of the steps described above; that is, the steps can be performed in the order mentioned in the embodiments, or in a different order, or several steps can be performed simultaneously.
[0057] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of this application. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of different embodiments or examples.
[0058] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of that feature. In the description of this application, "multiple" means at least two, such as two, three, etc., unless otherwise explicitly specified.
[0059] Other embodiments of this application will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this application that follow the general principles of this application and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only.
[0060] It should be understood that this application is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this application is limited only by the appended claims.
Claims
1. A batch digital signature verification processing device, characterized in that, It includes a processor module and a communication module, a message queue module, a data transfer module and a hardware configuration module electrically connected thereto. The hardware configuration module is electrically connected to a hash algorithm module and a signature verification algorithm module. The communication module is used to interact with the outside world, store the message data received from the outside world into the message queue module, and interact with the processor module to exchange relevant information of the message data. The processor module is used to configure the hardware configuration module and control the data transfer module to work based on the relevant information of the message data. The hardware configuration module is used to store relevant parameters of the hash algorithm module and the signature verification algorithm module, and to configure the working status of the hash algorithm module and the signature verification algorithm module according to the control instructions of the processor module. The data transfer module is used to interact with the message queue module, the hash algorithm module, and the signature verification algorithm module. The message queue module is used to buffer the data of the communication module and the data transfer module.
2. The apparatus according to claim 1, characterized in that, The hash algorithm module includes multiple hash engines, and the signature verification algorithm module includes multiple signature verification engines. The hardware configuration module is also used to determine the number of hash engines and signature verification engines to be started.
3. The apparatus according to claim 2, characterized in that, The hash algorithm module includes a hash engine selector, multiple hash engines, and a hash result output selector. The hash engine selector is used to determine the first target hash engine for processing the current task based on the working status of the plurality of hash engines. The hash engine is used to calculate the hash value of the original text corresponding to the message data; The hash result output selector is used to determine the second target hash engine to which the output hash result is sent from the signature verification algorithm module.
4. The apparatus according to claim 2, characterized in that, The signature verification algorithm module includes a signature verification engine selector, multiple signature verification engines, and a signature verification result output selector. The signature verification engine selector is used to determine the first target signature verification engine for processing the current task based on the working status of the plurality of signature verification engines. The signature verification engine is used to verify whether the digital signature of the hash result output by the hash algorithm module is correct; The signature verification result output selector is used to determine the second target signature verification engine to output the signature verification result to the data transfer module.
5. The apparatus according to claim 4, characterized in that, The signature verification algorithm module and the data transfer module are provided with a successful verification data output channel and a failed verification data output channel. The signature verification result output selector is also used to select either the successful verification data output channel or the failed verification data output channel to output the signature verification result according to the type of the signature verification result.
6. The apparatus according to claim 1, characterized in that, The processor module is also used for: Based on the relevant information of the message data, identify the message type of the message data; and configure the hardware configuration module and control the data transfer module to work according to the message type.
7. The apparatus according to claim 1, characterized in that, The processor module is also used for: Once it is detected that all the message data has been processed, a processing completion notification is sent to the outside via the communication module.
8. The apparatus according to claim 1, characterized in that, The data transfer module is a direct memory access (DMA) module.
9. A batch digital signature verification processing method, characterized in that, The method is used in a batch digital signature verification processing device, which includes a processor module and electrically connected to it a communication module, a message queue module, a data transfer module, and a hardware configuration module. The hardware configuration module is electrically connected to a hash algorithm module and a signature verification algorithm module. The method includes: The communication module receives message data sent from the outside, stores the message data in the message queue module, and sends relevant information about the message data to the processor module; The processor module parses the message type of the message data according to the relevant information of the message data. When the message type is a signature verification message, the hardware configuration module is configured to make the hash algorithm module and the signature verification algorithm module ready to work; and the data transfer module is started to transfer the data from the message queue module to the hash algorithm module. When the hash algorithm module detects data input, it starts processing the input data and outputs the processing result to the signature verification algorithm module. The signature verification algorithm module processes the output of the hash algorithm module and returns the processing result to the message queue module through the data transfer module; Once the processor module detects that all message data has been processed, it sends a processing completion notification to the outside via the communication module.
10. The method according to claim 9, characterized in that, The hash algorithm module includes multiple hash engines, the signature verification algorithm module includes multiple signature verification engines; the method further includes: The processor module determines the number of hash engines and signature verification engines to be started through the hardware configuration module.