iPXE
|
X25519 multiplication temporary working space. More...
Data Fields | |
struct { | |
uint8_t pad [sizeof(union x25519_multiply_step2) - offsetof(union x25519_multiply_step1, parts.high_260bit)] | |
Padding to avoid collision between steps 1 and 2. More... | |
union x25519_multiply_step1 step1 | |
Step 1 result. More... | |
}; | |
Step 1 result. More... | |
struct { | |
union x25519_multiply_step2 step2 | |
Step 2 result. More... | |
union x25519_multiply_step3 step3 | |
Step 3 result. More... | |
}; | |
Steps 2 and 3 results. More... | |
X25519 multiplication temporary working space.
We overlap the buffers used by each step of the multiplication calculation to reduce the total stack space required:
|-----------------------------------------------------—| | <- pad -> | <---------— step 1 result ----------—> | | | <- low 256 bits -> | <– high 260 bits --> | | <----— step 2 result ---—> | <– step 3 result --> | |-----------------------------------------------------—|
uint8_t x25519_multiply_workspace::pad[sizeof(union x25519_multiply_step2) - offsetof(union x25519_multiply_step1, parts.high_260bit)] |
union x25519_multiply_step1 x25519_multiply_workspace::step1 |
struct { ... } |
Step 1 result.
union x25519_multiply_step2 x25519_multiply_workspace::step2 |
union x25519_multiply_step3 x25519_multiply_workspace::step3 |
struct { ... } |
Steps 2 and 3 results.