Android security tags, read closely by Lightrion

CVE-2026-49880 AI-generated analysis

platform/packages/modules/Nfc, libnfc-nci NFA T4T NFCEE (ndefnfcee/t4t/nfa_nfcee_act.cc)

AI-generated: written from the bulletin and the fixing diffs by claude-fable-5-1, then checked against the code by claude-opus-5-5 (6 corrections). Verify against the commit before relying on it.

Adds an allocated-size field (p_dataBuf_len) to the T4T NFCEE control block and checks rd_offset + p_data->len against it before the memcpy in nfa_t4tnfcee_store_rx_buf, plus length guards in nfa_t4tnfcee_check_sw and nfa_t4tnfcee_store_cc_info and NULL checks on the two nfa_mem_co_alloc results.

Root cause

nfa_t4tnfcee_store_rx_buf copied p_data->len bytes of received T4T NFCEE data into nfa_t4tnfcee_cb.p_dataBuf at nfa_t4tnfcee_cb.rd_offset and then advanced rd_offset, with no knowledge of the buffer's allocated size. The buffer is allocated earlier with a fixed size: lenDataToBeRead in nfa_t4tnfcee_handle_file_operations, or p_data->len in nfa_t4tnfcee_store_cc_info. Incoming data whose cumulative length exceeds that allocation therefore overflows the heap buffer. The control block had no field recording the allocation size, so no check was possible. Adjacent issues: nfa_t4tnfcee_check_sw computed p += (p_r_apdu->len - T4T_RSP_STATUS_WORDS_SIZE) without checking that len is at least T4T_RSP_STATUS_WORDS_SIZE, so short responses underflow the pointer. The else branch of nfa_t4tnfcee_store_cc_info used p_data->len without checking that it covers 0x07 plus the status bytes (a uint16 underflow per the commit message). Neither nfa_mem_co_alloc result was checked for NULL.

How the fix works

Completeness

Behavior changes

Per major

Unknowns

Back to October 2026 · Findings