lists.osmocom.org
Sign In Sign Up
Manage this list Sign In Sign Up

Keyboard Shortcuts

Thread View

  • j: Next unread message
  • k: Previous unread message
  • j a: Jump to all threads
  • j l: Jump to MailingList overview

gerrit-log

Thread Start a new thread
Download
Threads by month
  • ----- 2026 -----
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2025 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2024 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2023 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2022 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
gerrit-log@lists.osmocom.org

June 2023

  • 1 participants
  • 2480 discussions
[L] Change in pysim[master]: Add support for encoding/decoding SMS in TPDU and SMPP format
by laforge 18 Jun '23

18 Jun '23
laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/33347 ) Change subject: Add support for encoding/decoding SMS in TPDU and SMPP format ...................................................................... Set Ready For Review -- To view, visit https://gerrit.osmocom.org/c/pysim/+/33347 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I0d95e62c1e7183a7851d1fe38df0f5133830cb1f Gerrit-Change-Number: 33347 Gerrit-PatchSet: 2 Gerrit-Owner: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Comment-Date: Sun, 18 Jun 2023 07:58:56 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: No Gerrit-MessageType: comment
1 0
0 0
[M] Change in pysim[master]: tests: Add new, data-driven OTA tests
by Jenkins Builder 18 Jun '23

18 Jun '23
Attention is currently required from: laforge. Jenkins Builder has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/33348 ) Change subject: tests: Add new, data-driven OTA tests ...................................................................... Patch Set 2: (1 comment) File tests/test_ota.py: Robot Comment from checkpatch (run ID jenkins-gerrit-lint-8398): https://gerrit.osmocom.org/c/pysim/+/33348/comment/fb331739_b733594c PS2, Line 181: # unittest subTests context manager to iterate over the entires of 'entires' may be misspelled - perhaps 'entries'? -- To view, visit https://gerrit.osmocom.org/c/pysim/+/33348 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I8789a21fa5a4793bdabd468adc9fee3b6e633c25 Gerrit-Change-Number: 33348 Gerrit-PatchSet: 2 Gerrit-Owner: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Comment-Date: Sun, 18 Jun 2023 07:15:42 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment
1 0
0 0
[S] Change in libosmocore[master]: core/osmo_io: Fix reception of partial packets
by laforge 18 Jun '23

18 Jun '23
Attention is currently required from: arehbein. laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/33346 ) Change subject: core/osmo_io: Fix reception of partial packets ...................................................................... Patch Set 2: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/33346 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: I0ab8028c807b4181fddd3c00ea2e037c40cf0813 Gerrit-Change-Number: 33346 Gerrit-PatchSet: 2 Gerrit-Owner: arehbein <arehbein(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: arehbein <arehbein(a)sysmocom.de> Gerrit-Comment-Date: Sun, 18 Jun 2023 06:25:38 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
[S] Change in libosmocore[master]: gsm/ipa: Add segmentation callback
by fixeria 17 Jun '23

17 Jun '23
Attention is currently required from: arehbein, pespin, daniel. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/33083 ) Change subject: gsm/ipa: Add segmentation callback ...................................................................... Patch Set 10: Code-Review-1 (7 comments) File src/gsm/ipa.c: https://gerrit.osmocom.org/c/libosmocore/+/33083/comment/854abcf7_d002ad5c PS8, Line 728: * -EIO, if the header declares a payload too large */ > */ on the next line Done https://gerrit.osmocom.org/c/libosmocore/+/33083/comment/3a4ea39a_1c162155 PS8, Line 735: const struct ipaccess_head *hh = (const struct ipaccess_head *) msg->data; > Agreeing with Pau here. […] Done https://gerrit.osmocom.org/c/libosmocore/+/33083/comment/33e71ea9_d53bedf9 PS8, Line 737: size_t total_len = payload_len + sizeof(*hh); > "sizeof(*hh) + payload_len;" it's logically easier to understand, as in lefto-to-right order filling […] Done https://gerrit.osmocom.org/c/libosmocore/+/33083/comment/821e589a_d23d9a03 PS8, Line 738: if (msgb_tailroom(msg) + msgb_length(msg) < total_len) { > > iiuc the problem here is that the allocated msgb space is not going to be enough to fit in what IP […] Done File src/gsm/ipa.c: https://gerrit.osmocom.org/c/libosmocore/+/33083/comment/441ff0d5_56f4edf9 PS10, Line 733: osmo_ntohs(hh->len); Now the problem is that you're accessing the buffer before checking if there is enough data in it. https://gerrit.osmocom.org/c/libosmocore/+/33083/comment/d6b63790_c2f79979 PS10, Line 735: msgb_length(msg) + msgb_tailroom(msg); This is incorrect. `msgb_length(msg)` is basically `msg->len`, which does include the tailroom and headroom. Please revert back to `msg->len` or `msgb_length(msg)` alone. https://gerrit.osmocom.org/c/libosmocore/+/33083/comment/bcbc3027_8e493c26 PS10, Line 744: EIO `ENOMEM` or `ENOSPC` is a better fit here, IMO. -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/33083 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: I3a639e6896cc3b3fc8e9b2e1a58254710efa0d3f Gerrit-Change-Number: 33083 Gerrit-PatchSet: 10 Gerrit-Owner: arehbein <arehbein(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-CC: daniel <dwillmann(a)sysmocom.de> Gerrit-Attention: arehbein <arehbein(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Attention: daniel <dwillmann(a)sysmocom.de> Gerrit-Comment-Date: Sat, 17 Jun 2023 19:05:42 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Comment-In-Reply-To: pespin <pespin(a)sysmocom.de> Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-MessageType: comment
1 0
0 0
[S] Change in libosmocore[master]: core/osmo_io: Fix reception of partial packets
by arehbein 17 Jun '23

