Change in pysim[master]: SysmoISIM-SJA2: Add option to set Service Provider Name (SPN)

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/.

Robert Falkenberg gerrit-no-reply at lists.osmocom.org
Tue Apr 6 10:04:55 UTC 2021


Robert Falkenberg has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/23652 )


Change subject: SysmoISIM-SJA2: Add option to set Service Provider Name (SPN)
......................................................................

SysmoISIM-SJA2: Add option to set Service Provider Name (SPN)

Same implementation as for sysmoUSIM-SJS1

Change-Id: I3a9dd2fe85126584758ea4cfa127f9cd14ab0c7d
---
M pySim/cards.py
1 file changed, 5 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/52/23652/1

diff --git a/pySim/cards.py b/pySim/cards.py
index 5eb2884..ad6ddbc 100644
--- a/pySim/cards.py
+++ b/pySim/cards.py
@@ -1266,6 +1266,11 @@
 		# select DF_GSM
 		self._scc.select_path(['7f20'])
 
+		# set Service Provider Name
+		if p.get('name') is not None:
+			content = enc_spn(p['name'], True, True)
+			data, sw = self._scc.update_binary('6F46', rpad(content, 32))
+
 		# write EF.IMSI
 		if p.get('imsi'):
 			self._scc.update_binary('6f07', enc_imsi(p['imsi']))

-- 
To view, visit https://gerrit.osmocom.org/c/pysim/+/23652
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I3a9dd2fe85126584758ea4cfa127f9cd14ab0c7d
Gerrit-Change-Number: 23652
Gerrit-PatchSet: 1
Gerrit-Owner: Robert Falkenberg <robert.falkenberg at tu-dortmund.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210406/0ec85074/attachment.htm>


More information about the gerrit-log mailing list