Module: kamailio
Branch: 5.6
Commit: 5154f20964e08d2853bbf96afdeecceac8fe7650
URL:
https://github.com/kamailio/kamailio/commit/5154f20964e08d2853bbf96afdeecce…
Author: Stefan Mititelu <stefan-cristian.mititelu(a)1and1.ro>
Committer: Stefan Mititelu <stefan-cristian.mititelu(a)1and1.ro>
Date: 2023-07-05T13:54:29+03:00
ims_qos: check and log for NULL sessionId
(cherry picked from commit 1b291315b43da1148cee5f3821ddbe49b0c86b7f)
---
Modified: src/modules/ims_qos/rx_aar.c
---
Diff:
https://github.com/kamailio/kamailio/commit/5154f20964e08d2853bbf96afdeecce…
Patch:
https://github.com/kamailio/kamailio/commit/5154f20964e08d2853bbf96afdeecce…
---
diff --git a/src/modules/ims_qos/rx_aar.c b/src/modules/ims_qos/rx_aar.c
index dbc2aebaeb6..287df6d9894 100644
--- a/src/modules/ims_qos/rx_aar.c
+++ b/src/modules/ims_qos/rx_aar.c
@@ -149,6 +149,11 @@ void async_aar_callback(int is_timeout, void *param, AAAMessage *aaa,
long elaps
LM_DBG("Success, received code: [%i] from PCRF for AAR request\n",
cdp_result);
counter_inc(ims_qos_cnts_h.successful_media_aars);
+ if(!aaa->sessionId) {
+ LM_ERR("NULL AAA sessionId from PCRF!\n");
+ goto error;
+ }
+
LM_DBG("Auth session ID [%.*s]", aaa->sessionId->data.len,
aaa->sessionId->data.s);
if(!data->aar_update) {
@@ -286,6 +291,12 @@ void async_aar_reg_callback(int is_timeout, void *param, AAAMessage
*aaa, long e
create_return_code(result);
goto done;
}
+
+ if(!aaa->sessionId) {
+ LM_ERR("NULL AAA sessionId from PCRF!\n");
+ goto error;
+ }
+
//need to set Rx auth data to say this session has been successfully opened
//This is used elsewhere to prevent acting on termination events when the session
has not been opened
//getting auth session