Skip to content
Snippets Groups Projects
Commit dcbb1320 authored by Dmitriy A. Gerasimov's avatar Dmitriy A. Gerasimov
Browse files

...

parent cf38dd9b
No related branches found
No related tags found
No related merge requests found
Pipeline #7000 passed with stage
in 11 seconds
...@@ -222,7 +222,7 @@ dilithium_signature_t* dap_enc_dilithium_read_signature_old(uint8_t *a_buf, size ...@@ -222,7 +222,7 @@ dilithium_signature_t* dap_enc_dilithium_read_signature_old(uint8_t *a_buf, size
return NULL ; return NULL ;
dilithium_signature_t* l_sign = DAP_NEW(dilithium_signature_t); dilithium_signature_t* l_sign = DAP_NEW(dilithium_signature_t);
l_sign->kind = (dilithium_kind_t) kind; memcpy(&l_sign->kind+sizeof(uint32_t), &kind,sizeof (kind));
uint64_t l_shift_mem = sizeof(uint32_t) + sizeof(uint32_t); uint64_t l_shift_mem = sizeof(uint32_t) + sizeof(uint32_t);
memcpy(&l_sign->sig_len, a_buf + l_shift_mem, sizeof(unsigned long long)); memcpy(&l_sign->sig_len, a_buf + l_shift_mem, sizeof(unsigned long long));
if( l_sign->sig_len> (UINT64_MAX - l_shift_mem ) ){ if( l_sign->sig_len> (UINT64_MAX - l_shift_mem ) ){
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment