Skip to main content

Module get_status

Module get_status 

Source
Expand description

GET STATUS (CLA 80, INS F2) — PDD §5.12, GPCS v2.3.1 §11.4.

Card/ISD scope: P1 0x80 (Table 11-33), P2 0x02 (Table 11-34: b2=1 modern TLV, b1=0 first/all), Data '4F' 00 match-all (Table 11-35). Response is a 'E3' registry entry carrying '9F70' life-cycle (len 1), '4F' AID, 'C5' privileges (Table 11-36, §11.4.3.1) — verified.

Constants§

P2_FIRST_TLV
P2 = get first/all occurrence(s) + modern TLV response (Table 11-34: b1=0 first/all, b2=1 TLV). The opening value of a paged GET STATUS.
P2_NEXT_TLV
P2 = get next occurrence + modern TLV response (Table 11-34: b1=1 next, b2=1 TLV). Sent to continue after a 63 10 “more data” warning (Table 11-38) when enumerating the registry across pages (PDD §5.12a).

Functions§

get_status
Build a GET STATUS for an arbitrary P1 scope and '4F'-tagged AID qualifier, with P2 fixed at P2_FIRST_TLV (0x02).
get_status_p2
Build a GET STATUS with an explicit P2 — the paginating form used by get_card_inventory (PDD §5.12a) to send P2_FIRST_TLV for the first page and P2_NEXT_TLV to continue after 63 10.