[sr-dev] get dispatcher selected ip
Federico Cabiddu
federico.cabiddu at gmail.com
Tue Feb 17 09:45:53 CET 2015
Hi,
1. get the ip address of the server selected by the dispatcher for the
> current session.
>
After calling one of the dispatcher selection functions (ds_select_dst,
ds_next_dst and so on...) you'll have the selected gateway in the $du
variable.
2. check if the request ip address is in the dispatcher list of servers
>
Use ds_is_from_list (
http://www.kamailio.org/docs/modules/devel/modules/dispatcher.html#dispatcher.f.ds_is_from_list)
for this
> 3. check if the request ip address is in the trusted server list
>
You can use permissions module and its allow_* functions (
http://www.kamailio.org/docs/modules/devel/modules/permissions.html)
> 4. get the ip address of the selected lcr gateway server
>
As for 1), you can get the ip address of the gateway from the $du variable.
> I cannot seem to find the functions for these things in the documentation.
> Please help.
>
> Regards
> Andrew Okri
>
Regards,
Federico
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-dev/attachments/20150217/5a33bdd3/attachment-0001.html>
More information about the sr-dev
mailing list