<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2745.2800" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Can somebody send me working accounting with 
statefull forwarding ser.cfg? </FONT></DIV>
<BLOCKQUOTE 
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
  <DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
  <DIV 
  style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B> 
  <A title=pi@hostmates.com href="mailto:pi@hostmates.com">Pavel Siderov</A> 
  </DIV>
  <DIV style="FONT: 10pt arial"><B>To:</B> <A title=serusers@lists.iptel.org 
  href="mailto:serusers@lists.iptel.org">serusers@lists.iptel.org</A> </DIV>
  <DIV style="FONT: 10pt arial"><B>Sent:</B> Wednesday, October 20, 2004 1:00 
  PM</DIV>
  <DIV style="FONT: 10pt arial"><B>Subject:</B> [Serusers] Forwarding to pstn, 
  accounting problem</DIV>
  <DIV><BR></DIV>
  <DIV><FONT face=Arial size=2>After I made my accounting up and working I've 
  changed something and it's not working now would you help me please. 
  </FONT></DIV>
  <DIV><FONT face=Arial size=2>The problem is that when I forward the call to 
  pstn gateway when user closes the line the "BYE" request is not written 
  </FONT></DIV>
  <DIV><FONT face=Arial size=2>in the database - it exists but it's not written 
  - here it is</FONT></DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2>&nbsp;3(17265) SIP 
  Request:<BR>&nbsp;3(17265)&nbsp; method:&nbsp; 
  &lt;BYE&gt;<BR>&nbsp;3(17265)&nbsp; uri:&nbsp;&nbsp;&nbsp;&nbsp; 
  &lt;sip:pavel@192.168.2.111:19454&gt;<BR>&nbsp;3(17265)&nbsp; version: 
  &lt;SIP/2.0&gt;<BR>&nbsp;3(17265) parse_headers: flags=1<BR>&nbsp;3(17265) 
  get_hdr_field: cseq &lt;CSeq&gt;: &lt;1&gt; &lt;BYE&gt;<BR></FONT></DIV>
  <DIV><FONT face=Arial size=2>Here is part of my ser.cfg</DIV></FONT>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2>modparam("acc", "log_flag", 1)<BR>modparam("acc", 
  "log_fmt", "cdfimorstup")<BR>modparam("acc", "db_url", 
  "mysql://user:pass@192.168.2.113:3306/ser")<BR>modparam("acc", "db_flag", 
  1)<BR>modparam("acc", "db_missed_flag", 1)<BR>modparam("acc", 
  "log_missed_flag", 1)<BR>#modparam("acc", "report_cancels", 
  1)<BR>modparam("acc", "report_ack", 1)</FONT></DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2>.......</FONT></DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if 
  (uri=~"^sip:[0-9]*@sip.mydomain.com") 
  {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  if (is_user_in("From", 
  "pstn")){<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  rewritehost("pstn_gw_ip");<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb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bsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  };<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  break;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  };</FONT></DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2>What's is the problem please help me. 
  </FONT></DIV>
  <DIV><FONT face=Arial size=2>Thanks in advance!</FONT></DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2>Pavel Siderov</FONT></DIV>
  <P>
  <HR>

  <P></P>_______________________________________________<BR>Serusers mailing 
  list<BR>serusers@lists.iptel.org<BR>http://lists.iptel.org/mailman/listinfo/serusers<BR></BLOCKQUOTE></BODY></HTML>