Attention is currently required from: neels.
Hello Jenkins Builder, neels,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/libosmo-sccp/+/29084
to look at the new patch set (#7).
Change subject: SIGTRAN: cache Optional Data for SCCP CR/CC/RLSD
......................................................................
SIGTRAN: cache Optional Data for SCCP CR/CC/RLSD
Limit length of optional Data parameter is 130 bytes according to ITU-T Rec Q.713 §4.2..§4.5. If we receive CR, CC or
RLSD message with bigger data - cache it if necessary and send via separate DT1 message after connection becomes active.
While at it, clarify the order of comments in the encoding routine to match the spec.
Fixes: OS#5579
Change-Id: I0033faf9da393418930252233ce74d62cd1cef8a
---
M src/sccp_scoc.c
1 file changed, 131 insertions(+), 17 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-sccp refs/changes/84/29084/7
--
To view, visit https://gerrit.osmocom.org/c/libosmo-sccp/+/29084
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-sccp
Gerrit-Branch: master
Gerrit-Change-Id: I0033faf9da393418930252233ce74d62cd1cef8a
Gerrit-Change-Number: 29084
Gerrit-PatchSet: 7
Gerrit-Owner: msuraev <msuraev(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-MessageType: newpatchset
Attention is currently required from: laforge, Christian Amsüss.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/29066 )
Change subject: proactive: Avoid clobbering the output of the command that triggered the FETCH
......................................................................
Patch Set 2: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/29066
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I2b794a5c5bc808b9703b4bc679c119341a0ed41c
Gerrit-Change-Number: 29066
Gerrit-PatchSet: 2
Gerrit-Owner: Christian Amsüss <chrysn(a)fsfe.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: Christian Amsüss <chrysn(a)fsfe.org>
Gerrit-Comment-Date: Sun, 21 Aug 2022 12:27:23 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: Christian Amsüss.
laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/29067 )
Change subject: proactive: Send a Terminal Response automatically after a Fetch
......................................................................
Patch Set 2: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/29067
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I43bc994e7517b5907fb40a98d84797c54056c47d
Gerrit-Change-Number: 29067
Gerrit-PatchSet: 2
Gerrit-Owner: Christian Amsüss <chrysn(a)fsfe.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: Christian Amsüss <chrysn(a)fsfe.org>
Gerrit-Comment-Date: Sun, 21 Aug 2022 11:57:07 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: laforge, pespin, Christian Amsüss, dexter.
laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/29033 )
Change subject: Add new pySim.ota library, implement SIM OTA crypto
......................................................................
Patch Set 7:
(1 comment)
Patchset:
PS7:
so somewhere in the changes from 5 -> 7 we have a regression in the command encoding. I yet have to figure out where this is coming from. I don't see any changes other than the PCNT?
======================================================================
FAIL: test_cmd_3des_ciphered (test_ota.Test_SMS_3DES)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/space/home/laforge/projects/git/pysim/tests/test_ota.py", line 71, in test_cmd_3des_ciphered
self.assertEqual(b2h(r), '00180d04193535b000000c8478b552a4ffc5a8f099b83cad7123')
AssertionError: '00180d04193535b00000e3ec80a849b554421276af3883927c20' != '00180d04193535b000000c8478b552a4ffc5a8f099b83cad7123'
- 00180d04193535b00000e3ec80a849b554421276af3883927c20
+ 00180d04193535b000000c8478b552a4ffc5a8f099b83cad7123
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/29033
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I193ff4712c8503279c017b4b1324f0c3d38b9f84
Gerrit-Change-Number: 29033
Gerrit-PatchSet: 7
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: Christian Amsüss <chrysn(a)fsfe.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: Christian Amsüss <chrysn(a)fsfe.org>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Sun, 21 Aug 2022 11:53:22 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: pespin, Christian Amsüss, dexter.
Hello Jenkins Builder, pespin, Christian Amsüss, dexter,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/pysim/+/29033
to look at the new patch set (#7).
Change subject: Add new pySim.ota library, implement SIM OTA crypto
......................................................................
Add new pySim.ota library, implement SIM OTA crypto
This introduces a hierarchy of classes implementing
* ETS TS 102 225 (general command structure)
* 3GPP TS 31.115 (dialects for SMS-PP)
In this initial patch only the SMS "dialect" is supported,
but it is foreseen that USSD/SMSCB/HTTPS dialects can be
added at a later point.
Change-Id: I193ff4712c8503279c017b4b1324f0c3d38b9f84
---
M contrib/jenkins.sh
A pySim/ota.py
A pySim/sms.py
M requirements.txt
M setup.py
A tests/test_ota.py
6 files changed, 585 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/33/29033/7
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/29033
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I193ff4712c8503279c017b4b1324f0c3d38b9f84
Gerrit-Change-Number: 29033
Gerrit-PatchSet: 7
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: Christian Amsüss <chrysn(a)fsfe.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: Christian Amsüss <chrysn(a)fsfe.org>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-MessageType: newpatchset
Attention is currently required from: pespin, Christian Amsüss, dexter.
laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/29033 )
Change subject: Add new pySim.ota library, implement SIM OTA crypto
......................................................................
Patch Set 6:
(9 comments)
File pySim/ota.py:
https://gerrit.osmocom.org/c/pysim/+/29033/comment/57493321_f2f0ac00
PS4, Line 44: S 102 225 Table 5
: ota_status_codes = bidict({
: 0x00: 'PoR OK',
: 0x01: 'RC/CC/DS failed',
: 0x02: 'CNTR low',
: 0x03: 'CNTR high',
: 0x04: 'CNTR blocked',
: 0x05: 'Ciphering error',
: 0x06: 'Unidentified security error',
: 0x07: 'Insufficient memory',
: 0x08: 'more time',
: 0x09: 'TAR unknown',
: 0x0a: 'Insufficient security level',
: 0x0b: 'Actual Response in SMS-SUBMIT', # 31.115
: 0x0c: 'Actual Response in USSD', # 31.115
: })
> This bidict is redundant with ResponseStatus, and not used anywhere. […]
yes, that can be removed. It goes back to some very old first attempts of implementing this months if not years ago.
https://gerrit.osmocom.org/c/pysim/+/29033/comment/dcfd2648_d6a0b5e4
PS4, Line 120: algo_auth: str, kid_idx: int, kid: bytes, cntr: int = 0):
> I'm very suspicious of the counter having zero as a default; the symmetric algorithm is already init […]
I understand the point. the rationale here was that in 99% of all current use cases we won't be using the counter, as we don't have any central database/backend where we would store the current per-card OTA counter. Also, 99% of the sysmoISIM-SJA2 users (which are probably >95% of our overall user base for this feature) have cards with a MSL not requiring counters, as they are used in a research/development setting and if you have multiple different programs talking OTA over time without any centralized counter storage...
File pySim/ota.py:
https://gerrit.osmocom.org/c/pysim/+/29033/comment/ac77469f_e7816b5b
PS5, Line 347: apdu += otak.crypt._get_padding(len_cipher, otak.crypt.blocksize)
> This should also set pad_cnt. […]
your patch was cherry-picked + squashed, thanks.
https://gerrit.osmocom.org/c/pysim/+/29033/comment/ebf6a889_70f16a20
PS5, Line 402: def decode_resp(self, otak: OtaKeyset, spi: dict, data: bytes) -> bytes:
> `-> bytes` is currently inaccurate, should be `CompactRemoteResp` (but see below)
Done
https://gerrit.osmocom.org/c/pysim/+/29033/comment/934b91bf_385bd7e8
PS5, Line 416: res = self.SmsResponsePacket.parse(remainder)
> Do we trust this parsing step enought, to […]
I'm not sure I understand you here. Why would it be bad if that call would raise some exception, which in turn propagetes further upt to the caller of decode_resp() ?
https://gerrit.osmocom.org/c/pysim/+/29033/comment/c79cdf29_b9e4bdb9
PS5, Line 443: cc = otak.auth.check_sig(temp_data, res['cc_rc'])
> Needless assign; check_sig is merely called for the exception it'd raise.
ack, fixing it in my next version.
https://gerrit.osmocom.org/c/pysim/+/29033/comment/85d113f1_874c01f6
PS5, Line 452: return dec
> There will need to be an API change later here, as in cases of `res. […]
Done
File pySim/sms.py:
https://gerrit.osmocom.org/c/pysim/+/29033/comment/a109665c_65c7f816
PS5, Line 30: ie_c = Struct('offset'/Tell, 'iei'/Int8ub, 'length'/Int8ub, 'data'/Bytes(this.length))
> There is an updated version of this in your patch series, which is easier to understand and removes […]
updated version pushed.
https://gerrit.osmocom.org/c/pysim/+/29033/comment/00bc2456_49a7dd02
PS5, Line 39: def __str__(self) -> str:
> I think this would be more useful as `__repr__`, especially as it does produce an expression that'd […]
squashed your related patch into my patch
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/29033
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I193ff4712c8503279c017b4b1324f0c3d38b9f84
Gerrit-Change-Number: 29033
Gerrit-PatchSet: 6
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: Christian Amsüss <chrysn(a)fsfe.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: Christian Amsüss <chrysn(a)fsfe.org>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Sun, 21 Aug 2022 11:34:38 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Christian Amsüss <chrysn(a)fsfe.org>
Gerrit-MessageType: comment
Attention is currently required from: laforge, pespin, dexter.
Hello Jenkins Builder, pespin, Christian Amsüss, dexter,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/pysim/+/29033
to look at the new patch set (#6).
Change subject: Add new pySim.ota library, implement SIM OTA crypto
......................................................................
Add new pySim.ota library, implement SIM OTA crypto
This introduces a hierarchy of classes implementing
* ETS TS 102 225 (general command structure)
* 3GPP TS 31.115 (dialects for SMS-PP)
In this initial patch only the SMS "dialect" is supported,
but it is foreseen that USSD/SMSCB/HTTPS dialects can be
added at a later point.
Change-Id: I193ff4712c8503279c017b4b1324f0c3d38b9f84
---
M contrib/jenkins.sh
A pySim/ota.py
A pySim/sms.py
M requirements.txt
M setup.py
A tests/test_ota.py
6 files changed, 603 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/33/29033/6
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/29033
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I193ff4712c8503279c017b4b1324f0c3d38b9f84
Gerrit-Change-Number: 29033
Gerrit-PatchSet: 6
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: Christian Amsüss <chrysn(a)fsfe.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-MessageType: newpatchset