mirror of
https://gitea.osmocom.org/sim-card/pysim.git
synced 2026-03-21 12:58:33 +03:00
Allow RAW data when editing files/records
This commit is contained in:
@@ -787,6 +787,7 @@ class TransparentEF(CardEF):
|
||||
t = self._tlv() if inspect.isclass(self._tlv) else self._tlv
|
||||
t.from_dict(abstract_data)
|
||||
return t.to_tlv()
|
||||
return h2b(abstract_data['raw'])
|
||||
raise NotImplementedError(
|
||||
"%s encoder not yet implemented. Patches welcome." % self)
|
||||
|
||||
@@ -816,6 +817,7 @@ class TransparentEF(CardEF):
|
||||
t = self._tlv() if inspect.isclass(self._tlv) else self._tlv
|
||||
t.from_dict(abstract_data)
|
||||
return b2h(t.to_tlv())
|
||||
return abstract_data['raw']
|
||||
raise NotImplementedError(
|
||||
"%s encoder not yet implemented. Patches welcome." % self)
|
||||
|
||||
@@ -1097,6 +1099,7 @@ class LinFixedEF(CardEF):
|
||||
t = self._tlv() if inspect.isclass(self._tlv) else self._tlv
|
||||
t.from_dict(abstract_data)
|
||||
return b2h(t.to_tlv())
|
||||
return abstract_data['raw']
|
||||
raise NotImplementedError(
|
||||
"%s encoder not yet implemented. Patches welcome." % self)
|
||||
|
||||
@@ -1126,6 +1129,7 @@ class LinFixedEF(CardEF):
|
||||
t = self._tlv() if inspect.isclass(self._tlv) else self._tlv
|
||||
t.from_dict(abstract_data)
|
||||
return t.to_tlv()
|
||||
return h2b(abstract_data['raw'])
|
||||
raise NotImplementedError(
|
||||
"%s encoder not yet implemented. Patches welcome." % self)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user