mirror of
https://gitea.osmocom.org/sim-card/pysim.git
synced 2026-06-24 08:48:30 +03:00
fix(ts_51_011): apply correct access conditions length
When the access conditions are extracted from resp_bin, the wrong length is used and only 2 bytes instead of 3 are extracted. 3GPP TS 51.011, section 9.2.1, table below "Response parameters/data in case of an EF", clearly states that the length should be 3 bytes (position 9-11) Related: OS#7018 Change-Id: I410fb58c395beafba8de6d5ab4e71452f424cdf2
This commit is contained in:
+1
-1
@@ -1305,7 +1305,7 @@ class CardProfileSIM(CardProfile):
|
||||
record_len = resp_bin[14]
|
||||
ret['file_descriptor']['record_len'] = record_len
|
||||
ret['file_descriptor']['num_of_rec'] = ret['file_size'] // record_len
|
||||
ret['access_conditions'] = b2h(resp_bin[8:10])
|
||||
ret['access_conditions'] = b2h(resp_bin[8:11])
|
||||
if resp_bin[11] & 0x01 == 0:
|
||||
ret['life_cycle_status_int'] = 'operational_activated'
|
||||
elif resp_bin[11] & 0x04:
|
||||
|
||||
Reference in New Issue
Block a user