mirror of https://github.com/wolfSSL/wolfssh.git
Fix digest comparison in FindKeyId to use id->id field
WMEMCMP was comparing the computed SHA-256 digest against the WOLFSSH_AGENT_ID struct pointer instead of the id field within the struct, causing key lookups by digest to never match.pull/880/head
parent
0728d9cac0
commit
6547f04a77
|
|
@ -660,7 +660,7 @@ static WOLFSSH_AGENT_ID* FindKeyId(WOLFSSH_AGENT_ID* id,
|
|||
|
||||
if (ret == WS_SUCCESS) {
|
||||
while (id != NULL &&
|
||||
WMEMCMP(digest, id, WC_SHA256_DIGEST_SIZE) != 0 &&
|
||||
WMEMCMP(digest, id->id, WC_SHA256_DIGEST_SIZE) != 0 &&
|
||||
WMEMCMP(keyBlob, id->keyBlob, keyBlobSz)) {
|
||||
id = id->next;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue