[asterisk-dev] [svn-commits] file: branch 12 r405019 - /branches/12/res/res_pjsip_nat.c

Daniel Jenkins dan.jenkins88 at gmail.com
Tue Jan 7 11:15:09 CST 2014


On Tue, Jan 7, 2014 at 5:03 PM, Matthew Jordan <mjordan at digium.com> wrote:

> On Tue, Jan 7, 2014 at 9:27 AM, Joshua Colp <jcolp at digium.com> wrote:
> > Olle E. Johansson wrote:
> >>
> >> On 07 Jan 2014, at 15:55, SVN commits to the Digium
> >> repositories<svn-commits at lists.digium.com>  wrote:
> >>
> >>> if (endpoint->nat.rewrite_contact&&  (contact =
> >>> pjsip_msg_find_hdr(rdata->msg_info.msg, PJSIP_H_CONTACT, NULL))&& -
> >>>
> >>> (PJSIP_URI_SCHEME_IS_SIP(contact->uri) ||
> >>> PJSIP_URI_SCHEME_IS_SIPS(contact->uri))) { +
>  !contact->star&&
> >>> (PJSIP_URI_SCHEME_IS_SIP(contact->uri) ||
> >>> PJSIP_URI_SCHEME_IS_SIPS(contact->uri))) { pjsip_sip_uri *uri =
> >>> pjsip_uri_get_uri(contact->uri);
> >>>
> >>> pj_cstr(&uri->host, rdata->pkt_info.src_name);
> >>>
> >>
> >> Seems like this code assumes that SIP only have SIP: and SIPS: as
> >> URI's. We should actually be quite transparent in the schemas
> >> supported - especially proxys but also b2bua's like Asterisk. Tel:
> >> uri's are not unknown. In the security area we are discussing
> >> improved end-2-end security which may end up using a new SIP uri.
> >
> >
> > Hrm, I've been trying to think of the best place to express this
> information
> > but I'm coming up empty. I'm not sure it's something for the config
> > documentation, maybe more the wiki.
> >
> >
> >> Instead of testing with two functions for two classes of schemas a
> >> table could be used? That would be more extensible. And please
> >> implement tel: support :-)
> >
> >
> > The code above stems from PJSIP itself and is used to determine what
> > structure PJSIP has used to store the parsed URI for manipulation. I'm
> not
> > sure a table would buy us anything in this area. As a developer you would
> > still need to know what structure was used and what it looks like.
> >
>
> We probably should have an issue made to (finally) implement TEL
> support. I know PJSIP supports it, but there'd obviously be some
> subtle things that would have to change in how we make use of PJSIP.
>
> I'll make an issue for it later today.
>
> --
> Matthew Jordan
> Digium, Inc. | Engineering Manager
> 445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
> Check us out at: http://digium.com & http://asterisk.org
>
> --
> _____________________________________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> asterisk-dev mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-dev
>



I love this fix, as the issue it fixes is causing my Asterisk 12 install to
die...

https://gist.github.com/danjenkins/e604c978b2a803140dce

Any idea when the next point release will be? Is it so far off I should
just recompile against the 12 branch later on?

Dan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20140107/f68c7b38/attachment.html>


More information about the asterisk-dev mailing list