diff --git a/pySim/transport/__init__.py b/pySim/transport/__init__.py index fb8f31d1..923787b6 100644 --- a/pySim/transport/__init__.py +++ b/pySim/transport/__init__.py @@ -68,7 +68,7 @@ class LinkBase(object): data : string (in hex) of returned data (ex. "074F4EFFFF") sw : string (in hex) of status word (ex. "9000") """ - pass + return self._send_apdu_raw(pdu) def send_apdu(self, pdu): """Sends an APDU and auto fetch response data diff --git a/pySim/transport/calypso.py b/pySim/transport/calypso.py index 467d5ee2..3c223e64 100644 --- a/pySim/transport/calypso.py +++ b/pySim/transport/calypso.py @@ -115,7 +115,7 @@ class CalypsoSimLink(LinkBase): def wait_for_card(self, timeout = None, newcardonly = False): pass # Nothing to do really ... - def send_apdu_raw(self, pdu): + def _send_apdu_raw(self, pdu): # Request FULL reset req_msg = L1CTLMessageSIM(h2b(pdu)) diff --git a/pySim/transport/modem_atcmd.py b/pySim/transport/modem_atcmd.py index fccd3881..f5a0f238 100644 --- a/pySim/transport/modem_atcmd.py +++ b/pySim/transport/modem_atcmd.py @@ -97,7 +97,7 @@ class ModemATCommandLink(LinkBase): def wait_for_card(self, timeout=None, newcardonly=False): pass # Nothing to do really ... - def send_apdu_raw(self, pdu): + def _send_apdu_raw(self, pdu): # Prepare the command as described in 8.17 cmd = 'AT+CSIM=%d,\"%s\"' % (len(pdu), pdu) diff --git a/pySim/transport/pcsc.py b/pySim/transport/pcsc.py index f08f71a4..2433e792 100644 --- a/pySim/transport/pcsc.py +++ b/pySim/transport/pcsc.py @@ -71,7 +71,7 @@ class PcscSimLink(LinkBase): self.connect() return 1 - def send_apdu_raw(self, pdu): + def _send_apdu_raw(self, pdu): apdu = h2i(pdu) diff --git a/pySim/transport/serial.py b/pySim/transport/serial.py index 6d393036..22788a90 100644 --- a/pySim/transport/serial.py +++ b/pySim/transport/serial.py @@ -180,7 +180,7 @@ class SerialSimLink(LinkBase): def _rx_byte(self): return self._sl.read() - def send_apdu_raw(self, pdu): + def _send_apdu_raw(self, pdu): pdu = h2b(pdu) data_len = ord(pdu[4]) # P3