<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;
        font-family:"Calibri","sans-serif";}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal>Hello,<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>I have come across this behavior in Kamailio 3.1.5 version.<o:p></o:p></p><p class=MsoNormal>The proxy is behind a Firewall and uses the advertised IP to communicate to sipclients.<o:p></o:p></p><p class=MsoNormal>I have used the &#8220;dlg_match_mode&#8221;, as the record_route_preset() does not include the DID during call initiation.<o:p></o:p></p><p class=MsoNormal style='text-indent:.5in'>modparam(&quot;dialog&quot;, &quot;dlg_match_mode&quot;, 2)<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>I&#8217;m also using pua_dialoginfo to notify users about the &#8220;Event:dialog&#8221;. I have used the attached patch to make pua_dialog info aware of the dialog<o:p></o:p></p><p class=MsoNormal>I see that the dialog is being created, and the pua_dialoginfo publishes with state &#8220;trying&#8221; and &#8220;confirmed&#8221;. <o:p></o:p></p><p class=MsoNormal>When the call is cancelled/408 request is generated, the pua_dialoginfo generates the xml with state=terminated.<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>But when the call is answered, the dialog module updates the dialog to state=4, according to the documentation mentioned below state=4 --&gt; Terminated.<o:p></o:p></p><p class=MsoNormal>I&#8217;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).<o:p></o:p></p><p class=MsoNormal>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 &nbsp;termination and the xml is never updated.<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>I have attached a log for a call, please find the attached document.<o:p></o:p></p><p class=MsoNormal>I have come across a documentation about dialog module:<o:p></o:p></p><p class=MsoNormal>http://www.kamailio.org/dokuwiki/doku.php/modules-new-design:dialog-module-design<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>Regards<o:p></o:p></p><p class=MsoNormal>Gnaneshwar<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p></div></body></html>