laforge has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/35890?usp=email )
Change subject: global_platform: Add --suppress-key-check option to put_key command
......................................................................
global_platform: Add --suppress-key-check option to put_key command
In some cases we may not want to auto-generate the Key Check Values.
Change-Id: I244b717b3e3aae6eb3ad512f9e23ff0b65958bb7
---
M pySim/global_platform/__init__.py
1 file changed, 18 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/90/35890/1
diff --git a/pySim/global_platform/__init__.py b/pySim/global_platform/__init__.py
index ca99f5f..4d553a7 100644
--- a/pySim/global_platform/__init__.py
+++ b/pySim/global_platform/__init__.py
@@ -515,12 +515,17 @@
put_key_parser.add_argument('--key-type', choices=KeyType.ksymapping.values(), action='append', required=True, help='Key Type')
put_key_parser.add_argument('--key-data', type=is_hexstr, action='append', required=True, help='Key Data Block')
put_key_parser.add_argument('--key-check', type=is_hexstr, action='append', help='Key Check Value')
+ put_key_parser.add_argument('--suppress-key-check', action='store_true', help='Suppress generation of Key Check Values')
@cmd2.with_argparser(put_key_parser)
def do_put_key(self, opts):
"""Perform the GlobalPlatform PUT KEY command in order to store a new key on the card.
See GlobalPlatform CardSpecification v2.3 Section 11.8 for details.
+ The KCV (Key Check Values) can either be explicitly specified using `--key-check`, or will
+ otherwise be automatically generated for DES and AES keys. You can suppress the latter using
+ `--suppress-key-check`.
+
Example (SCP80 KIC/KID/KIK):
put_key --key-version-nr 1 --key-id 0x01 --key-type aes --key-data 000102030405060708090a0b0c0d0e0f
--key-type aes --key-data 101112131415161718191a1b1c1d1e1f
@@ -537,6 +542,8 @@
for i in range(0, len(opts.key_type)):
if opts.key_check and len(opts.key_check) > i:
kcv = opts.key_check[i]
+ elif opts.suppress_key_check:
+ kcv = ''
else:
kcv_bin = compute_kcv(opts.key_type[i], h2b(opts.key_data[i])) or b''
kcv = b2h(kcv_bin)
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/35890?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I244b717b3e3aae6eb3ad512f9e23ff0b65958bb7
Gerrit-Change-Number: 35890
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-MessageType: newchange
Attention is currently required from: laforge.
pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/35884?usp=email )
Change subject: epdg: Introduce test TC_ho_lte_to_wifi
......................................................................
Patch Set 1:
(1 comment)
Patchset:
PS1:
> it's great that we have *that* kind of exotic test coverage. […]
Most of the stuff is really on other nodes, in ePDG/AAA it's just about adding Create/DeleteBearerRequest, and it helps me have the full state model in place.
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/35884?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Ibdfeda1fa5d7016b1952d64b306cd501cb33f61b
Gerrit-Change-Number: 35884
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Comment-Date: Tue, 06 Feb 2024 17:51:46 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>
Gerrit-MessageType: comment
Attention is currently required from: pespin.
laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/35884?usp=email )
Change subject: epdg: Introduce test TC_ho_lte_to_wifi
......................................................................
Patch Set 1: Code-Review+1
(1 comment)
Patchset:
PS1:
it's great that we have *that* kind of exotic test coverage. In general I would suggest to make sure the basic functioanlity works fully end-to-end, before thinkign about inter-rat handover etc.
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/35884?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Ibdfeda1fa5d7016b1952d64b306cd501cb33f61b
Gerrit-Change-Number: 35884
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Tue, 06 Feb 2024 17:48:32 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment