laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-hnbgw/+/37530?usp=email )
Change subject: kpi_ranap: Avoid null pointer de-ref during HNB shutdown
......................................................................
kpi_ranap: Avoid null pointer de-ref during HNB shutdown
In the downlink path, we cannot assume map->hnb_ctx is always
non-NULL. If the HNB has just disconnected, it might be NULL,
while we're still processing downlink messages from the CN which
were sent by it before it realized that HNB was gone.
Closes: SYS#7010
Change-Id: I9a304b9e0cbc18dbf7b699f4aae6b91ca0c16173
---
M src/osmo-hnbgw/kpi_ranap.c
1 file changed, 25 insertions(+), 0 deletions(-)
Approvals:
pespin: Looks good to me, but someone else must approve
fixeria: Looks good to me, approved
Jenkins Builder: Verified
diff --git a/src/osmo-hnbgw/kpi_ranap.c b/src/osmo-hnbgw/kpi_ranap.c
index 59631cf..d731c5f 100644
--- a/src/osmo-hnbgw/kpi_ranap.c
+++ b/src/osmo-hnbgw/kpi_ranap.c
@@ -179,6 +179,13 @@
void kpi_ranap_process_dl(struct hnbgw_context_map *map, ranap_message *ranap)
{
+ if (map->hnb_ctx == NULL) {
+ /* This can happen if the HNB has disconnected and we are processing downlink messages
+ * from the CN which were already in flight before the CN side has realized the HNB
+ * is gone. */
+ return;
+ }
+
switch (ranap->procedureCode) {
case RANAP_ProcedureCode_id_RAB_Assignment: /* RAB ASSIGNMENT REQ (8.2) */
kpi_ranap_process_dl_rab_ass_req(map, ranap);
@@ -405,6 +412,9 @@
void kpi_ranap_process_ul(struct hnbgw_context_map *map, ranap_message *ranap)
{
+ /* we should never be processing uplink messages from a non-existant HNB */
+ OSMO_ASSERT(map->hnb_ctx);
+
switch (ranap->procedureCode) {
case RANAP_ProcedureCode_id_RAB_Assignment: /* RAB ASSIGNMENT REQ (8.2) */
kpi_ranap_process_ul_rab_ass_resp(map, ranap);
--
To view, visit https://gerrit.osmocom.org/c/osmo-hnbgw/+/37530?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-hnbgw
Gerrit-Branch: master
Gerrit-Change-Id: I9a304b9e0cbc18dbf7b699f4aae6b91ca0c16173
Gerrit-Change-Number: 37530
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: iedemam <michael(a)kapsulate.com>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: merged
Attention is currently required from: pespin.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37544?usp=email )
Change subject: sgsn: expected-results.xml: Add missing TC_sgsn_context_req_{in,out}
......................................................................
Patch Set 2:
(1 comment)
Patchset:
PS2:
We do not expect those to pass yet (patches not merged).
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37544?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I2579958bbf8c28b72e58174e60634ca77c71dfee
Gerrit-Change-Number: 37544
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-CC: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 22 Jul 2024 19:23:38 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: daniel, osmith, pespin.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37545?usp=email )
Change subject: sgsn: Move BSSGP_ConnHdlr code to its own file
......................................................................
Patch Set 1: Code-Review+1
(1 comment)
File sgsn/BSSGP_ConnHdlr.ttcn:
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37545/comment/5d88ac4e_0aaf…
PS1, Line 902: }
"No newline at end of right file."
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37545?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I0591cab8cca5195b8648920d5f79acc536a4efac
Gerrit-Change-Number: 37545
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 22 Jul 2024 19:22:34 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: dexter, laforge.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/37543?usp=email )
Change subject: pySim-shell: add "fsdump" command
......................................................................
Patch Set 1: Code-Review+1
(3 comments)
File pySim-shell.py:
https://gerrit.osmocom.org/c/pysim/+/37543/comment/d78d413d_69d5eb82
PS1, Line 731: # the EF we want to export. To maintain consistency we will then
tabs vs spaces
https://gerrit.osmocom.org/c/pysim/+/37543/comment/cf7c3f6e_de14d3ad
PS1, Line 784: result[0])
don't you need to do `str()` like above?
https://gerrit.osmocom.org/c/pysim/+/37543/comment/17ebafdc_3dab3e56
PS1, Line 790: else
cosmetic: `else` is not needed after `break` or `return`
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/37543?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: Ib179f57bc04d394efe11003ba191dca6098192d3
Gerrit-Change-Number: 37543
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 22 Jul 2024 19:19:15 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment