[asterisk-bugs] [Asterisk 0017735]: [patch] Video RTP type in response SDP not matching the one in INVITE

Asterisk Bug Tracker noreply at bugs.digium.com
Fri Jul 30 03:38:51 CDT 2010


A NOTE has been added to this issue. 
====================================================================== 
https://issues.asterisk.org/view.php?id=17735 
====================================================================== 
Reported By:                sgarcia
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   17735
Category:                   Channels/chan_sip/Video
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     ready for review
Asterisk Version:           SVN 
JIRA:                       SWP-1973 
Regression:                 No 
Reviewboard Link:            
SVN Branch (only for SVN checkouts, not tarball releases):  1.4  
SVN Revision (number only!):  
Request Review:              
====================================================================== 
Date Submitted:             2010-07-28 04:24 CDT
Last Modified:              2010-07-30 03:38 CDT
====================================================================== 
Summary:                    [patch] Video RTP type in response SDP not matching
the one in INVITE
Description: 
When creating the SDP for answering a SIP call only audio types are matched
against the incoming INVITE SDP. As a result the default rtp codecs type
for video are used instead.

Even if that is tenchically correct, that causes softphones like Port SIP
or Pangolin not to display incomming video as expects the same rtp codec
type for both rtp video streams.

For audio it is already done, so the it will be much more coherent to do
it in video also. The ptch is quite simple:


<inline patch removed by lmadsen -- please upload as a file>
====================================================================== 

---------------------------------------------------------------------- 
 (0125368) sgarcia (reporter) - 2010-07-30 03:38
 https://issues.asterisk.org/view.php?id=17735#c125368 
---------------------------------------------------------------------- 
Hi Olle,

We are not adding new codecs, the patchs is just matching the RTP type
number of the codecs we send in the SDP response with the ones offered in
the INVITE.

Without the patch the call flow is (removed ip addresses)

INVITE sip:300 at XX.XX.XX.XX SIP/2.0
Via: SIP/2.0/UDP
192.168.1.33:5288;branch=z9hG4bK-d8754z-290acf6d1a2ac71e-1---d8754z-;rport
Max-Forwards: 70
Contact: <sip:200 at 192.168.1.33:5288>
To: <sip:300 at XX.XX.XX.XX>
From: "200"<sip:200 at XX.XX.XX.XX>;tag=d2626f7d
Call-ID: ZWU1ZmM2YmZkYzk1MWQ0Yjg4NTM5MjEyYjg5MTFjNzI.
CSeq: 1 INVITE
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
REGISTER, UBSCRIBE, INFO
Content-Type: application/sdp
Supported: replaces
User-Agent: Pangolin v5.3, Build 11292009
Content-Length: 471

v=0
o=- 5973438 5973438 IN IP4 192.168.1.33
s=http://www.portsip.com
c=IN IP4 192.168.1.33
t=0 0
m=audio 21352 RTP/AVP 0 8 18 3 98 4 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:3 GSM/8000
a=rtpmap:98 iLBC/8000
a=rtpmap:4 G723/8000
a=rtpmap:101 telephone-event/8000
a=ptime:20
a=fmtp:101 0-15
m=video 40694 RTP/AVP 125
a=fmtp:125 profile-level-id=42801e; packetization-mode=1
a=rtpmap:125 H264/90000

SIP/2.0 200 OK
Via: SIP/2.0/UDP
192.168.1.33:5288;branch=z9hG4bK-d8754z-290acf6d1a2ac71e-1---d8754z-;received=79.154.129.162;rport=5288
From: "200"<sip:200 at XX.XX.XX.XX>;tag=d2626f7d
To: <sip:300 at XX.XX.XX.XX>;tag=as7262f783
Call-ID: ZWU1ZmM2YmZkYzk1MWQ0Yjg4NTM5MjEyYjg5MTFjNzI.
CSeq: 1 INVITE
User-Agent: Asterisk PBX
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces
Contact: <sip:300 at XX.XX.XX.XX>
Content-Type: application/sdp
Content-Length: 340

v=0
o=root 4708 4708 IN IP4 XX.XX.XX.XX
s=session
c=IN IP4 XX.XX.XX.XX
b=CT:512
t=0 0
m=audio 15936 RTP/AVP 0 8 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=silenceSupp:off - - - -
a=ptime:20
a=sendrecv
m=video 13282 RTP/AVP 99
a=rtpmap:99 H264/90000
a=sendrecv


Note that in the first SDP h264 has an RTP codec type of 126 and in the
response SDP 99 (the default asterisk one).

The patch changes that, using the offered number (126) in the reply
instead.
m=video 13282 RTP/AVP 125
a=rtpmap:125 H264/90000
a=sendrecv


Best regards
Sergio 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2010-07-30 03:38 sgarcia        Note Added: 0125368                          
======================================================================




More information about the asterisk-bugs mailing list