aboutsummaryrefslogtreecommitdiffstats
path: root/pySim/cards.py
diff options
context:
space:
mode:
authorPhilipp Maier <pmaier@sysmocom.de>2022-06-14 16:18:12 +0200
committerPhilipp Maier <pmaier@sysmocom.de>2022-06-21 09:56:49 +0200
commitbda52830c9f7a1cc5f8d9b02ff0908aa3175333a (patch)
treebf127d3edb5ba46032f8a4e4f5d8f347027214a2 /pySim/cards.py
parent2403125a34a903456ddbc6d4fabcc14ee4be24c1 (diff)
cards: populate ADM1 key reference member
In class SimCard, we specify the key reference for ADM1 as 0x04. in the UsimCard class, which inherits from SimCard nothing is specified, even though ETSI TS 102 221 specifies 0x0A as key reference. Lets set the member in UsimCard accordingly to be closer to the spec. Note: For the moment this is a cosmetic fix, it does not change the behaviour since all card classes derived from UsimCard set the key reference properly. Change-Id: I96af395b1832f4462a6043cca3bb3812fddac612
Diffstat (limited to 'pySim/cards.py')
-rw-r--r--pySim/cards.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/pySim/cards.py b/pySim/cards.py
index b186044..18e4ef3 100644
--- a/pySim/cards.py
+++ b/pySim/cards.py
@@ -348,6 +348,9 @@ class UsimCard(SimCard):
def __init__(self, ssc):
super(UsimCard, self).__init__(ssc)
+ # See also: ETSI TS 102 221, Table 9.3
+ self._adm_chv_num = 0xA0
+
def read_ehplmn(self):
(res, sw) = self._scc.read_binary(EF_USIM_ADF_map['EHPLMN'])
if sw == '9000':