[SIPForum-discussion] Codec Prefrence Option

Shakil, Rashid rshakil at covad.com
Fri May 16 20:41:21 UTC 2008


Manpreet,

 

Thanks for the comprehensive reply. The goal which is to negotiate media
over to G729 and by reading the specs I came to the conclusion that the
only way I can avoid the RE-INVITE is by answering the specific codec in
my case 729 only with 200 OK.

 

Regards,

 

Rashid Shakil.

 

-----Original Message-----
From: Manpreet Singh [mailto:msingh at ibasis.net] 
Sent: Friday, May 16, 2008 4:13 PM
To: Shakil, Rashid; discussion at sipforum.org
Subject: RE: [SIPForum-discussion] Codec Prefrence Option

 

Rashid

 

The flow is valid and usually what the offerer do also. Check section
10.2 of rfc 3264 and you will get your answer. When the answer carries a
list of codec, the original offerer would "usually" send a new offer
with a single codec to negotiate down to one. This is usually done when
the UAS wants to include all in the answer and let offerer decide what
it wants/prefers. The preference in the 200OK doesnt drive the codec
selection but what comes in INVITE or offer does. ( in your case )
Answer is the preference local to answerer but offerer picks the
preference.

 

In SIP, the offerer preference takes precedence. In H323 world, the so
called answerer preference takes precedence. Its the recommended way. In
your case if you include all codecs, it would mean your switch should be
ready to listen on those media streams anytime in the session. Not sure
if thats what your intention is? So if you want to use your preferred
one, I would say only include one media stream for simplicity in the
answer.

 

>From spec something about preference.

 

 Although the answerer MAY list the formats in their desired order of
   preference, it is RECOMMENDED that unless there is a specific reason,
   the answerer list formats in the same relative order they were
   present in the offer.  In other words, if a stream in the offer lists
   audio codecs 8, 22 and 48, in that order, and the answerer only
   supports codecs 8 and 48, it is RECOMMENDED that, if the answerer has

   no reason to change it, the ordering of codecs in the answer be 8,
   48, and not 48, 8.  This helps assure that the same codec is used in
   both directions.

 

Hope it help

M

 

________________________________

From: discussion-bounces at sipforum.org
[mailto:discussion-bounces at sipforum.org] On Behalf Of Shakil, Rashid
Sent: Friday, May 16, 2008 3:57 PM
To: discussion at sipforum.org
Subject: [SIPForum-discussion] Codec Prefrence Option

 

I came across to this situation where we receive inbound call the codec
preference set on the SIP INVITE is 711 first and 729 second (m=audio
50000 RTP/AVP 0 18 100) when our softswitch reply back with a 200 OK
with SDP we set the preference as 729 first and 711 second (m=audio 3006
RTP/AVP 18 0 100). Instead of cutting the media over to 729 (means
select this as a codec because the 200 OK has 729 set as preference and
initial INVITE has both options) The peering partner sends a RE-INVITE
with 729 as the only option (a=rtpmap:18 G729/8000).

 

My question is this legal in SIP. Is codec can be negotiated that way as
well. I thought that carrier should negotiate the codec base on the
preference my Softswitch set on 200 OK

 

 

 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://sipforum.org/pipermail/discussion/attachments/20080516/6c4314e1/attachment-0002.html>


More information about the discussion mailing list