aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarald Welte <laforge@osmocom.org>2022-07-17 22:24:03 +0200
committerHarald Welte <laforge@osmocom.org>2022-07-18 09:35:35 +0200
commit363edd9d34d9c952d015a5a189fbbed5b7408773 (patch)
tree42b6611baccb43d1efe2f4153d7f5bd379d1430f
parentd90ceb86be68d93ed911355493733073c58e1884 (diff)
ts_31_102: Add support for obsolete EF.RPLMNAcT
This file existed in earlier specs like Release 3.8.0, but was removed in later revisions. Still, there are cards around implementing that older spec, so let's add a decoder. Change-Id: Ic7163b2a01f64ef1223cf15b8d0813d3edf5b61a
-rw-r--r--pySim/ts_31_102.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/pySim/ts_31_102.py b/pySim/ts_31_102.py
index a4f3532..314f3c2 100644
--- a/pySim/ts_31_102.py
+++ b/pySim/ts_31_102.py
@@ -743,6 +743,15 @@ class EF_THRESHOLD(TransparentEF):
super().__init__(fid, sfid=sfid, name=name, desc=desc, size=size, **kwargs)
self._construct = Struct('max_start'/Int24ub)
+# TS 31.102 (old releases like 3.8.0) Section 4.2.56
+class EF_RPLMNAcT(TransRecEF):
+ def __init__(self, fid='6f65', sfid=None, name='EF.RPLMNAcTD', size={2, 4}, rec_len=2,
+ desc='RPLMN Last used Access Technology', **kwargs):
+ super().__init__(fid, sfid=sfid, name=name, desc=desc, size=size, rec_len=rec_len, **kwargs)
+ def _decode_record_hex(self, in_hex):
+ return dec_act(in_hex)
+ # TODO: Encode
+
# TS 31.102 Section 4.2.77
class EF_VGCSCA(TransRecEF):
def __init__(self, fid='6fd4', sfid=None, name='EF.VGCSCA', size={2, 100}, rec_len=2,
@@ -1165,6 +1174,7 @@ class ADF_USIM(CardADF):
EF_xPLMNwAcT('6f61', 0x11, 'EF.OPLMNwAcT', 'User controlled PLMN Selector with Access Technology', service=42),
EF_xPLMNwAcT('6f62', 0x13, 'EF.HPLMNwAcT', 'HPLMN Selector with Access Technology', service=43),
EF_ARR('6f06', 0x17),
+ EF_RPLMNAcT(),
TransparentEF('6fc4', None, 'EF.NETPAR', 'Network Parameters'),
EF_PNN('6fc5', 0x19, service=45),
EF_OPL(service=46),