Error parsing Contact like user@domain@x.x.x.x

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Put  a SIP SBC in front of your SIP server, and let bad SIP phones talk to
SIP SBC.
Some SBC will reformat bad SIP message before send to SIP server.

regards,
Gang

On Fri, Apr 3, 2009 at 10:18 PM, Alexei Kuznetsov <eofster at gmail.com> wrote:

>  On Fri, Apr 3, 2009 at 3:40 PM, Benny Prijono <bennylp at teluu.com> wrote:
> > On Thu, Apr 2, 2009 at 11:46 PM, Alexei Kuznetsov <eofster at gmail.com>
> wrote:
> >>
> >> Hi,
> >>
> >> Some SIP phones produce Contact like "user at domain@x.x.x.x". pjsip fails
> to
> >> parse such headers:
> >>
> >> 17:24:24.363 sip_transport.  Error processing 800 bytes packet from UDP
> >> 10.0.0.1:5060 : PJSIP syntax error exception when parsing '' header on
> line
> >> 11 col 36:
> >> SIP/2.0 200 OK
> >> Via: SIP/2.0/UDP 10.0.0.24:55187;rport=55187;branch=111
> >> From: "John Smith" <sip:john@xxxxxxxxxxx <sip%3Ajohn at example.com>
> >;tag=222
> >> To: "John Smith" <sip:john at example.com <sip%3Ajohn at example.com>
> >;tag=333
> >> Call-ID: 444
> >> CSeq: 555 REGISTER
> >> Expires: 300
> >> Contact: <sip:john at 10.0.0.24:55187>;expires=300
> >> Contact: <sip:john at 10.0.0.24:55175>;expires=139
> >> Contact: <sip:john at 10.0.0.24:55134>;expires=4
> >> Contact: <sip:john at example.com <sip%3Ajohn at example.com>@10.0.0.41:5070
> >;q=0.90;expires=31
> >>
> >
> > That's not valid according to the spec. Character "@" is not allowed in
> the
> > user part of URI, so it should have been escaped. FYI
> >
> > SIP-URI          =  "sip:" [ userinfo ] hostport
> >                     uri-parameters [ headers ]
> > userinfo         =  ( user / telephone-subscriber ) [ ":" password ] "@"
> > user             =  1*( unreserved / escaped / user-unreserved )
> > user-unreserved  =  "&" / "=" / "+" / "$" / "," / ";" / "?" / "/"
> > unreserved       =  alphanum / mark
> > mark             =  "-" / "_" / "." / "!" / "~" / "*" / "'"
> >                      / "(" / ")"
>
> Oh yes, I completely understand that. I'm just trying to survive in
> such cases. Other SIP phone can register with the wrong Contact on the
> other computer, but with the same credentials. And pjsip will fail to
> do its job without even cooperating with that bad SIP phone directly.
> What we get is a failure to register just because some other phone
> registered with the bad Contact somewhere. I just thought it might be
> reasonable for pjsip to survive in such situations and not to be so
> dependent on that. What do you think?
>
> Alexei
>
> _______________________________________________
> Visit our blog: http://blog.pjsip.org
>
> pjsip mailing list
> pjsip at lists.pjsip.org
> http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20090406/2f428002/attachment-0001.html>


[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux