laforge has submitted this change. ( https://gerrit.osmocom.org/c/pysim/+/31814 )
Change subject: SimCardCommands.run_gsm(): use send_apdu_checksw() ......................................................................
SimCardCommands.run_gsm(): use send_apdu_checksw()
Change-Id: Ib713cf8154a3aba72bc5776a8d99ec47631ade28 --- M pySim/commands.py 1 file changed, 10 insertions(+), 1 deletion(-)
Approvals: laforge: Looks good to me, approved Jenkins Builder: Verified
diff --git a/pySim/commands.py b/pySim/commands.py index ba37876..b0f8b39 100644 --- a/pySim/commands.py +++ b/pySim/commands.py @@ -407,7 +407,7 @@ if len(rand) != 32: raise ValueError('Invalid rand') self.select_path(['3f00', '7f20']) - return self._tp.send_apdu('a0' + '88000010' + rand) + return self._tp.send_apdu_checksw('a0' + '88000010' + rand, sw='9000')
def authenticate(self, rand: str, autn: str, context='3g'): """Execute AUTHENTICATE (USIM/ISIM).