Private/secret keys can be selected.
It returns FCP when a private/secret key is selected but it is not allowed to read them. Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
@@ -222,6 +222,7 @@ static int cmd_select() {
|
|||||||
uint8_t pfx = fid >> 8;
|
uint8_t pfx = fid >> 8;
|
||||||
if (pfx == PRKD_PREFIX ||
|
if (pfx == PRKD_PREFIX ||
|
||||||
pfx == CD_PREFIX ||
|
pfx == CD_PREFIX ||
|
||||||
|
pfx == KEY_PREFIX ||
|
||||||
pfx == EE_CERTIFICATE_PREFIX ||
|
pfx == EE_CERTIFICATE_PREFIX ||
|
||||||
pfx == DCOD_PREFIX ||
|
pfx == DCOD_PREFIX ||
|
||||||
pfx == DATA_PREFIX ||
|
pfx == DATA_PREFIX ||
|
||||||
@@ -448,7 +449,7 @@ static int cmd_read_binary()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!authenticate_action(ef, ACL_OP_READ_SEARCH)) {
|
if ((fid >> 8) == KEY_PREFIX || !authenticate_action(ef, ACL_OP_READ_SEARCH)) {
|
||||||
return SW_SECURITY_STATUS_NOT_SATISFIED();
|
return SW_SECURITY_STATUS_NOT_SATISFIED();
|
||||||
}
|
}
|
||||||
if (ef->data) {
|
if (ef->data) {
|
||||||
|
|||||||
Reference in New Issue
Block a user