17 Jun '23
Attention is currently required from: laforge. arehbein has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/33346 ) Change subject: core/osmo_io: Fix reception of partial packets ...................................................................... Patch Set 1: (2 comments) Patchset: PS1: > I don't really understand this patch (but then I'm not an expert in the new osmo_io code). […] You're correct, I didn't at first understand the code well enough and thought of maintaining `iofd->pending` parallel to `msg` (in `iofd_poll_ofd_cb_recvmsg_sendmsg()`) in case of an incompletely received message (instead of removing it from the osmo_io fd via ` msg = iofd_msgb_pending_or_alloc(iofd);`). So my first approach was to maintain the old logic while trying to add new logic in case of having previously received an incompletely read packet, which is why it turned out like this. File src/core/osmo_io_poll.c: https://gerrit.osmocom.org/c/libosmocore/+/33346/comment/411d08d3_9fb8bbe9 PS1, Line 59: iofd > IMHO, the unconditional iov_base = msg->tail should do the trick here. […] Yes thanks, good catch. I changed the patch accordingly. -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/33346 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: I0ab8028c807b4181fddd3c00ea2e037c40cf0813 Gerrit-Change-Number: 33346 Gerrit-PatchSet: 1 Gerrit-Owner: arehbein <arehbein(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Comment-Date: Sat, 17 Jun 2023 18:40:48 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: laforge <laforge(a)osmocom.org> Gerrit-MessageType: comment
1 0
0 0
[S] Change in libosmocore[master]: core/osmo_io: Fix reception of partial packets
by arehbein 17 Jun '23

