init2 xors IV with input parameter block */
| 56 | |
| 57 | /* init2 xors IV with input parameter block */ |
| 58 | void blake2s_init_param( blake2s_state *S, uint32 node_offset, uint32 node_depth) |
| 59 | { |
| 60 | #ifdef USE_SSE |
| 61 | if (_SSE_Version>=SSE_SSE2) |
| 62 | blake2s_init_sse(); |
| 63 | #endif |
| 64 | |
| 65 | S->init(); // Clean data. |
| 66 | for( int i = 0; i < 8; ++i ) |
| 67 | S->h[i] = blake2s_IV[i]; |
| 68 | |
| 69 | S->h[0] ^= 0x02080020; // We use BLAKE2sp parameters block. |
| 70 | S->h[2] ^= node_offset; |
| 71 | S->h[3] ^= (node_depth<<16)|0x20000000; |
| 72 | } |
| 73 | |
| 74 | |
| 75 | #define G(r,i,m,a,b,c,d) \ |
no test coverage detected