Hello,
I have come across this behavior in Kamailio 3.1.5 version.
The proxy is behind a Firewall and uses the advertised IP to communicate to sipclients.
I have used the “dlg_match_mode”, as the record_route_preset() does not include the DID during call initiation.
modparam("dialog", "dlg_match_mode", 2)
I’m also using pua_dialoginfo to notify users about the “Event:dialog”. I have used the attached patch to make pua_dialog info aware of the dialog
I see that the dialog is being created, and the pua_dialoginfo publishes with state “trying” and “confirmed”.
When the call is cancelled/408 request is generated, the pua_dialoginfo generates the xml with state=terminated.
But when the call is answered, the dialog module updates the dialog to state=4, according to the documentation mentioned below state=4 --> Terminated.
I’m not aware of the event types that fires the state to termination (I have not found the documentation about events in the dialog module).
When a BYE is received to the same call, the BYE is processed and the dialog is cleared from the memory. But the pua_dialoginfo never gets the callback for the termination and the xml is never updated.
I have attached a log for a call, please find the attached document.
I have come across a documentation about dialog module:
http://www.kamailio.org/dokuwiki/doku.php/modules-new-design:dialog-module-design
Regards
Gnaneshwar