Fix secure channel with no payload.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
parent
4a8a6728c7
commit
b2c2980d73
1 changed files with 4 additions and 2 deletions
|
|
@ -106,8 +106,10 @@ int sm_unwrap() {
|
|||
}
|
||||
}
|
||||
}
|
||||
if (!body)
|
||||
return CCID_WRONG_DATA;
|
||||
if (!body) {
|
||||
apdu.nc = 0;
|
||||
return CCID_OK;
|
||||
}
|
||||
if (is87 && *body++ != 0x1) {
|
||||
return CCID_WRONG_PADDING;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue