Method and device for modular exponentiation
An operation method and modular exponentiation technology, applied in the field of modular exponentiation, can solve the problem of high power consumption of modular exponentiation devices, and achieve the effects of preventing power consumption analysis, reducing power consumption, and reducing the number of times.
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0036] This embodiment provides a modular exponentiation method, referring to figure 1 , which will be described in detail below through specific steps.
[0037] In step S101, the controller selects a data stream to be processed, and stores the data stream into a first memory.
[0038] In a specific implementation, the data stream to be processed may be a binary bit stream, and the first memory may be a register for storing the data stream to be processed, or may be other types of memory.
[0039] Step S102, the modular exponentiation operator sequentially acquires the data bits in the first memory, and when the value of the data bits is 1, performs the first operation, and stores the result of the first operation in the second memory; when the data When the value of the bit is 0, the second operation is performed, and the result of the second operation is stored in the second memory.
[0040] In a specific implementation, the first operation may include the following operat...
Embodiment 2
[0046] This embodiment provides a modular exponentiation method, referring to figure 2 , which will be described in detail below through specific steps.
[0047] Step S201, the controller selects a data stream to be processed, and stores the data stream into a first memory.
[0048] In a specific implementation, the first memory may store data streams that need to be processed. The length of the data stream is N, and the length of a data stream may be 32 data bits or an integer multiple of 32.
[0049] Step S202, initializing the preset counter in the modular exponentiation operator.
[0050] The modular exponentiation operator can sequentially read the data bits in the first memory. In a specific implementation, a counter can be set in the modular exponentiation unit, and the number of data bits currently read by the modular exponentiation unit can be judged by the value of the counter. The length of the counter is the same as the length of the data stream to be processe...
Embodiment 3
[0066] This embodiment provides a modular exponentiation method, referring to image 3 , which will be described in detail below through specific steps.
[0067] Step S301, the controller selects a data stream to be processed, and stores the data stream into a first memory.
[0068] Step S302, initializing the counter preset in the modular exponentiation operator.
[0069] The modular exponentiation operator can sequentially read the data bits in the first memory. In a specific implementation, a counter can be set in the modular exponentiation unit, and the number of data bits currently read by the modular exponentiation unit can be judged by the value of the counter. The length of the counter is the same as the length of the data stream to be processed, and the value of the counter is initialized to 1.
[0070] Step S303, the modular exponentiation operator reads the data bits in the first memory.
[0071] Step S304, judging whether the value of the first data bit is 1, i...
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 


