2016-04-29 87 views
1

我對Freeswitch 1.6.6有個神祕的問題。Freeswitch sdp響應缺少摘要

我嘗試整合sipjs(v0.7.4)與我的中心使用webrtc一起工作。

的應用都沒有問題(使用WSS)進行註冊,但是當我嘗試調用的其他用戶,我有一個SDP解析錯誤:

SIPml-api.js:1 Failed to parse SessionDescription. a=fingerprint:sha-256 
Failed to create fingerprint from the digest.tsk_utils_log_error @ SIPml-api.js:1 

當我在FreeSWITCH的日誌檢查SDP,這是我收到(IP住址是自願的蒙面):

o=mozilla...THIS_IS_SDPARTA-45.0.2 3927228173093566425 0 IN IP4 0.0.0.0 
s=- 
t=0 0 
a=sendrecv 
a=fingerprint:sha-256 EE:D6:5C:B1:7D:99:E6:FB:9A:46:89:58:14:19:A5:29:4A:AF:D3:0D:BE:32:06:76:1D:08:F5:3F:F9:DA:8B:DA 
a=ice-options:trickle 
a=msid-semantic:WMS * 
m=audio 63339 UDP/TLS/RTP/SAVPF 109 9 0 8 
c=IN IP4 ***.***.***.*** 
a=rtpmap:109 opus/48000/2 
a=rtpmap:9 G722/8000/1 
a=rtpmap:0 PCMU/8000 
a=rtpmap:8 PCMA/8000 
a=candidate:0 1 UDP 2122252543 ***.***.***.*** 63339 typ host 
a=candidate:2 1 UDP 2122187007 ***.***.***.*** 54708 typ host 
a=candidate:4 1 UDP 2122121471 ***.***.***.*** 56942 typ host 
a=candidate:0 2 UDP 2122252542 ***.***.***.*** 61720 typ host 
a=candidate:2 2 UDP 2122187006 ***.***.***.*** 61984 typ host 
a=candidate:4 2 UDP 2122121470 ***.***.***.*** 63345 typ host 
a=end-of-candidates 
a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level 
a=ice-pwd:1caa7d986c87c16de3e4f6f760528544 
a=ice-ufrag:2e86561a 
a=mid:sdparta_0 
a=msid:{2b638262-0603-3942-af0e-24fcb578a272} {5b012d42-d929-c144-8669-4aa5367cb6be} 
a=rtcp:61720 IN IP4 ***.***.***.*** 
a=rtcp-mux 
a=setup:actpass 
a=ssrc:1176697136 cname:{04e0f7d1-9999-ad46-871c-55dcb58e8bbd} 

而這正是FreeSWITCH中發送給客戶端:

v=0 
o=FreeSWITCH 1461635251 1461635252 IN IP4 128.179.101.13 
s=FreeSWITCH 
c=IN IP4 ***.***.***.*** 
t=0 0 
a=msid-semantic: WMS SqfRSSh9myFLk84BEDbOTgfOjB1zYaUH 
m=audio 23832 RTP/SAVPF 109 9 0 8 102 101 
a=rtpmap:109 opus/48000/2 
a=fmtp:109 useinbandfec=1; maxaveragebitrate=510000; maxplaybackrate=48000; ptime=20; minptime=10; maxptime=40; stereo=1 
a=rtpmap:9 G722/8000 
a=rtpmap:0 PCMU/8000 
a=rtpmap:8 PCMA/8000 
a=rtpmap:102 telephone-event/48000 
a=rtpmap:101 telephone-event/8000 
a=fingerprint:sha-256 
a=setup:actpass 
a=rtcp-mux 
a=rtcp:23832 IN IP4 ***.***.***.*** 
a=ssrc:1503282107 cname:qZo9Iv9VTEx4Drv7 
a=ssrc:1503282107 msid:SqfRSSh9myFLk84BEDbOTgfOjB1zYaUH a0 
a=ssrc:1503282107 mslabel:SqfRSSh9myFLk84BEDbOTgfOjB1zYaUH 
a=ssrc:1503282107 label:SqfRSSh9myFLk84BEDbOTgfOjB1zYaUHa0 
a=ice-ufrag:VxMFDRjNjad7bYEs 
a=ice-pwd:OTsmer8YVvSpNenyCZ36HdJQ 
a=candidate:2992776492 1 udp 659136 ***.***.***.*** 23832 typ host generation 0 
a=candidate:2992776492 2 udp 659136 ***.***.***.*** 23832 typ host generation 0 
a=ptime:20 
a=sendrecv 

你可以看到,Freeswitch sdp沒有sha-256摘要。

有沒有人有一個想法,爲什麼摘要消失?

感謝

+0

您是否看到類似'[ERR] switch_core_cert.c:210 FP FILE ERR !'的消息? – mirkobrankovic

回答

1

最有可能你缺少DTLS-srtp.pem在您的$$ {} certs_dir

檢查FreeSWITCH的目錄的所有權,用戶運行FreeSWITCH的需要對$$ permitions {certs_dir}通常是/ etc/freeswitch/tls來創建dtls-srtp.pem證書。

+0

此文件丟失。這是因爲我使用了docker容器,並將certs目錄與主機上的certs目錄鏈接起來。所以dtls-srtp.pem文件被破壞了。 我不得不重新啓動容器中的freeswitch以重建此文件(docker start/stop不會重新創建文件)。 感謝您的回答 – Marom

+0

np,很高興它被修復:) – mirkobrankovic