mirror of
https://github.com/polhenarejos/pico-openpgp.git
synced 2026-08-29 08:00:36 +01:00
Return wrong data for invalid reset-code length
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
@@ -98,8 +98,8 @@ int cmd_put_data(void) {
|
||||
r = file_put_data(ef, CONST_BYTE_ARRAY(pw_status, sizeof(pw_status)));
|
||||
}
|
||||
else if (fid == EF_RC) {
|
||||
if ((r = check_pin_len(EF_RC, apdu.nc)) != 0x9000) {
|
||||
return r;
|
||||
if (check_pin_len(EF_RC, apdu.nc) != 0x9000) {
|
||||
return SW_WRONG_DATA();
|
||||
}
|
||||
has_rc = false;
|
||||
if ((r = load_dek()) != PICOKEYS_OK) {
|
||||
|
||||
Reference in New Issue
Block a user