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

August 2022

  • 3 participants
  • 2402 discussions
Change in libosmocore[master]: gsm0808_enc_aoip_trasp_addr: add length check
by osmith 05 Aug '22

05 Aug '22
Attention is currently required from: osmith. Hello Jenkins Builder, pespin, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/libosmocore/+/28938 to look at the new patch set (#2). Change subject: gsm0808_enc_aoip_trasp_addr: add length check ...................................................................... gsm0808_enc_aoip_trasp_addr: add length check Instead of running into OSMO_ASSERT in msgb_put(), return early if the msgb is too small. As suggested by Pau in [1]. I would have returned -EMSGSIZE, but the function returns uint8_t. [1]: https://gerrit.osmocom.org/c/osmo-bsc-nat/+/28582/2#message-a183c463ea20a8d… Change-Id: I632986b99d841abff0f14c6da65f030175f5c4a1 --- M src/gsm/gsm0808_utils.c M tests/gsm0808/gsm0808_test.c 2 files changed, 40 insertions(+), 8 deletions(-) git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/38/28938/2 -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/28938 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: I632986b99d841abff0f14c6da65f030175f5c4a1 Gerrit-Change-Number: 28938 Gerrit-PatchSet: 2 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: osmith <osmith(a)sysmocom.de> Gerrit-MessageType: newpatchset
1 0
0 0
Change in libosmocore[master]: gsm0808_enc_aoip_trasp_addr: add length check
by pespin 05 Aug '22

05 Aug '22
Attention is currently required from: osmith. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/28938 ) Change subject: gsm0808_enc_aoip_trasp_addr: add length check ...................................................................... Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/28938 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: I632986b99d841abff0f14c6da65f030175f5c4a1 Gerrit-Change-Number: 28938 Gerrit-PatchSet: 1 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: osmith <osmith(a)sysmocom.de> Gerrit-Comment-Date: Fri, 05 Aug 2022 11:19:58 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmo-bsc-nat[master]: bssap_conn: fix missing length check
by osmith 05 Aug '22

05 Aug '22
Attention is currently required from: pespin. osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc-nat/+/28582 ) Change subject: bssap_conn: fix missing length check ...................................................................... Patch Set 2: (1 comment) File src/osmo-bsc-nat/bssap_conn.c: https://gerrit.osmocom.org/c/osmo-bsc-nat/+/28582/comment/6f6240ee_c8c358cf PS2, Line 60: len = IP_V4_ADDR_LEN; > AFAIR and from waht you mention, msgb_put checks length by calling osmo_panic(), which is not desira […] Done, updated this patch and submitted https://gerrit.osmocom.org/c/libosmocore/+/28938 -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc-nat/+/28582 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc-nat Gerrit-Branch: master Gerrit-Change-Id: I1fc4c81e139bab3d7d977ef9467f62d8088884db Gerrit-Change-Number: 28582 Gerrit-PatchSet: 2 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Fri, 05 Aug 2022 11:18:04 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: osmith <osmith(a)sysmocom.de> Comment-In-Reply-To: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: comment
1 0
0 0
Change in osmo-bsc-nat[master]: bssap_conn: fix missing length check
by osmith 05 Aug '22

