aboutsummaryrefslogtreecommitdiffstats
path: root/pySim/commands.py
diff options
context:
space:
mode:
authorPhilipp Maier <pmaier@sysmocom.de>2018-07-19 12:00:44 +0200
committerHarald Welte <laforge@gnumonks.org>2018-07-25 18:52:58 +0000
commitfb98dd6d6e9162d18c665e30c97e0ae4781e780f (patch)
tree6fbc7a85bee89d2151f4f2d88b6a18b79d7190e3 /pySim/commands.py
parent53b6dc216f86c26af0fa0a8f5383e212f4fdf8a9 (diff)
commands: depend on pytlv only when it is actually needed
Some of the USIM-Card programming implementations do not need to look at card responses, which means they also do not have to parse TLV data. Lets depend on pytlv only in cases where TLV data has to be parsed so that useser of cards that do not need at can go without installing pytlv. Change-Id: Ida841d74d9581e7f395751b0f74556a06a038de6
Diffstat (limited to 'pySim/commands.py')
-rw-r--r--pySim/commands.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pySim/commands.py b/pySim/commands.py
index 9e16b0e..73c2247 100644
--- a/pySim/commands.py
+++ b/pySim/commands.py
@@ -23,7 +23,6 @@
#
from pySim.utils import rpad, b2h
-from pytlv.TLV import *
class SimCardCommands(object):
def __init__(self, transport):
@@ -35,6 +34,7 @@ class SimCardCommands(object):
def __get_len_from_tlv(self, fcp):
# see also: ETSI TS 102 221, chapter 11.1.1.3.1 Response for MF,
# DF or ADF
+ from pytlv.TLV import TLV
tlvparser = TLV(['82', '83', '84', 'A5', '8a', '8b', '8c', '80', 'ab', 'c6', '81', '88'])
# pytlv is case sensitive!