[Home]

Summary:ASTERISK-24557: WebRTC call returns error "Failed to get local SDP"
Reporter:Osaulenko Alexander (a.osaulenko)Labels:
Date Opened:2014-11-25 07:47:31.000-0600Date Closed:2014-12-23 13:58:30.000-0600
Priority:MajorRegression?No
Status:Closed/CompleteComponents:
Versions:11.9.0 11.14.1 Frequency of
Occurrence
Constant
Related
Issues:
Environment:centos6.6, debian7.7.0 (i686 and x64)Attachments:( 0) backtrace_20141222.txt
( 1) backtrace.txt
( 2) backtraceSDP_fail.txt
Description:We use Asterisk of different versions 11.9-11.14.1 with default settings for WebRTC and Openssl version: OpenSSL 1.0.1e 11 Feb 2013. It works but craches on:

d1_both.c(278): OpenSSL internal error, assertion failed: s->init_num == (int)s->d1->w_msg_hdr.msg_len + DTLS1_HM_HEADER_LENGTH

We tried update openssl to OpenSSL 1.0.1j and then compiled Asterisk.
When we try to call using WebRTC we have error "Failed to get local SDP"
Comments:By: Osaulenko Alexander (a.osaulenko) 2014-11-25 07:55:20.794-0600

Attached backtrace.txt after Asterisk had crashed

By: Matt Jordan (mjordan) 2014-11-25 09:08:12.126-0600

Thank you for your bug report. In order to move your issue forward, we require a backtrace[1] from the core file produced after the crash. Also, be sure you have DONT_OPTIMIZE enabled in menuselect within the Compiler Flags section, then:

make install

After enabling, reproduce the crash, and then execute the backtrace[1] instructions. When complete, attach that file to this issue report.

[1] https://wiki.asterisk.org/wiki/display/AST/Getting+a+Backtrace

What you've attached is not a valid backtrace. Please following the linked instructions.

By: Osaulenko Alexander (a.osaulenko) 2014-11-27 08:25:08.449-0600

Matt, backtrace is attached

By: Badalian Vyacheslav (slavon) 2014-11-28 21:22:00.667-0600

https://rt.openssl.org/Ticket/Display.html?id=3592
guest /  guest

By: Rusty Newton (rnewton) 2014-12-15 09:43:03.723-0600

Your trace is incomplete for what we need. Also, there is a lot of this in your trace/log:

{noformat}
Nov 26 07:03:51] WARNING[4696]: loader.c:452 load_dynamic_module: Module 'res_ari' did not register itself during load
[Nov 26 07:03:51] WARNING[4696]: loader.c:918 load_resource: Module 'res_ari' could not be loaded.
[Nov 26 07:03:51] WARNING[4696]: loader.c:452 load_dynamic_module: Module 'res_stasis' did not register itself during load
[Nov 26 07:03:51] WARNING[4696]: loader.c:918 load_resource: Module 'res_stasis' could not be loaded.
[Nov 26 07:03:51] WARNING[4696]: loader.c:840 inspect_module: Module 'res_ari_playbacks.so' was not compiled with the same compile-time options as this version of Asterisk.
[Nov 26 07:03:51] WARNING[4696]: loader.c:841 inspect_module: Module 'res_ari_playbacks.so' will not be initialized as it may cause instability.
[Nov 26 07:03:51] WARNING[4696]: loader.c:931 load_resource: Module 'res_ari_playbacks.so' could not be loaded.
{noformat}

Please recompile Asterisk completely (including all modules). When doing so, make sure to [follow the linked instructions|https://wiki.asterisk.org/wiki/display/AST/Getting+a+Backtrace#GettingaBacktrace-GettingInformationAfterACrash] to use appropriate compiler flags and get a backtrace from the core after it dumps.

When recompiling Asterisk, please test with the latest of the SVN 11 branch as there are a few recent fixes that may apply to your issue.

By: Osaulenko Alexander (a.osaulenko) 2014-12-23 01:33:25.155-0600

Hello, Rusty Newton!
I have attached new backtrace. We had made two calls and get error "Failed to get local SDP". First call was general, second was with sip debug.

By: Osaulenko Alexander (a.osaulenko) 2014-12-23 03:24:46.804-0600

Hello, Rusty Newton!
I have attached new backtrace - backtrace(SDP fail).txt

By: Matt Jordan (mjordan) 2014-12-23 13:58:25.187-0600

Looking at your log file, the error message is being returned from whatever client Asterisk is communicating with:

{noformat}
<--- SIP read from WS:192.168.34.145:2562 --->
SIP/2.0 603 Failed to get local SDP
Via: SIP/2.0/WS 192.168.34.199:5060;rport=5060;branch=z9hG4bK589fe139
From: "156"<sip:156@192.168.34.199>;tag=as451e8620
To: <sip:157@df7jal23ls0d.invalid;rtcweb-breaker=no;transport=ws>;tag=8W672ie5gHvCPbzyA7VQ
Call-ID: 597126967b118c560a03e3eb6393f8da@192.168.34.199:5060
CSeq: 102 INVITE
Content-Length: 0
Reason: SIP; cause=603; text="Failed to get local SDP"

<------------->
{noformat}

You'll need to investigate it to determine what it doesn't like about the INVITE request Asterisk sent to it.

{noformat}
Reliably Transmitting (NAT) to 192.168.34.145:2562:
INVITE sip:157@df7jal23ls0d.invalid;rtcweb-breaker=no;transport=ws SIP/2.0

Via: SIP/2.0/WS 192.168.34.199:5060;branch=z9hG4bK589fe139;rport

Max-Forwards: 70

From: "156" <sip:156@192.168.34.199>;tag=as451e8620

To: <sip:157@df7jal23ls0d.invalid;rtcweb-breaker=no;transport=ws>

Contact: <sip:156@192.168.34.199:5060;transport=WS>

Call-ID: 597126967b118c560a03e3eb6393f8da@192.168.34.199:5060

CSeq: 102 INVITE

User-Agent: Asterisk PBX SVN-branch-11-r429539

Date: Mon, 22 Dec 2014 07:40:34 GMT

Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE

Supported: replaces, timer

Content-Type: application/sdp

Content-Length: 409



v=0

o=root 1170437591 1170437591 IN IP4 192.168.34.199

s=Asterisk PBX SVN-branch-11-r429539

c=IN IP4 192.168.34.199

t=0 0

m=audio 12760 UDP/TLS/RTP/SAVPF 0 3 8

a=rtpmap:0 PCMU/8000

a=rtpmap:3 GSM/8000

a=rtpmap:8 PCMA/8000

a=ptime:20

a=connection:new

a=setup:actpass

a=fingerprint:SHA-256 62:8E:8B:50:E7:8D:D6:62:DE:3B:9E:D8:E5:B8:49:04:23:E8:34:AF:C5:93:94:FF:DD:4E:9A:32:8D:C7:B8:82

a=sendrecv

{noformat}

That being said, it appears as if you've modified Asterisk. Asterisk does not include the request line modifier "rtcweb-breaker" anywhere.
{{INVITE sip:157@df7jal23ls0d.invalid;rtcweb-breaker=no;transport=ws SIP/2.0}}

The project does not provide source for modified versions of Asterisk.