SIP INVITE method · Calls are started by means of the methods INVITE together with SDP (Session Description Protocol) which carry the information ...
Skiptocontent
CallsarestartedbymeansofthemethodsINVITEtogetherwithSDP(SessionDescriptionProtocol)whichcarrytheinformationnecessarytoallowtheendpointsofthecallstoexchangeaudioinformofRTP(RealTimeProtocol)packets.
Let’sseeatypicalcalldialog:
TheINVITEmethodcontainingSDPissenttothecalledpartywhichreplieswithaprovisionalmessageRinging(whichindicatesthattheremoteendpointisringing).BeforeRinging,aTryingisusuallysentbytheSIPProxytopreventthecallerfromretransmittingthemessage.
ThecalleecantheneitheracceptthecallwithOKorrefuseitwithanerror.ThecalleecaninterruptthesessionatanytimebysendingaCANCEL.
Let’sseeindetailwhichdataareexchangedandwhichheadersareimportanttousduringdebug:
INVITEsip:[email protected]:5060;user=phoneSIP/2.0
Via:SIP/2.0/UDP10.135.0.12:5060;branch=z9hG4bKhye0bem20x.nx8hnt
Max-Forwards:70
From:"CallingUser"<151>;tag=m3l2hbp
To:<001234567890>
Call-ID:[email protected]
CSeq:10691INVITE
Contact:<151>;+sip.instance=""
Allow:INVITE,CANCEL,BYE,ACK,REGISTER,OPTIONS,REFER,SUBSCRIBE,NOTIFY,MESSAGE,INFO,PRACK,UPDATE
Content-Disposition:session
Supported:replaces,100rel
User-Agent:WildixW-AIR03.55.00.249c751434072202:76:f3:d6:64
Content-Type:application/sdp
Content-Length:254
v=0
o=15196559655INIP410.135.0.12
s=-
c=INIP410.135.0.12
t=00
m=audio50024RTP/AVP80218
a=rtpmap:8PCMA/8000
a=rtpmap:0PCMU/8000
a=rtpmap:2G726-32/8000/1
a=rtpmap:18G729/8000
a=ptime:20
a=maxptime:80
a=sendrecv
a=rtcp:50025
ThemethodisINVITEandtheSIPURIrequestedisthenumberdialed:001234567890(aleading0isaddedbythephonetousetheoutgoingline;thisleading0mightnotbepresent,or–incountriesliketheUnitedStates–itmightbesubstitutedwith9)
Cseq:incasemethodsdifferentfromREGISTERareused,thenumberdoesnothavetostartwith1sotheUserAgentpicked10691
Contact:inthiscaseContactincludesalso+sip.instanceorauniqueidentifierwhichallowstheSIPRegistrar/Proxytoeasilydetectduplicatedregistrations
Supported:indicatesthattheUserAgentsupportsReplaces(neededduringtransferstoreplaceanexistingsession)–100rel(indicatessupportforthereliabletransmissionofprovisionalresponses1XX)
Content-Type:indicatesthattheSIPmessageincludesalsoanSDPbodywhichprovidestheinformationaboutthemediasupportedbythecallingparty
SIP/2.0407ProxyAuthenticationRequired
Via:SIP/2.0/UDP10.135.0.12:5060;branch=z9hG4bKhye0bem20x.nx8hnt;rport=5060
From:"CallingUser"<151>;tag=m3l2hbp
To:<001234567890>;tag=b27e1a1d33761e85846fc98f5f3a7e58.d5d4
Call-ID:[email protected]
CSeq:10691INVITE
Proxy-Authenticate:Digestrealm="10.135.0.1",nonce="WWdAiVlnPjECocBoyYtBDshUs+RxMS+3"
Server:WildixGW-4.2.5.35963
Content-Length:0
AsinthecaseoftheREGISTERmessage,theserverwillrequestauthenticationbeforeacceptingtherequest,astheinitialINVITEdoesnotcontainanyinformationneededforauthentication.
Inthiscasethemessageisslightlydifferent–407ProxyAuthenticationRequired–toindicatethatitisaProxyrequestingtheauthentication.
ACKsip:[email protected]:5060;user=phoneSIP/2.0
Via:SIP/2.0/UDP10.135.0.12:5060;branch=z9hG4bKhye0bem20x.nx8hnt
Max-Forwards:70
From:"CallingUser"<151>;tag=m3l2hbp
To:<001234567890>;tag=b27e1a1d33761e85846fc98f5f3a7e58.d5d4
Call-ID:[email protected]
CSeq:10691ACK
User-Agent:WildixW-AIR03.55.00.249c7514340722
Content-Length:0
Theclientacknowledgeshavingreceivedtheauthenticationchallenge.
INVITEsip:[email protected]:5060;user=phoneSIP/2.0
Via:SIP/2.0/UDP10.135.0.12:5060;branch=z9hG4bKw5ij3wn4knq9hn8kkrmoa64.ahrre7d
Max-Forwards:70
From:"CallingUser"<151>;tag=m3l2hbp
To:<001234567890>
Call-ID:[email protected]
CSeq:10692INVITE
Contact:<151>;+sip.instance=""
Allow:INVITE,CANCEL,BYE,ACK,REGISTER,OPTIONS,REFER,SUBSCRIBE,NOTIFY,MESSAGE,INFO,PRACK,UPDATE
Content-Disposition:session
Proxy-Authorization:Digestusername="151",realm="10.135.0.1",nonce="WWdAiVlnPjECocBoyYtBDshUs+RxMS+3",uri="sip:[email protected]:5060;user=phone",response="b6194033119482068b09dc2688172baf"
Supported:replaces,100rel
User-Agent:WildixW-AIR03.55.00.249c751434072202:76:f3:d6:64
Content-Type:application/sdp
Content-Length:254
v=0
o=15196559655INIP410.135.0.12
s=-
c=INIP410.135.0.12
t=00
m=audio50024RTP/AVP80218
a=rtpmap:8PCMA/8000
a=rtpmap:0PCMU/8000
a=rtpmap:2G726-32/8000/1a=rtpmap:18G729/8000
a=ptime:20
a=maxptime:80
a=sendrecv
a=rtcp:50025
ThesecondINVITElooksprettymuchthesame,buttheCSeqvaluehasincreasedandtheauthenticationinformationisnowpresent.
SIP/2.0100trying--yourcallisimportanttous
Via:SIP/2.0/UDP10.135.0.12:5060;branch=z9hG4bKw5ij3wn4knq9hn8kkrmoa64.ahrre7d;rport=5060
From:"CallingUser"<151>;tag=m3l2hbp
To:<001234567890>
Call-ID:[email protected]
CSeq:10692INVITE
Server:WildixGW-4.2.5.35963
Content-Length:0
ServerrepliesimmediatelywithTrying,toindicatethatthemessagehasbeenreceivedandavoidre-transmissionsfromtheclientwhichwouldhappenwithin500ms(thestandardT1Timer1forSIP)–1000ms(twicetheprevioustimeout)–2000ms(1000msx2)–4000ms(2000msx2)upto16000milliseconds.ThusintotalanSIPClientwillbydefaulttry32secondsbeforecancellingarequestwhichiscalledTimerB(64timesT1).T1canbemodifiedandshouldbeequaltotheestimatedmaximumroundtriptimebetweenclientandserver.
SIP/2.0100Ringing
Via:SIP/2.0/UDP10.135.0.12:5060;branch=z9hG4bKw5ij3wn4knq9hn8kkrmoa64.ahrre7d;rport=5060
From:"CallingUser"<151>;tag=m3l2hbp
To:<001234567890>
Call-ID:[email protected]
CSeq:10692INVITE
Server:WildixGW-4.2.5.35963
Content-Length:0
TheremotesideindicatesAlertingstate–theremotedeviceisringing.
SIP/2.0183SessioninProgress
Via:SIP/2.0/UDP10.135.0.12:5060;branch=z9hG4bKw5ij3wn4knq9hn8kkrmoa64.ahrre7d;rport=
5060
From:"CallingUser"<151>;tag=m3l2hbp
To:<001234567890>
Call-ID:[email protected]
CSeq:10692INVITE
Server:WildixGW-4.2.5.35963
Content-Type:application/sdp
Content-Length:170
v=0
o=root16731402321673140232INIP410.135.0.1
s=Wildix35935
c=INIP410.135.0.1
t=00
m=audio13504RTP/AVP8
a=rtpmap:8PCMA/8000/1
a=ptime:20
a=sendrecv
BesidesRingingtheremovesidemightprovideinbandinformationsuchasearlymediabeforeconnectionasintheexampleabove.Thisisusedforexamplebyoperatorstoprovidefreemessagesbeforetransferringacalltovoicemail.
SIP/2.0200OK
Via:SIP/2.0/UDP10.135.0.12:5060;rport=5060;branch=z9hG4bKw5ij3wn4knq9hn8kkrmoa64.ahrre7d
From:"CallingUser"<151>;tag=m3l2hbp
To:<001234567890>;tag=as27b249ee
Call-ID:[email protected]
CSeq:10692INVITE
Server:WildixGW35935
Allow:INVITE,ACK,CANCEL,OPTIONS,BYE,REFER,SUBSCRIBE,NOTIFY,INFO,PUBLISH
Supported:replaces,timer
Session-Expires:600;refresher=uas
Contact:<001234567890>
P-Asserted-Identity:"+331XXXXXXXX"
Content-Type:application/sdp
Content-Length:170
v=0
o=root16731402321673140232INIP410.135.0.1
s=Wildix35935
c=INIP410.135.0.1
t=00
m=audio13504RTP/AVP8
a=rtpmap:8PCMA/8000/1
a=ptime:20
a=sendrecv
PleasenotethattheSDPcontainsonlyonecodec.Itisalsoimportanttonoticethattheheader“P-Asserted-Identity”containstheinformationwhichwillbethendisplayedtothecalleronthescreen.
Informationrequest:
Ineedmoreinformationonimprovingthebusinesscommunications
Privacy*:IhavereadandacceptthePrivacy*
IwanttoreceiveexclusivecontentforSystemIntegratorsandMSPsonhowtogrowmyBusiness
SocialSharing
LeaveaReplyCancelreplyYouremailaddresswillnotbepublished.Requiredfieldsaremarked*Comment*Name*
Email*
Website
Savemyname,email,andwebsiteinthisbrowserforthenexttimeIcomment.
Postnavigation
PreviousPostPreviousUnderstandingREGISTERmethodNextPostNextACKandBYEmethods
BlogSubscription Enteryouremailaddress:
You'llreceiveanemailwhenwepublishnewarticles.
Search
Searchfor:
Search
TWEETS TweetsbyWildix_
SeewhyWildixisEurope’sonlyUCaaSbrandontheMagicQuadrant™
Getthereport
AvatarsbySterlingAdventures
001234567890>001234567890>151>001234567890>151>001234567890>151>001234567890>151>151>001234567890>151>001234567890>151>001234567890>151>151>001234567890>151>