SIP Multiple m-line Support

 

The IMG 2020 supports multiple m-line in accordance with RFC 3264 (Offer/Answer Model with SDP) and allows the IMG 2020 to select an acceptable media stream from a valid SIP offer containing multiple media streams (m-lines). The answer or response will contain the media streams that are accepted and will also contain the media streams that are rejected. The rejected media streams in the answer will have the media port number set to zero in the m-line. The IMG 2020 accepts a minimum of 1 m-line and a maximum of 4 m-lines and by default, accepts the first matching media stream with at least one media format. The feature is enabled by default and no configuration is required for the feature to function. For more information see below.

Diagram

 

Examples

Below are examples of how IMG 2020 would react to SIP offers with different types of Media Descriptors. (Ex: Audio, Video, Fax). See Additional Information below explaining how the IMG 2020 selects the Media Descriptor.

The IMG 2020 will NOT select the best matching media stream, it will match on the first media stream (m-line) from a valid Offer which has multiple media streams. Matching the first Media Stream assumes the media streams are sorted by preference and the first being the highest preference.

 

In both examples below, the Codec Priority setting will have no effect on the IMG 2020 behavior to accept the first matching media stream in the offer. Codec Priority setting will only affect the IMG 2020 method used to select media formats for answer after having selected a media stream.

Audio

  • A SIP INVITE comes into IMG 2020 with an Offer indicating that there are two audio streams. The IMG 2020 parses the message and sends back an answer with both the accepted and rejected audio stream. In this example, the m-line with payload type of 0 is accepted and m-line with the payload type 8 is rejected. Note that the rejected m-line has a port value of 0. The rejected m-line is sent back in a response to the Offer even though it was rejected.

VoIP Configuration in IMG 2020

Offer to IMG 2020

Answer from IMG 2020

 

Default Codec = G.711 ulaw

Codec Priority = Local

m=audio 38400 RTP/AVP 0

a=rtpmap:0 PCMU/8000

m=audio 49500 RTP/AVP 8

a=rtpmap:8 PCMA/8000

m=audio 6000 RTP/AVP 0

a=..(a-line present as applicable)

m=audio 0 RTP/AVP 8

  • A SIP INVITE comes into IMG 2020 with an Offer indicating that there are three audio streams. The IMG 2020 parses the message and rejects the first m-line because of the Codec. It accepts the second m-line even though the second and third m-line are acceptable. The IMG 2020 accepts the FIRST ACCEPTABLE m-line.

VoIP Configuration in IMG 2020

Offer to IMG 2020

Answer from IMG 2020

 

Default Codec = G.711 ulaw

Codec Priority = Local

m=audio 10000 RTP/AVP 98

a=rtpmap:98 amr/8000

m=audio 18000 RTP/AVP 18

m=audio 38400 RTP/AVP 0 8

a=rtpmap:0 PCMU/8000

a=rtpmap:8 PCMU/8000

m=audio 0 RTP/AVP 98

m=audio 0 RTP/AVP 18

m=audio 6000 RTP/AVP 0

a=..(a-line present as applicable)

  • The IMG 2020 will select the CODEC depending on the Codec Priority field (Local/Remote) setting in the SIP SGP Profile.

VoIP Configuration in IMG 2020

Offer to IMG 2020

Answer from IMG 2020

 

Default Codec = G.711 alaw (default), G.711 ulaw

Codec Priority = Local

m=audio 10000 RTP/AVP 98

a=rtpmap:98 amr/8000

m=audio 38400 RTP/AVP 0 8

a=rtpmap:0 PCMU/8000

a=rtpmap:8 PCMA/8000

m=audio 18000 RTP/AVP 18

m=audio 0 RTP/AVP 98

m=audio 6000 RTP/AVP 8

a=..(a-line present as applicable)

m=audio 0 RTP/AVP 18

 

The IMG 2020 selected the first matching media stream and the media format selected is based on codec priority setting (local)

 

  • The IMG 2020 will select the CODEC depending on the Codec Priority field (Local/Remote) setting in the SIP SGP Profile.

VoIP Configuration in IMG 2020

Offer to IMG 2020

Answer from IMG 2020

 

Codec = G.711 alaw (default)

G.711 ulaw

Codec Priority = Remote

m=audio 10000 RTP/AVP 98

a=rtpmap:98 amr/8000

m=audio 38400 RTP/AVP 0 8

a=rtpmap:0 PCMU/8000

a=rtpmap:8 PCMA/8000

m=audio 18000 RTP/AVP 18

m=audio 0 RTP/AVP 98

m=audio 6000 RTP/AVP 0

a=..(a-line present as applicable)

m=audio 0 RTP/AVP 18

 

 

  • The IMG 2020 will always accept fax (m=image line) if one of the Media streams offered in Re-INVITE is for fax.

VoIP Configuration in IMG 2020

Offer to IMG 2020

Answer from IMG 2020

 

Default Codec = G.711 Ulaw

Codec Priority = Local

Fax T38 Enabled

m=image 7228 udptl t38

a=T38FaxVersion:0

a=T38MaxBitRate:14400

a=T38FaxRateManagement:transferredTCF

a=T38FaxUdpEC:t38UDPRedundancy

m=audio 7228 RTP/AVP 8 0

a=rtpmap:8 PCMA/8000

a=rtpmap:0 PCMU/8000

a=ptime:20

a=silenceSupp:off - - - -

a=ecan:fb on -

a=X-fax

m=image 8001 udptl t38                

m=audio 0 RTP/AVP 8 0

 

Default Codec = G.711 Ulaw

Codec Priority = Local

Fax T38 Enabled

m=audio 7228 RTP/AVP 8 0

a=rtpmap:8 PCMA/8000

a=rtpmap:0 PCMU/8000

a=ptime:20

a=silenceSupp:off - - - -

a=ecan:fb on -

a=X-fax

m=image 7228 udptl t38

a=T38FaxVersion:0

a=T38MaxBitRate:14400

a=T38FaxRateManagement:transferredTCF

a=T38FaxUdpEC:t38UDPRedundancy

m=audio 0 RTP/AVP 8 0

m=image 8001 udptl t38    

Additional Information

  • The IMG 2020 by default will accept all offers with multiple valid m-lines.

  • The IMG 2020 supports a minimum of 1 m-line and a maximum of 4 m-lines. A 488 Not Acceptable Here will be sent if less than 1 or more than 4 m-lines are sent. The only exception to this is in a PRACK scenario.

  • The answer will contain the same number of m-lines as was in the Offer.

  • The IMG 2020 will accept the first matching media stream from an offer with multiple m-lines except when offer has a media stream of fax.

  • The IMG 2020 supports fax only in RE-INVITE scenarios. If Offer contains m=image, it will be rejected.

  • When the IMG 2020 rejects a Media stream, it will set the port number to 0 in the answer and will include the media formats.

  • The IMG 2020 cannot generate an offer with multiple m-line.

  • The IMG 2020 will reject the session with a 488 Not Acceptable Here if none of the media streams is accepted.

  • The IMG 2020 Shall log all codec information and media types across all m-lines in the Radius VSA. Support for m=video is added but not supported as of Software release 10.5.2. The remote m-line parameters will be logged as follows:dialogic-voip-remote-vocoders ="PCMU,PCMA,Video"

Return to Documentation Home I Return to Sangoma Support