[Serusers] route based on src IP address?

info at beeplove.com info at beeplove.com
Wed Apr 27 22:36:49 CEST 2005


if (src_ip == 192.168.0.0/24) {
    rewritehostport("gw1.gateway.com:5060");
} else {
    rewritehostport("gw2.gateway.com:5060");
}


Hope this will help.

Thanks,
Mohammad




Original Message:
-----------------
From: Juan Priotti jpriotti at gmail.com
Date: Wed, 27 Apr 2005 17:29:10 -0300
To: serusers at iptel.org
Subject: [Serusers] route based on src IP address?


I have a simple question:

Is it possible to route a sip call based on source IP address? For 
example, if a call if originated from UA1 I would need the call to be 
routed to gateway1 but if the call was originated on UA2, gateway2 
should be used (UA1 has different IP address than UA2). If possible, 
which is the config I need to use in ser.cfg?

Thanks in advance

Juan

_______________________________________________
Serusers mailing list
Serusers at iptel.org
http://mail.iptel.org/mailman/listinfo/serusers

--------------------------------------------------------------------
mail2web - Check your email from the web at
http://mail2web.com/ .





More information about the sr-users mailing list