17 Jun '23
Attention is currently required from: arehbein. Hello Jenkins Builder, laforge, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/libosmocore/+/33346 to look at the new patch set (#2). Change subject: core/osmo_io: Fix reception of partial packets ...................................................................... core/osmo_io: Fix reception of partial packets Always append to 'msg->tail' instead of to 'msg->data'. Change-Id: I0ab8028c807b4181fddd3c00ea2e037c40cf0813 --- M src/core/osmo_io_poll.c 1 file changed, 12 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/46/33346/2 -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/33346 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: I0ab8028c807b4181fddd3c00ea2e037c40cf0813 Gerrit-Change-Number: 33346 Gerrit-PatchSet: 2 Gerrit-Owner: arehbein <arehbein(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: arehbein <arehbein(a)sysmocom.de> Gerrit-MessageType: newpatchset
1 0
0 0
[S] Change in libosmocore[master]: gsm/ipa: Add segmentation callback
by arehbein 17 Jun '23

17 Jun '23
Attention is currently required from: arehbein, pespin, daniel. Hello Jenkins Builder, laforge, pespin, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/libosmocore/+/33083 to look at the new patch set (#10). Change subject: gsm/ipa: Add segmentation callback ...................................................................... gsm/ipa: Add segmentation callback Add segmentation callback to be used by the streaming backend of libosmo-netif Related: OS#5753, OS#5751 Change-Id: I3a639e6896cc3b3fc8e9b2e1a58254710efa0d3f --- M include/osmocom/gsm/ipa.h M src/gsm/ipa.c M src/gsm/libosmogsm.map 3 files changed, 44 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/83/33083/10 -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/33083 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: I3a639e6896cc3b3fc8e9b2e1a58254710efa0d3f Gerrit-Change-Number: 33083 Gerrit-PatchSet: 10 Gerrit-Owner: arehbein <arehbein(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-CC: daniel <dwillmann(a)sysmocom.de> Gerrit-CC: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: arehbein <arehbein(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Attention: daniel <dwillmann(a)sysmocom.de> Gerrit-MessageType: newpatchset
1 0
0 0
[L] Change in pysim[master]: Add support for encoding/decoding SMS in TPDU and SMPP format
by fixeria 17 Jun '23

17 Jun '23
Attention is currently required from: laforge. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/33347 ) Change subject: Add support for encoding/decoding SMS in TPDU and SMPP format ...................................................................... Patch Set 1: (2 comments) File contrib/jenkins.sh: https://gerrit.osmocom.org/c/pysim/+/33347/comment/5d4b969b_312879de PS1, Line 25: pip install git+https://github.com/hologram-io/smpp.pdu Is this really needed given that you adding this dep to `requirements.txt`? File ota_test.py: https://gerrit.osmocom.org/c/pysim/+/33347/comment/8ab8e82e_5143a312 PS1, Line 1: #!/usr `/usr/bin/env python3` please -- To view, visit https://gerrit.osmocom.org/c/pysim/+/33347 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I0d95e62c1e7183a7851d1fe38df0f5133830cb1f Gerrit-Change-Number: 33347 Gerrit-PatchSet: 1 Gerrit-Owner: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Comment-Date: Sat, 17 Jun 2023 11:25:05 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment
1 0
0 0
[M] Change in pysim[master]: tests: Add new, data-driven OTA tests
by Jenkins Builder 17 Jun '23

17 Jun '23
Jenkins Builder has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/33348 ) Change subject: tests: Add new, data-driven OTA tests ...................................................................... Patch Set 1: (1 comment) File tests/test_ota.py: Robot Comment from checkpatch (run ID jenkins-gerrit-lint-8395): https://gerrit.osmocom.org/c/pysim/+/33348/comment/da54181a_4572c9b9 PS1, Line 181: # unittest subTests context manager to iterate over the entires of 'entires' may be misspelled - perhaps 'entries'? -- To view, visit https://gerrit.osmocom.org/c/pysim/+/33348 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I8789a21fa5a4793bdabd468adc9fee3b6e633c25 Gerrit-Change-Number: 33348 Gerrit-PatchSet: 1 Gerrit-Owner: laforge <laforge(a)osmocom.org> Gerrit-CC: Jenkins Builder Gerrit-Comment-Date: Sat, 17 Jun 2023 11:11:50 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment
1 0
0 0
[M] Change in pysim[master]: tests: Add new, data-driven OTA tests
by laforge 17 Jun '23

