### Description I'm trying to check if the incoming message is from the dispatcher hosts using KEMI function ds_is_from_list from a lua script:
``` if KSR.dispatcher.ds_is_from_list("-1", "2") then KSR.info("Dispatcher List \n"); return "list" end ```
I'm getting always true if when the source IP of the request is from a different network: ``` /usr/local/sbin/kamcmd dispatcher.list { NRSETS: 1 RECORDS: { SET: { ID: 1 TARGETS: { DEST: { URI: sip:127.0.0.1:5060 FLAGS: AX PRIORITY: 0 LATENCY: { AVG: 0 STD: 0 EST: 0 MAX: 0 TIMEOUT: 0 } } } } } } ```
SIP Request: ``` [info] [sipexer.go:1578] main.SIPExerDialogLoop(): local socket address: 172.16.22.12:45379 (udp) [info] [sipexer.go:1579] main.SIPExerDialogLoop(): local via address: 172.16.22.12:45379 [info] [sipexer.go:1580] main.SIPExerDialogLoop(): sending to udp 192.168.1.1:5060: [[--- OPTIONS sip:192.168.1.1:5060 SIP/2.0 Via: SIP/2.0/UDP 172.16.22.12:45379;rport;branch=z9hG4bKSG.70e3db71-1902-40aa-898b-ba582eefb784 From: sip:alice@localhost;tag=4f0ad3f3-1008-49dd-8177-7913ab12cf38 To: sip:bob@localhost Call-ID: 4f538d14-e8e4-495b-818a-c595f4457585 CSeq: 977235 OPTIONS Date: Tue, 01 Oct 2024 10:51:14 IST User-Agent: SIPExer v1.1.0 Max-Forwards: 10 Content-Length: 0 ```
Works ok when I'm using this function from the default configuration file: ``` if (ds_is_from_list("-1", "2")) { xlogl("L_INFO","Dispatcher List\n"); exit; } ```
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
``` version: kamailio 5.8.3 (x86_64/linux) ab3530-dirty ```
* **Operating System**:
``` 5.14.0-508.el9.x86_64 ```