<div dir="ltr">Dear Sir,<div>           In case of presence the condition which you mentioned works  (i.e <span style="font-size:13px;font-family:arial,sans-serif"> if($hu=~"^/</span><span class="" style="font-size:13px;font-family:arial,sans-serif">xcap</span><span style="font-size:13px;font-family:arial,sans-serif">-root")  { }) but when i want to capture the authentication request from sipml5 client(SIP over websocket), the conditions does't match(e.g </span><span style="font-family:arial,sans-serif;font-size:13px">if($hu=~"^/webrtc") or </span><span style="font-family:arial,sans-serif;font-size:13px">if($hu=~"^/sip:" etc). When i tried described as follows  within XTTP request block  kamailio.cfg gives parsing error</span></div>
<div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px">  </span><span style="font-size:13px;font-family:arial,sans-serif">    if($hu=~"^/</span><span class="" style="font-size:13px;font-family:arial,sans-serif">xcap</span><span style="font-size:13px;font-family:arial,sans-serif">-root") {</span></div>
<div class="im" style="font-family:arial,sans-serif;font-size:13px"><br>        # handle <span class="">xcap</span><br>    }</div><div class="im" style="font-family:arial,sans-serif;font-size:13px"><br></div><div class="im" style="font-family:arial,sans-serif;font-size:13px">
<span style="color:rgb(34,34,34)">    if(!($hu=~"^/</span><span class="">xcap</span><span style="color:rgb(34,34,34)">-root")) {</span><div class="im"><br>        # handle <span class="">another</span><br>    }</div>
<div class="im"><br></div><div class="im">where is the problem I can't solve. Pls give some ideas.</div><div class="im"><br></div><div class="im">Rupayan dutta</div></div><div><span style="font-family:arial,sans-serif;font-size:13px"><br>
</span></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Aug 1, 2013 at 2:25 PM, Daniel-Constantin Mierla <span dir="ltr"><<a href="mailto:miconda@gmail.com" target="_blank">miconda@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
  
    
  
  <div text="#000000" bgcolor="#FFFFFF">
    the conditions in the example of previous email were negated, so
    they should be:<br>
    <br>
        if($hu=~"^/webrtc") {<br>
            # handle webrtc<br>
        }<br>
    <br>
        if($hu=~"^/xcap-root") {<div class="im"><br>
            # handle xcap<br>
        }<br>
    <br>
    Cheers,<br>
    Daniel<br>
    <br>
    </div><div><div class="h5"><div>On 8/1/13 10:54 AM, Daniel-Constantin
      Mierla wrote:<br>
    </div>
    <blockquote type="cite">
      
      Hello,<br>
      <br>
      one way is to use different base uri for each service and decide
      based on it, for example:<br>
      <br>
          if(! ($hu=~"^/webrtc")) {<br>
              # handle webrtc<br>
          }<br>
      <br>
          if(! ($hu=~"^/xcap-root")) {<br>
              # handle xcap<br>
          }<br>
      <br>
      Cheers,<br>
      Daniel<br>
      <br>
      <div>On 8/1/13 9:46 AM, Rupayan Dutta
        wrote:<br>
      </div>
      <blockquote type="cite">
        <div dir="ltr">Dear Sir,
          <div>          <span style="font-family:arial,sans-serif;font-size:13px">I have
              kamailio 4.0.2 installed with the websockets module and it
              is working fine.Now I want to enable presence with
              XCAP.How can I do that.I have gone through the steps
              defined in </span><a href="http://kb.asipto.com/kamailio:presence:k31-made-simple" target="_blank">http://kb.asipto.com/kamailio:presence:k31-made-simple</a>.
            But I am little bit confused because both websocket and XCAP
            route configuration is using <span>event_route</span><span>[</span><span>xhttp</span><span>:</span><span>request</span><span>].</span></div>
          <div><span><br>
            </span></div>
          <div><span>Pls

              help to modify kamailio.cfg file</span></div>
        </div>
        <br>
        <fieldset></fieldset>
        <br>
        <pre>_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
<a href="mailto:sr-users@lists.sip-router.org" target="_blank">sr-users@lists.sip-router.org</a>
<a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a>
</pre>
      </blockquote>
      <br>
      <pre cols="72">-- 
Daniel-Constantin Mierla - <a href="http://www.asipto.com" target="_blank">http://www.asipto.com</a>
<a href="http://twitter.com/#%21/miconda" target="_blank">http://twitter.com/#!/miconda</a> - <a href="http://www.linkedin.com/in/miconda" target="_blank">http://www.linkedin.com/in/miconda</a>
</pre>
    </blockquote>
    <br>
    <pre cols="72">-- 
Daniel-Constantin Mierla - <a href="http://www.asipto.com" target="_blank">http://www.asipto.com</a>
<a href="http://twitter.com/#!/miconda" target="_blank">http://twitter.com/#!/miconda</a> - <a href="http://www.linkedin.com/in/miconda" target="_blank">http://www.linkedin.com/in/miconda</a>
</pre>
  </div></div></div>

<br>_______________________________________________<br>
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<br>
<a href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a><br>
<a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a><br>
<br></blockquote></div><br></div>