aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Willmann <daniel@totalueberwachung.de>2018-06-15 07:42:48 +0200
committerDaniel Willmann <daniel@totalueberwachung.de>2018-06-15 07:42:48 +0200
commit690b08c9f086b26e0a4a4a0da0846e880c27e656 (patch)
treee15a4caac1ddad9c09643c2ccc6cba66bedbbf90
parent3d0122733f3eb219a5e2d0507de258545a56fec1 (diff)
Make programming OPC optionalusers/daniel/csv-format
-rw-r--r--pySim/cards.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/pySim/cards.py b/pySim/cards.py
index 494d62c..47b3922 100644
--- a/pySim/cards.py
+++ b/pySim/cards.py
@@ -528,8 +528,9 @@ class SysmoUSIMSJS1(Card):
data, sw = self._scc.update_binary('00FF', p['ki'])
# set Ki in proprietary file
- content = "01" + p['opc']
- data, sw = self._scc.update_binary('00F7', content)
+ if 'opc' in p:
+ content = "01" + p['opc']
+ data, sw = self._scc.update_binary('00F7', content)
# write EF.IMSI