<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Hello,<br>
    <br>
    let's keep the list on cc so other devs can participate and have
    idea of what is going on ...<br>
    <br>
    On 8/11/11 9:26 AM, Tristan Bruns wrote:
    <blockquote cite="mid:assp.0204e2103e.4E438431.8040105@decoit.de"
      type="cite">
      <meta content="text/html; charset=ISO-8859-1"
        http-equiv="Content-Type">
      <title></title>
      Hello Daniel,<br>
      <br>
      I tried using the message parser and textops to add the headers to
      the message but failed, probably because I did not manage to
      create a sip_msg struct that append_hf would update. (It worked
      when I used an existing sip_msg struct, [e.g. the one from
      sip_trace()] but not all trace-functions had access to a sip_msg
      [e.g. trace_sl_*])<br>
    </blockquote>
    <br>
    Indeed, the functions for storing the message don't have the sip_msg
    struct available. I was referring to parsing of received messages
    (the mirrored traffic from other kamailios), where would be safer to
    use the parser -- if there will be another proxy in between
    mirroring proxy and storage proxy, it can add headers in between the
    X-Siptrace-..., breaking the read.<br>
    <br>
    Anyhow, that is very unlikely -- for the I will go with your patches
    and update afterwards, when it is more time for it.<br>
    <br>
    Cheers,<br>
    Daniel<br>
    <br>
    <blockquote cite="mid:assp.0204e2103e.4E438431.8040105@decoit.de"
      type="cite"> <br>
      After that, I did not consider to use the message parser to
      extract the headers.<br>
      <br>
      Regards, Tristan<br>
      <br>
      <br>
      Am 09.08.2011 16:26, schrieb Daniel-Constantin Mierla:
      <blockquote cite="mid:4E41437A.7080708@gmail.com" type="cite">
        <meta content="text/html; charset=ISO-8859-1"
          http-equiv="Content-Type">
        Hi Tristan,<br>
        <br>
        I was looking at the patches and the only thing I want to
        discuss is related to the operations with headers.<br>
        <br>
        You don't use the internal SIP parser, with it you can get the
        end of headers position as well as you can iterate through the
        list of headers and match by name, then take the body and fill
        local variables.<br>
        <br>
        In the patches (3/5) you use sscanf(...). I would go for using
        the parser, since it is safer in long term. Do you had any
        special reason to go with own kind of parser for SIP and
        headers?<br>
        <br>
        Cheers,<br>
        Daniel<br>
        <br>
        On 8/5/11 10:17 AM, Tristan Bruns wrote:
        <blockquote cite="mid:assp.019835d507.4E3BA735.80908@decoit.de"
          type="cite">Hello OpenSER/Kamailio developers, <br>
          <br>
          we implemented some additional features in siptrace. <br>
          The main objective was to have multiple kamailios send
          duplicates <br>
          of sent/received packets to one logging server (also running
          kamailio). <br>
          We did not just set db_url to the logging server because of <br>
          performance concerns. <br>
          <br>
          The attached patches contain our commits. <br>
          I hope that you find them useful. <br>
          <br>
          Viele Gr&uuml;&szlig;e / Best regards, <br>
          Tristan Bruns (DECOIT GmbH) <br>
          <br>
          <br>
          <br>
          0001-modules_k-siptrace-separately-store-to-db-and-or-sen.patch

          <br>
          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; modules_k/siptrace: separately store to db and/or send
          duplicate <br>
          <br>
          0002-modules_k-siptrace-Add-trace_to_database-configurati.patch

          <br>
          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; modules_k/siptrace: Add trace_to_database configuration
          parameter <br>
          <br>
          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Adding configuration parameter to disable writing to the
          database. <br>
          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; We can use this to only duplicate the SIP messages
          without storing <br>
          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; them in our database. <br>
          <br>
          0003-modules_k-siptrace-Add-x-headers-feature.patch <br>
          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; modules_k/siptrace: Add "x-headers" feature <br>
          <br>
          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; The "x-headers" feature stores the fromip, toip, method
          and <br>
          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; direction in the message body (using X-* headers). This
          allows to <br>
          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; transmit them using duplicate_uri from one kamailio to
          an other. <br>
          <br>
          0004-modules_k-siptrace-Add-column-time_us.patch <br>
          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; modules_k/siptrace: Add column time_us <br>
          <br>
          0005-modules_k-siptrace-Add-time-to-x-headers.patch <br>
          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; modules_k/siptrace: Add time to x-headers <br>
          <br>
          <br>
          <br>
          <br>
          <fieldset class="mimeAttachmentHeader"></fieldset>
          <br>
          <pre wrap="">_______________________________________________
sr-dev mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:sr-dev@lists.sip-router.org">sr-dev@lists.sip-router.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev</a>
</pre>
        </blockquote>
        <br>
        <pre class="moz-signature" cols="72">-- 
Daniel-Constantin Mierla -- <a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://www.asipto.com">http://www.asipto.com</a>
Kamailio Advanced Training, Oct 10-13, Berlin: <a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://asipto.com/u/kat">http://asipto.com/u/kat</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://linkedin.com/in/miconda">http://linkedin.com/in/miconda</a> -- <a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://twitter.com/miconda">http://twitter.com/miconda</a></pre>
      </blockquote>
      <br>
    </blockquote>
    <br>
    <pre class="moz-signature" cols="72">-- 
Daniel-Constantin Mierla -- <a class="moz-txt-link-freetext" href="http://www.asipto.com">http://www.asipto.com</a>
Kamailio Advanced Training, Oct 10-13, Berlin: <a class="moz-txt-link-freetext" href="http://asipto.com/u/kat">http://asipto.com/u/kat</a>
<a class="moz-txt-link-freetext" href="http://linkedin.com/in/miconda">http://linkedin.com/in/miconda</a> -- <a class="moz-txt-link-freetext" href="http://twitter.com/miconda">http://twitter.com/miconda</a></pre>
  </body>
</html>