[SR-Users] SIP contact header question

Robert Johnson robert.j at bendtel.com
Fri Mar 3 02:03:51 CET 2017


I seem to recall reading something stating that you shouldn't modify the 
contact header - But, I can't find the text.

Might suggest adding a Record-Route header instead of re-writing the 
contact header?

I'm curious as to what the list has to say about this question, I've 
considered doing the same thing.

On 03/02/2017 04:53 PM, Jack Davis wrote:
> Greetings,
>
> I have a general question about the usage of SIP contact headers in the
> context of using Kamailio as a SIP proxy.
>
>
> ________________________________
>
> [  A  ] --> [  Kamailio  B ]  ---> [  C ]
>
> Node A originates a SIP invite, containing a valid via header and URI
> while setting the contact address to a user at itself and delivers it to
> Kamailio B which is acting as a SIP proxy.
>
> Kamailio B then uses dispatcher routing to direct the Invite to node C,
> adding a via line with its own information as well as a record-route
> header with its own proxy information but retaining the same contact
> address from A.
>
> Node C establishes the call and then sends a re-invite to the Kamailio B
> proxy which is in turn sent to Node A. Node A responds with a 200 OK
>
> The problem arises when Node C tries to send an Ack in response to this
> 200 OK. The ack is being sent to the Contact address, rather than the
> routing already established in the initial dialog.
>
> ________________________________
>
> My question is: should kamailio be rewriting this contact address with
> its own? Is that the best practice? My understanding is that the contact
> header is more so related to future requests within the same dialog ONLY
> when a record-route is not used.
>
> I would appreciate any clarification on the RFC or best practices in
> this scenario.
>
> Thank you,
> Jack Davis
>
>
> _______________________________________________
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users at lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>



More information about the sr-users mailing list