Categories

CUC (6) CUCM (27) Jabber (6) Python (2) Routing (3) Solarwinds Orion NPM (4) switching (1) Video (6) voice (2)

Monday, 8 August 2016

SIP Early offer v. Delayed Offer

Another post on SIP?!  Why?  Because SIP is good, I love SIP and so should you.

SIP Signalling/Media establishment negotiation comes in two flavors:

    • SIP Delayed Offer (DO),  ACK contains SDP
    • SIP Early Offer     (EO),   INVITE contains SDP

There is no right or wrong method, sometimes EO works and sometimes DO works. Both Delayed offer and Early offer are mandatory parts of the SIP standard. So if you ask me when to implement what method, my answer (as with many IT topics) would be; 'it depends'.

But let me first explain what the difference is between these two methods.

With Delayed Offer, the session initiator (calling devices) does not send its capabilities in the initial INVITE, but waits for the calling devices to send its capabilities first. Using this method means that the called device will send it capabilities first (for instance a list of codecs it can deal with), thus allowing the calling device to choose from that list.

With Early Offer, the session initiator (calling device) sends it capabilities (for instance codec, IP address, and UDP port for RTP) in the SDP body contained in the initial INVITE. This allows the called device to choose the properties/capabilities of the call. EO if often preferred by IP PSTN provider. Because it will allow these providers to quickly establish one-way media to the calling device, after the provider has received the intial INVITE. This allow the provider to stream messages, such as "unknown number" or "the number you have called is 500 bucks a minute". With Early Offer, the called device decides the negotiated media.

So I guess the main requirement why some systems would use Early Offer over Delayed Offer, is the requirement to set up a session pretty much straight after the INVITE is received. If speed is not imperative, then a system can get by, using Delayed Offer.


The number one, easiest way to find out what method you is being used for a particular call, is to capture the logs of the SIP call and look at the initial invite. If it contains an SDP then its Early Offer, if it does contain an SDP, then its Early Offer.


The picture below shows part of a capture I did in the past, and has an inbound call leg that is DO and outbound with EO (as it includes an SDP).




I would probably tend to argue that I would like to have both call legs EO or DO if I could, or at least NOT a mix of the two. But I would also argue; 'if it aint broke dont fix it'.


FYI, by default, Cisco SIP phones use Early Offer  and by default CUCM SIP trunk use Delayed Offer.



No comments:

Post a Comment