05 Aug '22
Attention is currently required from: osmith. Hello Jenkins Builder, pespin, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/osmo-bsc-nat/+/28582 to look at the new patch set (#3). Change subject: bssap_conn: fix missing length check ...................................................................... bssap_conn: fix missing length check Check length of msg_new before trying to encode a copy of the IE into it. The code path for IE_AOIP_TRASP_ADDR is different since it gets replaced. With the libosmocore patch in Depends below the gsm0808_enc_aoip_trasp_addr function checks the length. Depends: libosmocore I632986b99d841abff0f14c6da65f030175f5c4a1 Fixes: Coverity CID#273004 Change-Id: I1fc4c81e139bab3d7d977ef9467f62d8088884db --- M src/osmo-bsc-nat/bssap_conn.c 1 file changed, 14 insertions(+), 8 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bsc-nat refs/changes/82/28582/3 -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc-nat/+/28582 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc-nat Gerrit-Branch: master Gerrit-Change-Id: I1fc4c81e139bab3d7d977ef9467f62d8088884db Gerrit-Change-Number: 28582 Gerrit-PatchSet: 3 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: osmith <osmith(a)sysmocom.de> Gerrit-MessageType: newpatchset
1 0
0 0
Change in libosmocore[master]: gsm0808_enc_aoip_trasp_addr: add length check
by osmith 05 Aug '22

05 Aug '22
osmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmocore/+/28938 ) Change subject: gsm0808_enc_aoip_trasp_addr: add length check ...................................................................... gsm0808_enc_aoip_trasp_addr: add length check Instead of running into OSMO_ASSERT in msg_put(), return early if the msgb is too small. As suggested by Pau in [1]. I would have returned -EMSGSIZE, but the function returns uint8_t. [1]: https://gerrit.osmocom.org/c/osmo-bsc-nat/+/28582/2#message-a183c463ea20a8d… Change-Id: I632986b99d841abff0f14c6da65f030175f5c4a1 --- M src/gsm/gsm0808_utils.c M tests/gsm0808/gsm0808_test.c 2 files changed, 40 insertions(+), 8 deletions(-) git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/38/28938/1 diff --git a/src/gsm/gsm0808_utils.c b/src/gsm/gsm0808_utils.c index 040872b..ac1c4bf 100644 --- a/src/gsm/gsm0808_utils.c +++ b/src/gsm/gsm0808_utils.c @@ -78,7 +78,7 @@ /*! Encode TS 08.08 AoIP transport address IE * \param[out] msg Message Buffer to which to append IE * \param[in] ss Socket Address to be used in IE - * \returns number of bytes added to \a msg */ + * \returns number of bytes added to \a msg; 0 if msg is too small */ uint8_t gsm0808_enc_aoip_trasp_addr(struct msgb *msg, const struct sockaddr_storage *ss) { @@ -87,16 +87,27 @@ struct sockaddr_in6 *sin6; uint16_t port = 0; uint8_t *ptr; - uint8_t *old_tail; - uint8_t *tlv_len; + uint8_t len_tl = 2; + uint8_t len_v = sizeof(port); OSMO_ASSERT(msg); OSMO_ASSERT(ss); OSMO_ASSERT(ss->ss_family == AF_INET || ss->ss_family == AF_INET6); + switch (ss->ss_family) { + case AF_INET: + len_v += IP_V4_ADDR_LEN; + break; + case AF_INET6: + len_v += IP_V6_ADDR_LEN; + break; + } + + if (msgb_tailroom(msg) < len_tl + len_v) + return 0; + msgb_put_u8(msg, GSM0808_IE_AOIP_TRASP_ADDR); - tlv_len = msgb_put(msg,1); - old_tail = msg->tail; + msgb_put_u8(msg, len_v); switch (ss->ss_family) { case AF_INET: @@ -114,9 +125,7 @@ } msgb_put_u16(msg, port); - - *tlv_len = (uint8_t) (msg->tail - old_tail); - return *tlv_len + 2; + return len_tl + len_v; } /*! Decode TS 08.08 AoIP transport address IE diff --git a/tests/gsm0808/gsm0808_test.c b/tests/gsm0808/gsm0808_test.c index 158aeba..b3aa3ab 100644 --- a/tests/gsm0808/gsm0808_test.c +++ b/tests/gsm0808/gsm0808_test.c @@ -924,6 +924,28 @@ msgb_free(msg); } +static void test_enc_aoip_trasp_addr_msg_too_small() +{ + struct msgb *msg; + struct sockaddr_storage enc_addr; + struct sockaddr_in enc_addr_in; + uint8_t rc_enc; + + memset(&enc_addr_in, 0, sizeof(enc_addr_in)); + enc_addr_in.sin_family = AF_INET; + enc_addr_in.sin_port = htons(1234); + inet_aton("255.0.255.255", &enc_addr_in.sin_addr); + + memset(&enc_addr, 0, sizeof(enc_addr)); + memcpy(&enc_addr, &enc_addr_in, sizeof(enc_addr_in)); + + msg = msgb_alloc(7, "output buffer"); + rc_enc = gsm0808_enc_aoip_trasp_addr(msg, &enc_addr); + OSMO_ASSERT(rc_enc == 0); + + msgb_free(msg); +} + static void test_gsm0808_enc_dec_speech_codec() { struct gsm0808_speech_codec enc_sc = { @@ -2540,6 +2562,7 @@ test_enc_dec_aoip_trasp_addr_v4(); test_enc_dec_aoip_trasp_addr_v6(); + test_enc_aoip_trasp_addr_msg_too_small(); test_gsm0808_enc_dec_speech_codec(); test_gsm0808_enc_dec_speech_codec_ext_with_cfg(); test_gsm0808_enc_dec_speech_codec_with_cfg(); -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/28938 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: I632986b99d841abff0f14c6da65f030175f5c4a1 Gerrit-Change-Number: 28938 Gerrit-PatchSet: 1 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-MessageType: newchange
1 0
0 0
Change in osmo-bsc[master]: bts_trx_vty: prefix bb_trxc mo with [Virtual] for ericsson BTS
by pespin 05 Aug '22

