mirror of
https://github.com/clearml/dropbear
synced 2025-01-31 10:57:01 +00:00
Fix ecdsa verification
--HG-- branch : ecc
This commit is contained in:
parent
95a21c8fd7
commit
916cfa6b83
8
ecdsa.c
8
ecdsa.c
@ -248,14 +248,6 @@ static int buf_get_ecdsa_verify_params(buffer *buf, struct dropbear_ecc_curve *c
|
|||||||
unsigned int sig_pos;
|
unsigned int sig_pos;
|
||||||
unsigned char key_ident[30];
|
unsigned char key_ident[30];
|
||||||
|
|
||||||
ident = buf_getstring(buf, &ident_len);
|
|
||||||
snprintf((char*)key_ident, sizeof(key_ident), "ecdsa-sha2-%s", curve->name);
|
|
||||||
if (strlen((char*)key_ident) != ident_len) {
|
|
||||||
goto out;
|
|
||||||
}
|
|
||||||
if (memcmp(key_ident, ident, ident_len) != 0) {
|
|
||||||
goto out;
|
|
||||||
}
|
|
||||||
sig_len = buf_getint(buf);
|
sig_len = buf_getint(buf);
|
||||||
sig_pos = buf->pos;
|
sig_pos = buf->pos;
|
||||||
if (buf_getmpint(buf, r) != DROPBEAR_SUCCESS) {
|
if (buf_getmpint(buf, r) != DROPBEAR_SUCCESS) {
|
||||||
|
Loading…
Reference in New Issue
Block a user