[OpenSIPS-Users] Local Route Socket

Samuel Anderson sanderson at ArnoldMagnetics.com
Tue Apr 14 16:41:10 EST 2020


Hi All,

I know you're unable to do routing or signaling in the local route, so I'm hoping someone can help me think of a workaround.

My OpenSIPS proxy has 2 IP addresses on the LAN and 1 on the WAN. When a SIP trunk sends an invite to my proxy, it forwards that invite out a specific LAN IP address, so Asterisk recognizes it as from the PSTN. When an external UAC sends a registration request to the proxy, it's forwarded to Asterisk from the other LAN IP address, so Asterisk recognizes it as a UAC to authenticate. I use the mid_registrar module in OpenSIPS to save the location of the UAC.

The problem is if the UAC becomes unresponsive and the max_pings_lost threshold of the nathelper module is reached, OpenSIPS sends a registration with an expiration of 0 to Asterisk. However, it's sent with the wrong source IP address, and Asterisk does not recognize it as an AOR to update.

I've tried modifying the local_route to change the $fs variable, but this does not work.

local_route {

                if (is_method("REGISTER")) {
                                #Asterisk is expecting Registrations from UAC phones to come from 10.x.x.x
                                $fs = "udp:10.x.x.x:5060";
                }


}

Thank you,

-Sam

This message (including any attachments) is intended only for
the use of the individual or entity to which it is addressed and
may contain information that is non-public, proprietary,
privileged, confidential, and exempt from disclosure under
applicable law or may constitute as attorney work product.
If you are not the intended recipient, you are hereby notified
that any use, dissemination, distribution, or copying of this
communication is strictly prohibited. If you have received this
communication in error, notify us immediately by telephone and
(i) destroy this message if a facsimile or (ii) delete this message
immediately if this is an electronic communication.

Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20200414/a090f57e/attachment-0001.html>


More information about the Users mailing list