05 Aug '22
Attention is currently required from: laforge, dexter. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/28895 ) Change subject: bts_trx_vty: prefix bb_trxc mo with [Virtual] for ericsson BTS ...................................................................... Patch Set 3: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/28895 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I0f5501f6fbc7ce6d5457676b16c7f93f70db5763 Gerrit-Change-Number: 28895 Gerrit-PatchSet: 3 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-CC: laforge <laforge(a)osmocom.org> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Fri, 05 Aug 2022 11:11:04 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmo-bsc[master]: abis_om2000: duplicate nmstate of bb_trxc mo to trx mo
by pespin 05 Aug '22

05 Aug '22
Attention is currently required from: laforge, dexter. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/28896 ) Change subject: abis_om2000: duplicate nmstate of bb_trxc mo to trx mo ...................................................................... Patch Set 3: Code-Review+1 (1 comment) File src/osmo-bsc/abis_om2000.c: https://gerrit.osmocom.org/c/osmo-bsc/+/28896/comment/c401f2ac_c72b2e6a PS2, Line 2303: memset(&nsd_bb_transc, 0, sizeof(nsd)); > You mean basically copying nsd (trx) to nsd_bb_transc (bb_transc) I think thats problematic. […] Not really, because the virtual bbtransc will always have the same state as the trx, so you an copy it from the trx one. I think this code can really be cleaned up further, but anyway just adding +1. -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/28896 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I4611d8af16a30725308bd527098b12a356bfde9f Gerrit-Change-Number: 28896 Gerrit-PatchSet: 3 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-CC: laforge <laforge(a)osmocom.org> Gerrit-Attention: laforge <laforge(a)osmocom.org> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Fri, 05 Aug 2022 11:10:28 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Comment-In-Reply-To: pespin <pespin(a)sysmocom.de> Comment-In-Reply-To: dexter <pmaier(a)sysmocom.de> Gerrit-MessageType: comment
1 0
0 0
Change in osmo-bsc[master]: abis_om2000: om2k_trx_s_done_onenter() does not send signal
by pespin 05 Aug '22

05 Aug '22
Attention is currently required from: dexter. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/28916 ) Change subject: abis_om2000: om2k_trx_s_done_onenter() does not send signal ...................................................................... Patch Set 2: (1 comment) Patchset: PS2: linter needs fixing -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/28916 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: Iabf9f3a1a345c5d53d9a4d02fa2d6d13ddfd86ae Gerrit-Change-Number: 28916 Gerrit-PatchSet: 2 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: pespin <pespin(a)sysmocom.de> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Fri, 05 Aug 2022 11:02:57 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment
1 0
0 0
Change in osmo-bsc[master]: abis_om2000: update_op_state() does not send signal
by pespin 05 Aug '22

05 Aug '22
Attention is currently required from: dexter. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/28915 ) Change subject: abis_om2000: update_op_state() does not send signal ...................................................................... Patch Set 2: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/28915 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: Id19c6beb2bc79c4db0ec07ef593aacb57fff8b75 Gerrit-Change-Number: 28915 Gerrit-PatchSet: 2 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Fri, 05 Aug 2022 11:01:38 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmo-bsc[master]: abis_om2000: constify mo in mo2obj
by pespin 05 Aug '22

05 Aug '22
Attention is currently required from: dexter. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/28937 ) Change subject: abis_om2000: constify mo in mo2obj ...................................................................... Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/28937 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: Ia09d0c96c8938e287fdbad343b9605cbfd6ff6a1 Gerrit-Change-Number: 28937 Gerrit-PatchSet: 1 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: dexter <pmaier(a)sysmocom.de> Gerrit-Comment-Date: Fri, 05 Aug 2022 11:01:02 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 199
  • 200
  • 201
  • 202
  • 203
  • 204
  • 205
  • ...
  • 241
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.