To test, create the following event_route in your script:

event_route[tcp:closed] {
 xlogl("L_INFO", "TCP connection closed: si=$si sp=$sp conid=$conid proto=$proto\n");
}

Then connect to the server via TCP, TLS, WS, or WSS, and explicitly kill the connection between kamailio and the client using tcpkill or something similar, or alternatively, time out the TCP connection by unplugging a SIP phone or inserting IPtables rules to block traffic. You should see event_route[tcp:closed] get executed.

Please let me know if you find issues with this approach. Thanks!


Reply to this email directly or view it on GitHub.