Attention is currently required from: neels, laforge, pespin, keith.
laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-msc/+/28114 )
Change subject: WIP: switch from libdbi to lbsqlite3
......................................................................
Set Ready For Review
--
To view, visit https://gerrit.osmocom.org/c/osmo-msc/+/28114
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-Change-Id: Ia334904289f92d014e7bd16b02b3b5817c12c790
Gerrit-Change-Number: 28114
Gerrit-PatchSet: 8
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: keith <keith(a)rhizomatica.org>
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: keith <keith(a)rhizomatica.org>
Gerrit-Comment-Date: Mon, 16 May 2022 20:16:48 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
laforge has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmocore/+/28128 )
Change subject: fsm_vty: use unsigned int when left-shifting 31 bits!
......................................................................
fsm_vty: use unsigned int when left-shifting 31 bits!
fsm_vty.c:64:8: runtime error: left shift of 1 by 31 places cannot be represented in type 'int'
Change-Id: I637bce52fae947922cbb8642a0313d174c827422
---
M src/vty/fsm_vty.c
1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/28/28128/1
diff --git a/src/vty/fsm_vty.c b/src/vty/fsm_vty.c
index 025d0d8..777d38c 100644
--- a/src/vty/fsm_vty.c
+++ b/src/vty/fsm_vty.c
@@ -61,7 +61,7 @@
if (fsm->event_names) {
for (evt_name = fsm->event_names; evt_name->str != NULL; evt_name++) {
vty_out(vty, "%s Event %02u (0x%08x): '%s'%s", prefix, evt_name->value,
- (1 << evt_name->value), evt_name->str, VTY_NEWLINE);
+ (1U << evt_name->value), evt_name->str, VTY_NEWLINE);
}
} else
vty_out(vty, "%s No event names are defined for this FSM! Please fix!%s", prefix, VTY_NEWLINE);
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/28128
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I637bce52fae947922cbb8642a0313d174c827422
Gerrit-Change-Number: 28128
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-MessageType: newchange
laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-msc/+/28125 )
Change subject: smpp: Fix use-after-free bug when ESME disconnects but has write pending
......................................................................
smpp: Fix use-after-free bug when ESME disconnects but has write pending
When the SMPP code free's an ESME it also free's the related write_queue
and the osmo_fd contained therein. So if this happens while we are
in esme_link_read_cb(), we must return -EBADF to make
osmo_wqueue_bfd_cb() of libosmocore avoid further accessing related
memory.
Change-Id: I441d3b05c2f2556c530783a7f66c73adf6d845a1
Closes: OS#5565
---
M src/libmsc/smpp_smsc.c
1 file changed, 1 insertion(+), 1 deletion(-)
Approvals:
pespin: Looks good to me, but someone else must approve
fixeria: Looks good to me, approved
Jenkins Builder: Verified
diff --git a/src/libmsc/smpp_smsc.c b/src/libmsc/smpp_smsc.c
index 4581865..6712032 100644
--- a/src/libmsc/smpp_smsc.c
+++ b/src/libmsc/smpp_smsc.c
@@ -888,7 +888,7 @@
esme->acl->esme = NULL;
smpp_esme_put(esme);
- return 0;
+ return -EBADF;
}
/* call-back of write queue once it wishes to write a message to the socket */
--
To view, visit https://gerrit.osmocom.org/c/osmo-msc/+/28125
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-Change-Id: I441d3b05c2f2556c530783a7f66c73adf6d845a1
Gerrit-Change-Number: 28125
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge(a)osmocom.org>
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-MessageType: merged
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmocore/+/28127 )
Change subject: coding: prevent marking FACCH frames as AMR's special DTX frames
......................................................................
coding: prevent marking FACCH frames as AMR's special DTX frames
Both gsm0503_tch_a[fh]s_decode_dtx() functions accept an optional
'dtx' pointer, which is used to indicate type of a received AMR
block to the caller in DTX mode of operation. If not NULL, it's
expected to be updated by gsm0503_detect_a[fh]s_dtx_frame() every
time one of the mentioned functions is called.
However, in case of FACCH both functions return early, so the value
of dtx remains unchanged and thus FACCH frames may be misinterpreted
as AMR's special DTX frames. This is rather critical during the DTX
silence periods, when all special DTX frames (e.g. SID_UPDATE) are
being treated as SUB frames. Each unsuccessful FACCH decoding
attempt will 'poison' SUB measurements, causing unexpected RxQual-
SUB values in the Uplink measurement reports.
Fix this by resetting *dtx to AMR_OTHER in the FACCH specific path.
Change-Id: I2e6f4b748c6445725211e264ab5f3f5a2712087a
Related: SYS#5853
---
M src/coding/gsm0503_coding.c
1 file changed, 13 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/27/28127/1
diff --git a/src/coding/gsm0503_coding.c b/src/coding/gsm0503_coding.c
index 98439e3..e81bf02 100644
--- a/src/coding/gsm0503_coding.c
+++ b/src/coding/gsm0503_coding.c
@@ -2171,6 +2171,12 @@
gsm0503_tch_fr_deinterleave(cB, iB);
if (steal > 0) {
+ /* If not NULL, dtx indicates type of previously decoded TCH/AFS frame.
+ * It's normally updated by gsm0503_detect_afs_dtx_frame(), which is not
+ * reached in case of FACCH. Reset it here to avoid FACCH/F frames being
+ * misinterpreted as AMR's special DTX frames. */
+ if (dtx != NULL)
+ *dtx = AMR_OTHER;
rv = _xcch_decode_cB(tch_data, cB, n_errors, n_bits_total);
if (rv) {
/* Error decoding FACCH frame */
@@ -2633,6 +2639,13 @@
/* if we found a stole FACCH, but only at correct alignment */
if (steal > 0) {
+ /* If not NULL, dtx indicates type of previously decoded TCH/AHS frame.
+ * It's normally updated by gsm0503_detect_ahs_dtx_frame(), which is not
+ * reached in case of FACCH. Reset it here to avoid FACCH/H frames being
+ * misinterpreted as AMR's special DTX frames. */
+ if (dtx != NULL)
+ *dtx = AMR_OTHER;
+
for (i = 0; i < 6; i++) {
gsm0503_tch_burst_unmap(&iB[i * 114],
&bursts[i * 116], NULL, i >> 2);
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/28127
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I2e6f4b748c6445725211e264ab5f3f5a2712087a
Gerrit-Change-Number: 28127
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: newchange