Error when output allocation length is not equal to the signature length. 'Compute_signature' now returns the answer's length
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@3195 c6295689-39f2-0310-b995-f0e70906c6a9
This commit is contained in:
parent
8c222a0b44
commit
16c5ab4d5b
|
@ -1174,9 +1174,9 @@ auth_compute_signature(sc_card_t *card,
|
||||||
SC_FUNC_RETURN(card->ctx, 1, SC_ERROR_CARD_CMD_FAILED);
|
SC_FUNC_RETURN(card->ctx, 1, SC_ERROR_CARD_CMD_FAILED);
|
||||||
}
|
}
|
||||||
|
|
||||||
memcpy(out, apdu.resp, olen);
|
memcpy(out, apdu.resp, apdu.resplen);
|
||||||
|
|
||||||
SC_FUNC_RETURN(card->ctx, 1, olen);
|
SC_FUNC_RETURN(card->ctx, 1, apdu.resplen);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue