[SR-Users] Configuring Kamailio as a "VoIP traffic reflector"

Daniel Tryba d.tryba at pocos.nl
Thu Mar 30 09:45:50 CEST 2017

On Wed, Mar 29, 2017 at 09:57:02PM +0900, Tahiro Hashizume wrote:
> B.)Kamailio listens on five IP addresses on dummyN which has
> (N=0-4, so dummy0 has, for example) making
> five SIP+RTP sessions to the same remote host to appear as if they are
> from five different hosts - so that a single instance of Asterisk
> running on debian may be registered (through Kamailio) on the same
> remote host by using five different accounts and source IP addresses.
> Should be simple, but so far cannot find good sources of reference. I
> need your advice.

Snipping your long story, summarized to: sipserver only accepts 1
connection from 1 ipadress (which is kind of strange, have you tried 1
ipaddress and different source ports?) and you want to make multiple
from 1 machine (with multiple ipadresses).

If my understanding is correct the solution is simple, in kamailio use
force_send_socket to send requests to the sipserver from different
adresses ( 

The hard part is how you will differentiate the REGISTERS from asterisk
to the sipserver. The easiest way I can think of right now is to listen
on multiple ports with kamailio and tell the kamailio peers to connect
to these in a unique way.

So in kamailio it would something like:
else if($Rp=="5071")
else if(...)


More information about the sr-users mailing list