11.12.3.4.116. Function Se05x_API_ReadSize¶
Defined in File se05x_APDU_apis.h
11.12.3.4.116.1. Function Documentation¶
-
smStatus_t
Se05x_API_ReadSize
(pSe05xSession_t session_ctx, uint32_t objectID, uint16_t *psize)¶ Se05x_API_ReadSize
ReadSize
Get the size of a Secure Object (in bytes):
For EC keys: the size of the curve is returned.
For RSA keys: the key size is returned.
For AES/DES/HMAC keys, the key size is returned.
For binary files: the file size is returned
For userIDs: nothing is returned (SW_CONDITIONS_NOT_SATISFIED).
For counters: the counter length is returned.
For PCR: the PCR length is returned.
Command to Applet
Field
Value
Description
CLA
0x80
INS
INS_READ
See
SE05x_INS_t
P1
P1_DEFAULT
See
SE05x_P1_t
P2
P2_SIZE
See
SE05x_P2_t
Lc
#(Payload)
TLV[TAG_1]
4-byte object identifier.
Le
0x00
R-APDU Body
Value
Description
TLV[TAG_1]
Byte array containing size.
R-APDU Trailer
SW
Description
SW_NO_ERROR
Data is returned successfully.
- Return
The sm status.
- Parameters
[in] session_ctx
: The session context[in] objectID
: The object idpsize
: The psize