Change in pysim[master]: Use zero padding for EF['ACC'] field

Robert Falkenberg gerrit-no-reply at lists.osmocom.org
Mon Apr 5 06:15:33 UTC 2021


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


Change subject: Use zero padding for EF['ACC'] field
......................................................................

Use zero padding for EF['ACC'] field

Change-Id: I1b8dc01a6c48adad1ed8158de59b12519ed688e9
---
M pySim/cards.py
1 file changed, 2 insertions(+), 1 deletion(-)



  git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/31/23631/1

diff --git a/pySim/cards.py b/pySim/cards.py
index 5eb2884..0d5d6b9 100644
--- a/pySim/cards.py
+++ b/pySim/cards.py
@@ -76,7 +76,8 @@
 		return sw
 
 	def update_acc(self, acc):
-		data, sw = self._scc.update_binary(EF['ACC'], lpad(acc, 4))
+		#data, sw = self._scc.update_binary(EF['ACC'], lpad(acc, 4))
+		data, sw = self._scc.update_binary(EF['ACC'], lpad(acc, 4, c='0'))
 		return sw
 
 	def read_hplmn_act(self):

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

Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I1b8dc01a6c48adad1ed8158de59b12519ed688e9
Gerrit-Change-Number: 23631
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/20210405/33843d19/attachment.htm>


More information about the gerrit-log mailing list