laforge has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/27329 ) Change subject: ts_102_221: Fix decoding the 'num_of_rec' field ...................................................................... ts_102_221: Fix decoding the 'num_of_rec' field It is a 8bit integer, not a 16bit integer. See TS 102 221 11.1.1.4.3 Change-Id: I3e258547dad21a248650cfbc02e0576268d3b3fd --- M pySim/ts_102_221.py 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/29/27329/1 diff --git a/pySim/ts_102_221.py b/pySim/ts_102_221.py index 708b50b..713d169 100644 --- a/pySim/ts_102_221.py +++ b/pySim/ts_102_221.py @@ -103,7 +103,7 @@ 'structure'/Enum(BitsInteger(3), no_info_given=0, transparent=1, linear_fixed=2, cyclic=6)) ) _construct = Struct('file_descriptor_byte'/FDB, Const(b'\x21'), - 'record_len'/COptional(Int16ub), 'num_of_rec'/COptional(Int16ub)) + 'record_len'/COptional(Int16ub), 'num_of_rec'/COptional(Int8ub)) # ETSI TS 102 221 11.1.1.4.4 class FileIdentifier(BER_TLV_IE, tag=0x83): -- To view, visit https://gerrit.osmocom.org/c/pysim/+/27329 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I3e258547dad21a248650cfbc02e0576268d3b3fd Gerrit-Change-Number: 27329 Gerrit-PatchSet: 1 Gerrit-Owner: laforge <laforge@osmocom.org> Gerrit-MessageType: newchange