mirror of
https://github.com/polhenarejos/pico-keys-sdk
synced 2026-05-28 17:11:23 +02:00
Only send response apdu if sw != 0.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
@@ -169,6 +169,7 @@ void apdu_finish() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
size_t apdu_next() {
|
size_t apdu_next() {
|
||||||
|
if (apdu.sw != 0) {
|
||||||
if (apdu.rlen <= apdu.ne)
|
if (apdu.rlen <= apdu.ne)
|
||||||
return apdu.rlen + 2;
|
return apdu.rlen + 2;
|
||||||
else {
|
else {
|
||||||
@@ -183,4 +184,5 @@ size_t apdu_next() {
|
|||||||
}
|
}
|
||||||
return apdu.ne + 2;
|
return apdu.ne + 2;
|
||||||
}
|
}
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user