This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
laforge gerrit-no-reply at lists.osmocom.orglaforge has submitted this change. ( https://gerrit.osmocom.org/c/pysim/+/17458 ) Change subject: sysmoISIM-SJA2: Add suport for USIM-only and ISIM-only cards ...................................................................... sysmoISIM-SJA2: Add suport for USIM-only and ISIM-only cards When pysim-prog programms the application specific files of ISIM and USIM it selects the application by its AID first. If depending on the card profile one of the applications is missing the selection of the related ADF will fail. Lets check the presence of the AID first and if it is not present lets skip the programming of the related files. Change-Id: I0eec6ed244320fcd4dc410b6fab20df9c64ff906 Related: SYS#4817 --- M pySim/cards.py 1 file changed, 12 insertions(+), 10 deletions(-) Approvals: Jenkins Builder: Verified laforge: Looks good to me, approved diff --git a/pySim/cards.py b/pySim/cards.py index 0f84834..a872ee0 100644 --- a/pySim/cards.py +++ b/pySim/cards.py @@ -1054,20 +1054,22 @@ # update EF-USIM_AUTH_KEY in ADF.ISIM self._scc.select_file(['3f00']) aid = self.read_aid(isim = True) - self._scc.select_adf(aid) - if p.get('ki'): - self._scc.update_binary('af20', p['ki'], 1) - if p.get('opc'): - self._scc.update_binary('af20', p['opc'], 17) + if (aid): + self._scc.select_adf(aid) + if p.get('ki'): + self._scc.update_binary('af20', p['ki'], 1) + if p.get('opc'): + self._scc.update_binary('af20', p['opc'], 17) # update EF-USIM_AUTH_KEY in ADF.USIM self._scc.select_file(['3f00']) aid = self.read_aid() - self._scc.select_adf(aid) - if p.get('ki'): - self._scc.update_binary('af20', p['ki'], 1) - if p.get('opc'): - self._scc.update_binary('af20', p['opc'], 17) + if (aid): + self._scc.select_adf(aid) + if p.get('ki'): + self._scc.update_binary('af20', p['ki'], 1) + if p.get('opc'): + self._scc.update_binary('af20', p['opc'], 17) return -- To view, visit https://gerrit.osmocom.org/c/pysim/+/17458 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I0eec6ed244320fcd4dc410b6fab20df9c64ff906 Gerrit-Change-Number: 17458 Gerrit-PatchSet: 1 Gerrit-Owner: dexter <pmaier at sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge at osmocom.org> Gerrit-MessageType: merged -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200311/9e3599bb/attachment.htm>