pespin submitted this change.

View Change

Approvals: Jenkins Builder: Verified laforge: Looks good to me, but someone else must approve pespin: Looks good to me, approved osmith: Looks good to me, but someone else must approve
IPSP: don't route any incoming M3UA messages in IPSP case

An IPSP is a point-to-point association, and we must not route any
such messages.

Change-Id: Iad7280619ec5814cda7a179418079048a5955976
---
M src/m3ua.c
1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/src/m3ua.c b/src/m3ua.c
index cad7889..42a9798 100644
--- a/src/m3ua.c
+++ b/src/m3ua.c
@@ -41,6 +41,7 @@
#include <osmocom/sigtran/protocol/sua.h>

#include "mtp3_hmdc.h"
+#include "mtp3_hmdt.h"
#include "xua_as_fsm.h"
#include "xua_asp_fsm.h"
#include "xua_internal.h"
@@ -667,8 +668,14 @@
xua_msg_free_tag(xua, M3UA_IEI_ROUTE_CTX);
}

+ /* an IPSP by definition is a peer-to-peer service that doesn't
+ * use a signaling gateway, and hence doesn't route messages.
+ * See RFC 4666 Section 1.4.3.4. */
/* xua ownership is passed here: */
- return mtp3_hmdc_rx_from_l2(asp->inst, xua);
+ if (asp->cfg.role == OSMO_SS7_ASP_ROLE_IPSP)
+ return mtp3_hmdt_message_for_distribution(asp->inst, xua);
+ else
+ return mtp3_hmdc_rx_from_l2(asp->inst, xua);

ret_free:
xua_msg_free(xua);

To view, visit change 42025. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-MessageType: merged
Gerrit-Project: libosmo-sigtran
Gerrit-Branch: master
Gerrit-Change-Id: Iad7280619ec5814cda7a179418079048a5955976
Gerrit-Change-Number: 42025
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin@sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge@osmocom.org>
Gerrit-Reviewer: osmith <osmith@sysmocom.de>
Gerrit-Reviewer: pespin <pespin@sysmocom.de>