Attention is currently required from: laforge.
neels has posted comments on this change by neels. (
https://gerrit.osmocom.org/c/pysim/+/40094?usp=email )
Change subject: personalization: set default values
......................................................................
Patch Set 4:
(6 comments)
Commit Message:
https://gerrit.osmocom.org/c/pysim/+/40094/comment/7d871308_60acd266?usp=em… :
PS2, Line 11: This is useful for user interaction, to prefill an input field that
: indicates a valid input to modify to taste.
I beg to differ. […]
I think it looks odd in
this patch because i later on separated the patch from the ParamSource patch. The defaults
make more sense when you realize that, in practice, they mostly indicate the lengths for
automatically generated digits.
For example, for Pin1 + RandomDigitSource, the user input is just '0000' to get a
four digit random PIN, or '000000' to get a six digit pin.
A default value makes sense to indicate the input format to the user.
Indicating IMSI as '0010100000000000' + IncrementingDigitSource:
it is obvious that it is not a usual IMSI that I entered,
and it greatly clarifies what to enter to get a useful result.
A default value can make sense to indicate the most secure / most likely option,
like suggesting the longest allowed (random) key length, or choosing Milenage by default.
If I remove all defaults from sysmo-esim-mgr, then a user as to manually enter digits for
all of K. Opc, Pin, Adm, all SdKeys before generating is possible.
It is infinitely more helpful to have a default of e.g. '0*16'+RandomDigitSource
set for K, so users don't have to look it up.
Note, assigning a default value is not actually done in pysim, it is merely up to a caller
to use the default value paired with a param source. code wise, it is very useful to place
the info here, not in the caller.
File pySim/esim/saip/personalization.py:
https://gerrit.osmocom.org/c/pysim/+/40094/comment/64b7939f_cdedf895?usp=em… :
PS2, Line 278: default_value
there's no point of an all-zero default ICCID.
that's true, it's a copy paste artifact from the random parameters...
in the esim mgr, we never let a user enter an ICCID so i never noticed.
I think it's still the most useful indicator for number of digits, if anyone ever used
it.
We can set an empty default... but why drop the informational example?
https://gerrit.osmocom.org/c/pysim/+/40094/comment/22716676_d37c6a14?usp=em… :
PS2, Line 299:
I also think there's no point in having a default
for the IMSI
I explained my IMSI point above, let's continue the discussion
there
https://gerrit.osmocom.org/c/pysim/+/40094/comment/3e590015_d58515a1?usp=em… :
PS2, Line 467: default_value = '0' * allow_len
I'm not sure why any security key / pin should
have any default value at all. […]
I made the point above: it goes with a
RandomDigitSource, let's continue the discussion there
https://gerrit.osmocom.org/c/pysim/+/40094/comment/faf7649c_757c13aa?usp=em… :
PS2, Line 494: default_value = '0' * max_len
same here
Done
https://gerrit.osmocom.org/c/pysim/+/40094/comment/a75bdfec_0b31fbde?usp=em… :
PS2, Line 582: default_value = '00' * allow_len
no cryptographic key should have any default value.
It's just creating security nightmares.
I made the point above: it is just a
length indicator for a RandomDigitSource. Let's continue the discussion there
--
To view, visit
https://gerrit.osmocom.org/c/pysim/+/40094?usp=email
To unsubscribe, or for help writing mail filters, visit
https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I2672fedcbc32cb7a6cb0c233a4a22112bd9aae03
Gerrit-Change-Number: 40094
Gerrit-PatchSet: 4
Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Comment-Date: Mon, 04 Aug 2025 17:27:55 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>