pespin has uploaded this change for review. (
https://gerrit.osmocom.org/c/libosmo-sigtran/+/40586?usp=email )
Change subject: vty: Make sure user doesn't configure AS in ASP role with a non-local
PC as routing-key
......................................................................
vty: Make sure user doesn't configure AS in ASP role with a non-local PC as
routing-key
AS in ASP mode doesn't expect to route incomign traffic to other nodes.
They are expected to announce its routing-key (local PC) to the SG so it
knows how to reach it and in turn announce (un)availability to other
SG/ASPs in the network.
Change-Id: Ibbf990fd8dcbdc67ebc4118597b34a5767320cf6
---
M src/ss7_as_vty.c
1 file changed, 9 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-sigtran refs/changes/86/40586/1
diff --git a/src/ss7_as_vty.c b/src/ss7_as_vty.c
index 0b0ddc1..7a01e46 100644
--- a/src/ss7_as_vty.c
+++ b/src/ss7_as_vty.c
@@ -581,6 +581,15 @@
struct osmo_ss7_as *as = vty->index;
vty->node = L_CS7_NODE;
vty->index = as->inst;
+
+ /* Config sanity checks: */
+
+ /* AS in ASP role should be configured with a local PC which they can
+ * then announce using RKM: */
+ if (ss7_as_get_local_role(as) == OSMO_SS7_ASP_ROLE_ASP &&
+ !osmo_ss7_pc_is_local(as->inst, as->cfg.routing_key.pc))
+ vty_out(vty, "%% AS with local role ASP should have a local PC configured in its
routing-key. Fix your config!%s", VTY_NEWLINE);
+
return 0;
}
--
To view, visit
https://gerrit.osmocom.org/c/libosmo-sigtran/+/40586?usp=email
To unsubscribe, or for help writing mail filters, visit
https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newchange
Gerrit-Project: libosmo-sigtran
Gerrit-Branch: master
Gerrit-Change-Id: Ibbf990fd8dcbdc67ebc4118597b34a5767320cf6
Gerrit-Change-Number: 40586
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>