v3.25.0 review: the DF-tree ARR resolution walk-up

The live card references 6F06 from MF-tree files (MF/7F20/6F07 ->
8B 03 6F06 14), but the resolver compared only the path's first
segment: the reference fell back to the ADF.USIM copy instead of the
file's own DF copy (ISO 7816-4 5.4.3.3 / TS 102 221 9.2.7 walk-up) -
masked on this card only because all four copies are byte-identical.

- The server reads the DF.TELECOM and DF.GSM copies too (MF/7F10/6F06,
  MF/7F20/6F06 - TS 51.011), best effort.
- fcpArrRules resolves by the file's DF chain (own DF first, then
  walking up to MF); a reference with no copy in the chain resolves
  only when a single candidate exists, otherwise it stays silent.
- The implicit form prefers the file's DF copy (6F06), walking up to
  the MF copy (2F06).

Tests: the DF copy wins over the ADF copy; two candidates outside the
chain stay unresolved; a single one resolves; the implicit walk-up;
the server reads the DF-tree paths.  879 frontend + 858 Python;
sw cache simple-v424.
This commit is contained in:
2026-10-10 23:26:16 +03:00
parent 3bf005619e
commit a37266f865
7 changed files with 82 additions and 17 deletions
+5 -4
View File
@@ -486,10 +486,11 @@ def _read_iccid(app):
# EF.ARR copies referenced by the FCP security attribute DO '8B' (ISO 7816-4
# Table 25): the MF copy and the ADF.USIM copy (TS 102 221 13.4). The read
# runs once per card session (_refresh_arr_cache); the PWA's file manager
# resolves the referenced record's access rules against the cache.
ARR_READ_PATHS = ('MF/2F06', 'ADF.USIM/6F06')
# Table 25): the MF copy, the DF.TELECOM/DF.GSM copies (TS 51.011 7F10/7F20)
# and the ADF.USIM copy (TS 102 221 13.4). The read runs once per card
# session (_refresh_arr_cache); the PWA's file manager resolves the referenced
# record's access rules against the cache (the file's DF chain wins).
ARR_READ_PATHS = ('MF/2F06', 'MF/7F10/6F06', 'MF/7F20/6F06', 'ADF.USIM/6F06')
ARR_RECORD_LIMIT = 64