From 5e0439f881a8f94671742181dea8012a33f6c1d1 Mon Sep 17 00:00:00 2001 From: Harald Welte Date: Sat, 27 Jan 2024 21:07:38 +0100 Subject: [PATCH] ara_m: Permit encoding of empty AID (--aid '') in ARA-M rules Encoding an empty AID-REF-DO (4F) is neccessary to achieve the meaning described in "Secure Element Access Control - Public Release v1.0" Table 6-1: "Empty: Indicates that the rules to be stored or retrieved are associated with all SE applications not covered by a specific rule". Change-Id: Iac6c3d78bc9ce36bac47589e5f7a0cc78e2efc38 --- pySim/ara_m.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pySim/ara_m.py b/pySim/ara_m.py index 68244d12..f05109b8 100644 --- a/pySim/ara_m.py +++ b/pySim/ara_m.py @@ -348,7 +348,7 @@ class ADF_ARAM(CardADF): """Perform STORE DATA [Command-Store-REF-AR-DO] to store a (new) access rule.""" # REF ref_do_content = [] - if opts.aid: + if opts.aid != None: ref_do_content += [{'aid_ref_do': opts.aid}] elif opts.aid_empty: ref_do_content += [{'aid_ref_empty_do': None}]