17 Jun '23
laforge has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/33348 ) Change subject: tests: Add new, data-driven OTA tests ...................................................................... tests: Add new, data-driven OTA tests Rather than writing one test class with associated method for each OTA algorithm / test, let's do this in a data-driven way, where new test cases just have to provide test data, while the code iterates over it. Change-Id: I8789a21fa5a4793bdabd468adc9fee3b6e633c25 --- M tests/test_ota.py 1 file changed, 151 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/48/33348/1 diff --git a/tests/test_ota.py b/tests/test_ota.py index c58a69d..896839c 100644 --- a/tests/test_ota.py +++ b/tests/test_ota.py @@ -2,6 +2,7 @@ import unittest from pySim.utils import h2b, b2h +from pySim.sms import SMS_SUBMIT, SMS_DELIVER, AddressField from pySim.ota import * # pre-defined SPI values for use in test cases below @@ -35,6 +36,9 @@ 'por': 'por_required' } +###################################################################### +# old-style code-driven test (lots of code copy+paste) +###################################################################### class Test_SMS_AES128(unittest.TestCase): tar = h2b('B00011') @@ -146,3 +150,136 @@ spi['rc_cc_ds'] = 'no_rc_cc_ds' r = self.dialect.encode_cmd(self.od, self.tar, spi, h2b('00a40000023f00')) self.assertEqual(b2h(r), '0d00193535b0000000000000000000a40000023f00') + + + +###################################################################### +# new-style data-driven tests +###################################################################### + +# SJA5 SAMPLE cards provisioned by execute_ipr.py +OTA_KEYSET_SJA5_SAMPLES = OtaKeyset(algo_crypt='triple_des_cbc2', kic_idx=3, + algo_auth='triple_des_cbc2', kid_idx=3, + kic=h2b('300102030405060708090a0b0c0d0e0f'), + kid=h2b('301102030405060708090a0b0c0d0e0f')) + +OTA_KEYSET_SJA5_AES128 = OtaKeyset(algo_crypt='aes_cbc', kic_idx=2, + algo_auth='aes_cmac', kid_idx=2, + kic=h2b('200102030405060708090a0b0c0d0e0f'), + kid=h2b('201102030405060708090a0b0c0d0e0f')) + +class OtaTestCase(unittest.TestCase): + def __init__(self, methodName='runTest', **kwargs): + super().__init__(methodName, **kwargs) + # RAM: B00000 + # SIM RFM: B00010 + # USIM RFM: B00011 + self.tar = h2b('B00011') + +class SmsOtaTestCase(OtaTestCase): + # Array describing the input/output data for the tests. We use the + # unittest subTests context manager to iterate over the entires of + # this testdatasets list. This is much more productive than + # manually writing one class per test. + testdatasets = [ + { + 'name': '3DES-SJA5-CIPHERED-CC', + 'ota_keyset': OTA_KEYSET_SJA5_SAMPLES, + 'spi': SPI_CC_POR_CIPHERED_CC, + 'request': { + 'apdu': b'\x00\xa4\x00\x04\x02\x3f\x00', + 'encoded_cmd': '00201506193535b00011ae733256918d050b87c94fbfe12e4dc402f262c41cf67f2f', + 'encoded_tpdu': '400881214365877ff6227052000000000302700000201506193535b00011ae733256918d050b87c94fbfe12e4dc402f262c41cf67f2f', + }, + 'response': { + 'encoded_resp': '027100001c12b000118bb989492c632529326a2f4681feb37c825bc9021c9f6d0b', + 'response_status': 'por_ok', + 'number_of_commands': 1, + 'last_status_word': '6132', + 'last_response_data': '', + } + }, { + 'name': '3DES-SJA5-UNCIPHERED-CC', + 'ota_keyset': OTA_KEYSET_SJA5_SAMPLES, + 'spi': SPI_CC_POR_UNCIPHERED_CC, + 'request': { + 'apdu': b'\x00\xa4\x00\x04\x02\x3f\x00', + 'encoded_cmd': '00201506093535b00011c49ac91ab8159ba5b83a54fb6385e0a5e31694f8b215fafc', + 'encoded_tpdu': '400881214365877ff6227052000000000302700000201506093535b00011c49ac91ab8159ba5b83a54fb6385e0a5e31694f8b215fafc', + }, + 'response': { + 'encoded_resp': '027100001612b0001100000000000000b5bcd6353a421fae016132', + 'response_status': 'por_ok', + 'number_of_commands': 1, + 'last_status_word': '6132', + 'last_response_data': '', + } + }, { + 'name': '3DES-SJA5-UNCIPHERED-NOCC', + 'ota_keyset': OTA_KEYSET_SJA5_SAMPLES, + 'spi': SPI_CC_POR_UNCIPHERED_NOCC, + 'request': { + 'apdu': b'\x00\xa4\x00\x04\x02\x3f\x00', + 'encoded_cmd': '00201506013535b000113190be334900f52b025f3f7eddfe868e96ebf310023b7769', + 'encoded_tpdu': '400881214365877ff6227052000000000302700000201506013535b000113190be334900f52b025f3f7eddfe868e96ebf310023b7769', + }, + 'response': { + 'encoded_resp': '027100000e0ab0001100000000000000016132', + 'response_status': 'por_ok', + 'number_of_commands': 1, + 'last_status_word': '6132', + 'last_response_data': '', + } + }, { + 'name': 'AES128-SJA5-CIPHERED-CC', + 'ota_keyset': OTA_KEYSET_SJA5_AES128, + 'spi': SPI_CC_POR_CIPHERED_CC, + 'request': { + 'apdu': b'\x00\xa4\x00\x04\x02\x3f\x00', + 'encoded_cmd': '00281506192222b00011e87cceebb2d93083011ce294f93fc4d8de80da1abae8c37ca3e72ec4432e5058', + 'encoded_tpdu': '400881214365877ff6227052000000000302700000281506192222b00011e87cceebb2d93083011ce294f93fc4d8de80da1abae8c37ca3e72ec4432e5058', + }, + 'response': { + 'encoded_resp': '027100002412b00011ebc6b497e2cad7aedf36ace0e3a29b38853f0fe9ccde81913be5702b73abce1f', + 'response_status': 'por_ok', + 'number_of_commands': 1, + 'last_status_word': '6132', + 'last_response_data': '', + } + }, + # TODO: AES192 + # TODO: AES256 + ] + + def __init__(self, methodName='runTest', **kwargs): + super().__init__(methodName, **kwargs) + self.dialect = OtaDialectSms() + self.da = AddressField('12345678', 'unknown', 'isdn_e164') + + def test_encode_cmd(self): + for t in SmsOtaTestCase.testdatasets: + with self.subTest(name=t['name']): + kset = t['ota_keyset'] + outp = self.dialect.encode_cmd(kset, self.tar, t['spi'], apdu=t['request']['apdu']) + #print("result: %s" % b2h(outp)) + self.assertEqual(b2h(outp), t['request']['encoded_cmd']) + + with_udh = b'\x02\x70\x00' + outp + #print("with_udh: %s" % b2h(with_udh)) + + tpdu = SMS_DELIVER(tp_udhi=True, tp_oa=self.da, tp_pid=0x7F, tp_dcs=0xF6, + tp_scts=h2b('22705200000000'), tp_udl=3, tp_ud=with_udh) + #print("TPDU: %s" % tpdu) + #print("tpdu: %s" % b2h(tpdu.toBytes())) + self.assertEqual(b2h(tpdu.toBytes()), t['request']['encoded_tpdu']) + + def test_decode_resp(self): + for t in SmsOtaTestCase.testdatasets: + with self.subTest(name=t['name']): + kset = t['ota_keyset'] + r, d = self.dialect.decode_resp(kset, t['spi'], t['response']['encoded_resp']) + #print("RESP: %s / %s" % (r, d)) + self.assertEqual(r.response_status, t['response']['response_status']) + self.assertEqual(d.number_of_commands, t['response']['number_of_commands']) + self.assertEqual(d.last_status_word, t['response']['last_status_word']) + self.assertEqual(d.last_response_data, t['response']['last_response_data']) -- To view, visit https://gerrit.osmocom.org/c/pysim/+/33348 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I8789a21fa5a4793bdabd468adc9fee3b6e633c25 Gerrit-Change-Number: 33348 Gerrit-PatchSet: 1 Gerrit-Owner: laforge <laforge(a)osmocom.org> Gerrit-MessageType: newchange
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 96
  • 97
  • 98
  • 99
  • 100
  • 101
  • 102
  • ...
  • 248
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.