Sip Questions

sip RFC summary

http://www.networksorcery.com/enp/protocol/sip.htm

1. SIP questions

2. good tutorial

http://www.cs.columbia.edu/~coms6181/slides/

3. more SIP questions

concepts in SIP

http://www.voipuser.org/forum_topic_7295.html

basic flow of a SIP transaction

sip-flow.gif

DTMF

http://www.voip-info.org/wiki/view/SIP+DTMF+Signalling
There are 3 common ways of sending DTMF on SIP calls

  • SIP INFO packets
  • As specially marked events in the RTP stream - see: RFC 2833
  • inband as normal audio tones in the RTP stream with no special coding or markers

dtmf debug

sip and SDP headers:

RFC 3261, section 7.3.1 "Header Field Format", near the top of page 32,
says:

"When comparing header fields, field names are always case insensitive."

while SDP is case-sensitive. “field” is exactly one character (case-sensitive)

well explained SIP message fields.

http://www.geocities.com/intro_to_multimedia/SIP/request.html

request and response

The first line of the text-encoded message is called Request-Line: Method SP Request-URI SP SIP-Version CRLF
[SP = single-space & CRLF=Carriage Return + Line Feed

INVITE sip:moc.2revres|2resu#moc.2revres|2resu SIP/2.0

The first line in a response is called Status line: SIP-Version SP Status-Code SP Reason-Phrase CRLF
[SP = single-space & CRLF=Carriage Return + Line Feed

SIP/2.0 200 OK

six types of responses.

SIP/2.0 allows six types of response. They are similar to those of HTTP.

* 1xx: Provisional — request received, continuing to process the request;
* 2xx: Success — the action was successfully received, understood, and accepted;
* 3xx: Redirection — further action needs to be taken in order to complete the request;
* 4xx: Client Error — the request contains bad syntax or cannot be fulfilled at this server;
* 5xx: Server Error — the server failed to fulfill an apparently valid request;
* 6xx: Global Failure — the request cannot be fulfilled at any server.

(1)If a response is received having a Status-Code of the form yxx which is not understood by the receiving party, it treats the response as a y00 response i.e. if a client receives an unknown response 345, it treats that as a 300 response.
(2)An unknown 1xx is treated as 183 (Session in Progress).

So each UA must know how to react to 100,183,200,300,400,500 and 600.

what is a location server?

The Registrar stores this binding (between the user and its present address) in a location server which is used by other proxies to locate the user. so a location server is kind like a DB system.

SDP fields

•Session description (* denotes optional )
v= (protocol version)
o= (owner/creator and session identifier)
s= (session name)
i=* (session information)
u=* (URI of description)
e=* (email address)
p=* (phone number)
c=* (connection information -not required if included in all media)
b=* (bandwidth information)
One or more time descriptions (see next slide)
z=* (time zone adjustments)
k=* (encryption key)
a=* (zero or more session attribute lines)
Zero or more media descriptions (see next slide)

•Time description (* denotes optional )
t= (time the session is active)
r=* (zero or more repeat times)

•Media description (* denotes optional )
m= (media name and transport address)
i=* (media title)
c=* (connection information -optional if included at session-level)
b=* (bandwidth information)
k=* (encryption key)
a=* (zero or more media attribute lines)

How voice is coded digitally for voip?

The digitization of analog voice signals is a must to transmit voice over the digital IP network. It can be done in several ways

* PCM (Pulse Code Modulation) is a simple technique of sampling the sound signal at a fixed rate (8000 times/second) and generate a number corresponding to each sample. It assumes no specific property of the signal. So it works reasonably well with all types of sounds.
* LPC (Liner Predictive Coding) assumes specific properties of human voice and uses a more complex algorithm to digitize and compress voice data. It works well for sending human utterances offering a low data rate but is not suitable for transmitting music or fax.
* SBC (Sub Band Coder) uses a different approach of representing sounds in terms of frequencies rather than sampling at regular intervals.
* Hybrid coders like the CELP (Code Excited Linear Prediction) use a mixture of the techniques to transmit sound of adequate quality.

SIP vs H.323

http://www.cisco.com/univercd/cc/td/doc/product/voice/sipsols/biggulp/bgsipov.htm#27697

H.323 stack

h323.png
http://www.linktionary.com/h/h323.html

SIP stack

sip-stack.png

NAT issue

four types of NAT:

  1. FULL Cone : Any external host can send a packet to the internal host, by sending a packet to the mapped external address
  2. Restricted Cone : an external host (with IP address X) can send a packet to the internal host only if the internal host had previously sent a packet to IP address X.
  3. Port Restricted Cone : A port restricted cone NAT is like a restricted cone NAT, but the restriction includes port numbers. Specifically, an external host can send a packet, with source IP address X and source port P, to the internal host only if the internal host had previously sent a packet to IP address X and port P.
  4. Symmetric : The most common in modern day solutions. A NAT 'binding' is created by the NAT device in response to a request made from internal_source_ip:port to public_destination_ip:port. This binding is kept alive so you can recieve responses from public_destination_ip:port (but it _has_ to come from this address/port combo). A new binding is created for each unique internal_source_ip:port combo that sends packets somewhere on a network that is external to your NAT device which controls your private LAN.

- UPnP
- STUN
- TURN
- Tunnel
- AIG

good paper: http://www.newport-networks.com/whitepapers/nat-traversal3.html

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License