mirror of
https://github.com/polhenarejos/pico-hsm.git
synced 2026-05-07 12:43:06 +00:00
Code style
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
parent
2f63966c60
commit
ee73c6e781
2 changed files with 4 additions and 2 deletions
|
|
@ -68,8 +68,9 @@ int cmd_mse() {
|
|||
&chr_len);
|
||||
if (memcmp(chr, tag_data, chr_len) == 0) {
|
||||
ef_puk_aut = ef;
|
||||
if (puk_status[i] == 1)
|
||||
if (puk_status[i] == 1) {
|
||||
return SW_CONDITIONS_NOT_SATISFIED(); // It is correct
|
||||
}
|
||||
return SW_OK();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,8 +23,9 @@ int cmd_puk_auth() {
|
|||
uint8_t p1 = P1(apdu), p2 = P2(apdu);
|
||||
file_t *ef_puk = search_by_fid(EF_PUKAUT, NULL, SPECIFY_EF);
|
||||
if (!file_has_data(ef_puk)) {
|
||||
if (apdu.nc > 0)
|
||||
if (apdu.nc > 0) {
|
||||
return SW_FILE_NOT_FOUND();
|
||||
}
|
||||
return SW_INCORRECT_P1P2();
|
||||
}
|
||||
uint8_t *puk_data = file_get_data(ef_puk);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue