<div dir="ltr">Hi Alex,<div>I had the same problem as you and I couldn't find a way to selectively reply to via.</div><div>What I ended up doing is the following dirty trick...</div><div>Before a transaction is created for the processed message I do:</div><div><br></div><div>if (SOME CONDITION) {</div>        remove_hf_value("Via[-1].rport");<br>        msg_apply_changes();<br>}<div><br></div><div>For sure it would be better to be able to selectively set the reply_to_via behavior.</div><div><br></div><div>Hope this helps.</div><div><br></div><div>Cheers,</div><div><br></div><div>Federico</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Sep 22, 2016 at 6:11 PM, Alex Balashov <span dir="ltr"><<a href="mailto:abalashov@evaristesys.com" target="_blank">abalashov@evaristesys.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 09/22/2016 10:55 AM, Daniel Tryba wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
force_rport seems to override any rport available in via, so reply_to_via<br>
has no additional effects.<br>
</blockquote>
<br></span>
Thanks, that was helpful. But so, if force_rport() is not used, do I need reply_to_via=1 in order to have replies go back to the declared port in the Via rather than the received source port (as would be mandated by the presence of client-injected rport)?<br>
<br>
As for trusting client headers, I strongly agree. Unfortunately, sometimes business requirements collide with our philosophies.<span class="im HOEnZb"><br>
<br>
-- <br>
Alex Balashov | Principal | Evariste Systems LLC<br>
<br>
Tel: <a href="tel:%2B1-706-510-6800" value="+17065106800" target="_blank">+1-706-510-6800</a> (direct) / <a href="tel:%2B1-800-250-5920" value="+18002505920" target="_blank">+1-800-250-5920</a> (toll-free)<br>
Web: <a href="http://www.evaristesys.com/" rel="noreferrer" target="_blank">http://www.evaristesys.com/</a>, <a href="http://www.csrpswitch.com/" rel="noreferrer" target="_blank">http://www.csrpswitch.com/</a><br>
<br></span><div class="HOEnZb"><div class="h5">
______________________________<wbr>_________________<br>
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<br>
<a href="mailto:sr-users@lists.sip-router.org" target="_blank">sr-users@lists.sip-router.org</a><br>
<a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank">http://lists.sip-router.org/cg<wbr>i-bin/mailman/listinfo/sr-user<wbr>s</a><br>
</div></div></blockquote></div><br></div>