linphone-developers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Linphone-developers] Failed to parse SDP message


From: Michel Ferreira Bueno
Subject: Re: [Linphone-developers] Failed to parse SDP message
Date: Fri, 17 Apr 2015 08:35:16 -0300
User-agent: Microsoft-MacOutlook/14.4.8.150116

Hello Dragos,

I found out what is wrong.
Apparently problem is at the end of the SDP message sent by my equipment.
It sends 3 CRLF( \r\n) string sequences instead of one. Take a look:

The correct message should be:
v=0\r\no=0 0 0 IN IP4 192.168.199.104\r\ns=Dahua VT 1.5\r\nc=IN IP4 192.168.199.104\r\nt=0 0\r\nm=audio 15000 RTP/AVP 0\r\na=rtpmap:0 PCMU/8000\r\n

But my equipment sends:
v=0\r\no=0 0 0 IN IP4 192.168.199.104\r\ns=Dahua VT 1.5\r\nc=IN IP4 192.168.199.104\r\nt=0 0\r\nm=audio 15000 RTP/AVP 0\r\na=rtpmap:0 PCMU/8000\r\n\r\n\r\n

I took a look on the source code and noticed that the newer version of the liblinphone has some extra validations for the SDP messages that weren’t present on older versions. This explains why older versions of linphone works fine with this same equipment. 
Apparently this is the reason why my calls are being aborted: the SDP message cannot be parsed because of the extra \r\n at the end of the message.
To test this theory, I wrote my own routine to remove the extra \r\n and everything worked fine.

Regards,
Michel Bueno
 

From: Dragos Oancea <address@hidden>
Reply-To: Dragos Oancea <address@hidden>, "address@hidden" <address@hidden>
Date: quinta-feira, 16 de abril de 2015 18:50
To: "address@hidden" <address@hidden>
Subject: Re: [Linphone-developers] Failed to parse SDP message

Hi Michel,

The SDP in the "200 OK" looks fine to me.
Some observations about it:
- no telephone-event codec
- the rtpmap for PCMU is redundant.

What happens if your voip client offers only PCMA ?

Regards,
Dragos




From: Michel Ferreira Bueno <address@hidden>
To: "address@hidden" <address@hidden>
Sent: Friday, April 10, 2015 7:33 PM
Subject: [Linphone-developers] Failed to parse SDP message

Hello,

I’m facing a problem with latest linphone version and can’t find the reason. When I call from my linphone iOS to one of my voip clients, the call is terminated as soon as it is answered. The linphone on iOS shows this message: Call failed. Reason was: Incompatible, check codecs or security settings.
Also, the following logs are printed:

2015-04-10 14:08:42.325 linphone[69412:4738154] Failed to parse SDP message.
2015-04-10 14:08:42.325 linphone[69412:4738154] Doing SDP offer/answer process of type outgoing
2015-04-10 14:08:42.339 linphone[69412:4738154] Incompatible SDP offer received in 200 OK, need to abort the call

Here is the INVITE message:

INVITE sip:address@hidden SIP/2.0
Via: SIP/2.0/UDP 192.168.199.102:55463;branch=z9hG4bK.WJ9AAiVpU;rport
From: <sip:address@hidden>;tag=Z3ZbvKX3r
CSeq: 20 INVITE
Call-ID: x6Yszwt0G5
Max-Forwards: 70
Supported: outbound
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE, SUBSCRIBE, INFO, UPDATE
Content-Type: application/sdp
Content-Length: 161
Contact: <sip:address@hidden:55463>;+sip.instance="<urn:uuid:a04141a6-48c8-450a-81f6-196933978a72>"
User-Agent: LinphoneIphone/2.2.5-55-g6aa5a53 (belle-sip/1.4.0)

v=0
o=803 2833 1977 IN IP4 192.168.199.102
s=Talk
c=IN IP4 192.168.199.102
b=AS:380
t=0 0
m=audio 7076 RTP/AVP 0 8 101
a=rtpmap:101 telephone-event/8000

And the 200 OK response to it:

SIP/2.0 200 OK
Via: SIP/2.0/UDP 192.168.199.102:55463;branch=z9hG4bK.WJ9AAiVpU;rport=55463
Record-Route: <sip:address@hidden:5060;lr>
From: <sip:address@hidden>;tag=Z3ZbvKX3r
To: <sip:address@hidden>;tag=1216962757
Call-ID: x6Yszwt0G5
CSeq: 20 INVITE
Contact: <sip:address@hidden:5060>
User-agent: Dahua UAC/3.0 VTH1510 V2.0.1.4
Content-Type: application/sdp
Content-Length:   137

v=0
o=0 0 0 IN IP4 192.168.199.104
s=Dahua VT 1.5
c=IN IP4 192.168.199.104
t=0 0
m=audio 15000 RTP/AVP 0
a=rtpmap:0 PCMU/8000

It appears that the SDP message could not be parsed for some reason. Any suggestion what it might be?
I’ve tested with an older version of linphone and it works fine, the problem appeared only on this latest version.
Any help will be appreciated!

Thanks in advance,
Michel Bueno




_______________________________________________
Linphone-developers mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/linphone-developers



reply via email to

[Prev in Thread] Current Thread [Next in Thread]