9ae9c39e55
EF_PBR ('4F30', TS 31.102 4.4.2.1) lists the phonebook's files as
BER-TLVs, and those files are not in pySim's model - so they were
invisible in the file tree.
- The PWA gains the decoder (efDecPbr, registered as EF.PBR/4f30): the
'A8'/'A9'/'AA' type-1/2/3 containers, the 'C0'-'CC' kinds, the 02/03
value lengths (FID / FID+SFI) and the master EF (the first FID after
the first 'A8'), tolerant of FF padding, truncation, unknown tags and
the spec's vague 'AA' path form (kept raw + noted, never a throw).
- The server reads the three PBR copies once per card session
(best-effort, exactly like EF.ARR) into server.pbr and serves the raw
records from the card-free GET /api/pbr.
- The file tree is populated SERVER-SIDE (no frontend involvement): a
small Python parser reads the cached records and /api/tree appends the
referenced files as children of the DF that holds the PBR
({'name','fid','isDir':false,'pbr':true,'sfi'}, deduplicated against
the model), and /api/tree|select|read|write auto-allow the probe for
exactly those FIDs, so the injected nodes are clickable without any
PWA flag. The node-to-PBR match is by the requested node's normalised
path: a leading MF before an ADF segment is dropped and an ADF
addressed by AID (the Profiler's walk) folds onto its name, so both
DF_PHONEBOOK copies resolve to their own PBR; a full path never falls
back to another DF's copy, and an ambiguous bare 5F3A injects nothing.
- Drift guard: the JS and Python parsers share
frontend/tests/pbr_vectors.json, which includes the TS 31.102 Annex G
record (its printed A8 length is internally inconsistent - 10
primitives x 5 bytes = 0x32, not the printed 0x2D - so the corrected
length is used, noted in the case name).
Docs: api.md (/api/pbr, the tree children, the auto-probe, the AA path
form), the repo AGENTS. 953 frontend + 989 Python; sw simple-v455.
21 lines
702 B
TOML
21 lines
702 B
TOML
[build-system]
|
|
requires = ["setuptools", "wheel"]
|
|
build-backend = "setuptools.build_meta"
|
|
|
|
[project]
|
|
name = "pysim-simple-server"
|
|
version = "3.31.0"
|
|
description = "HTTP REST server wrapping pysim for the SIMple PWA"
|
|
requires-python = ">=3.8"
|
|
# pysim is a git-only dependency installed explicitly by setup.bat/setup.sh.
|
|
# Declaring it here would make pip resolve its full tree (including the SMPP
|
|
# bridge -> Twisted -> twisted-iocpsupport, which needs MSVC on Windows).
|
|
|
|
[project.scripts]
|
|
pysim-simple-server = "pysim_simple_server.__main__:main"
|
|
|
|
[tool.setuptools.packages.find]
|
|
include = ["pysim_simple_server*"]
|
|
|
|
[tool.setuptools.package-data]
|
|
pysim_simple_server = ["data/*.json", "data/*.LICENSE"] |