<p>laforge <strong>submitted</strong> this change.</p><p><a href="https://gerrit.osmocom.org/c/libosmo-sccp/+/15868">View Change</a></p><div style="white-space:pre-wrap">Approvals:
  laforge: Looks good to me, approved
  Jenkins Builder: Verified

</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">vty: ss7: Make sure ASP has at least INET_ANY addr set if not configured in VTY<br><br>Several parts of the code expect an operative ASP to always have at<br>least one local ip addr, be it INET_ANY (NULL, 0.0.0.0) or any specific<br>IP address.<br>This allows osmo_ss7_asp_find_by_socket_addr() matching incoming<br>connectiongs against ASPs defined through VTY "asp" node with no<br>"local-ip" cmd option specified. In that case, we assume the user wants<br>it to bind/match against INET_ANY.<br><br>Related: OS#3608<br>Fixes: 80b135581909fef595d48436ab04dbcb147e3895<br>Change-Id: Id4da0c778890c90cf5bfcf0fd3a7ecf165f2a6df<br>---<br>M src/osmo_ss7_vty.c<br>1 file changed, 5 insertions(+), 0 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/src/osmo_ss7_vty.c b/src/osmo_ss7_vty.c</span><br><span>index 23607ca..fa3d5d1 100644</span><br><span>--- a/src/osmo_ss7_vty.c</span><br><span>+++ b/src/osmo_ss7_vty.c</span><br><span>@@ -1722,6 +1722,11 @@</span><br><span>      switch (vty->node) {</span><br><span>      case L_CS7_ASP_NODE:</span><br><span>                 asp = vty->index;</span><br><span style="color: hsl(120, 100%, 40%);">+          /* If no local addr was set */</span><br><span style="color: hsl(120, 100%, 40%);">+                if (!asp->cfg.local.host_cnt) {</span><br><span style="color: hsl(120, 100%, 40%);">+                    asp->cfg.local.host[0] = NULL;</span><br><span style="color: hsl(120, 100%, 40%);">+                     asp->cfg.local.host_cnt = 1;</span><br><span style="color: hsl(120, 100%, 40%);">+               }</span><br><span>            osmo_ss7_asp_restart(asp);</span><br><span>           vty->node = L_CS7_NODE;</span><br><span>           vty->index = asp->inst;</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.osmocom.org/c/libosmo-sccp/+/15868">change 15868</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.osmocom.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.osmocom.org/c/libosmo-sccp/+/15868"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: libosmo-sccp </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: Id4da0c778890c90cf5bfcf0fd3a7ecf165f2a6df </div>
<div style="display:none"> Gerrit-Change-Number: 15868 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </div>
<div style="display:none"> Gerrit-Owner: pespin <pespin@sysmocom.de> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins Builder </div>
<div style="display:none"> Gerrit-Reviewer: laforge <laforge@osmocom.org> </div>
<div style="display:none"> Gerrit-MessageType: merged </div>