Re: MobicentsWebClient.jsp

72 views
Skip to first unread message

Jean Deruelle

unread,
Nov 8, 2012, 6:49:14 AM11/8/12
to Nathan Stratton, mobicents-public
Hi Nathan,

You have to use the latest version from https://oss.sonatype.org/content/repositories/snapshots/org/mobicents/servlet/sip/examples/websockets-sip-servlet/2.1.0-SNAPSHOT/ as there was a non backward compatible change to the WebRTC API between Version 22 and 23 from Google Chrome. This latest snapshot is upgraded to the latest JAIN SIP JS and WebRTC API changes. 

I added mobicents-public google group to my reply for the benefit of the community. For future queries about Mobicents, please use the google group so that everyone benefits from it and you can benefit from community.

Thanks in advance
BR
Jean


On Thu, Nov 8, 2012 at 2:09 AM, Nathan Stratton <nat...@robotics.net> wrote:
Ran into an error using google-chrome that said it could not find webkitPeerConnection00, I edited ApplicationSipTest.js and changed it to webkitRTCPeerConnection and it now does not give an error, but when I send a register it looks something like:

SIP message sent: REGISTER sip:robotics.net SIP/2.0 Call-ID: 1352336714179 CSeq: 1 REGISTER From: <sip:10...@robotics.net>;tag=1352336714190 To: <sip:10...@robotics.net> Via: SIP/2.0/WS SGdUTQwcTU3r.invalid;branch=z9hG4bK1352336714112 Max-Forwards: 70 Expires: 3600 User-Agent: WebRTC JAIN SIP JS UserAgent Allow: INVITE,ACK,CANCEL,BYE Contact: <sip:10...@SGdUTQwcTU3r.invalid;transport=ws> Content-Length: 0
As you can see the Via line is totally messed up, so my websockets proxy gets it, but can't respond because the Via is messed up.

Any ideas how to fix it?

--
><>
Nathan Stratton
nathan at robotics.net
http://www.robotics.net


Jean Deruelle

unread,
Nov 8, 2012, 9:00:50 AM11/8/12
to Nathan Stratton, mobicents-public
That's mandatory from SIP Over WebSockets IETF Draft  http://tools.ietf.org/html/draft-ietf-sipcore-sip-websocket-06

But the message received in the SIP Servlets application in Mobicents should be correct at it replaces it with the correct one.

Jean


On Thu, Nov 8, 2012 at 2:39 PM, Nathan Stratton <nat...@robotics.net> wrote:
Thanks, the new version does fix webkitPeerConnection00, however the IP address in the REGISTER is still garbage.

SIP message sent: REGISTER sip:mobicents.com SIP/2.0 Call-ID: 1352381851008 CSeq: 1 REGISTER From: <sip:tele...@mobicents.com>;tag=1352381851017 To: <sip:tele...@mobicents.com> Via: SIP/2.0/WS wFdzTI7flqTk.invalid;branch=z9hG4bK1352381850956 Max-Forwards: 70 Expires: 3600 User-Agent: MobicentsWebRTCPhone Allow: INVITE,UPDATE,ACK,CANCEL,BYE,NOTIFY,OPTIONS,MESSAGE,REFER Contact: <sip:tele...@wFdzTI7flqTk.invalid;transport=ws> Content-Length: 0

Nathan Stratton

unread,
Nov 22, 2012, 11:00:35 AM11/22/12
to Jean Deruelle, mobicents-public
We were able to get it to register via reSIProcate, we had to make the attached patch to get it to work.

We send back what looks like a good 200 OK:
SIP message received: SIP/2.0 200 OK Via: SIP/2.0/WS SIC5KPZpN1hM.invalid;branch=z9hG4bK1353599314883;rport=50930;received=75.148.206.241;rport Record-Route: <sip:204.117.64.103:5060;transport=udp;lr;drr> Contact: <sip:conf=10...@204.117.64.121:5060> To: <sip:conf=10...@204.117.64.121>;tag=e452e70d From: <sip:10...@robotics.net>;tag=1353599320484 Call-ID: 1353599320485 CSeq: 1 INVITE Allow: INVITE,ACK,CANCEL,OPTIONS,BYE,UPDATE,INVITE,REGISTER,ACK,CANCEL,BYE,INFO Content-Type: application/sdp Content-Length: 4134 v=0 o=- 1786481246 2 IN IP4 127.0.0.1 s=- c=IN IP4 204.117.64.103 t=0 0 a=group:BUNDLE audio video m=audio 44516 RTP/SAVPF 103 104 111 0 8 106 105 13 126 c=IN IP4 10.13.0.241 a=rtpmap:103 ISAC/16000 a=rtpmap:104 ISAC/32000 a=rtpmap:111 opus/48000 a=rtpmap:0 PCMU/8000 a=rtpmap:8 PCMA/8000 a=rtpmap:106 CN/32000 a=rtpmap:105 CN/16000 a=rtpmap:13 CN/8000 a=rtpmap:126 telephone-event/8000 a=rtcp:44516 IN IP4 10.13.0.241 a=candidate:2104331942 1 udp 2113937151 10.13.0.241 44516 typ host generation 0 a=candidate:2104331942 2 udp 2113937151 10.13.0.241 44516 typ host generation 0 a=candidate:3247670995 1 udp 2113937151 75.148.206.241 37598 typ host generation 0 a=candidate:3247670995 2 udp 2113937151 75.148.206.241 37598 typ host generation 0 a=candidate:1170023432 1 udp 2113937151 172.16.209.1 37561 typ host generation 0 a=candidate:1170023432 2 udp 2113937151 172.16.209.1 37561 typ host generation 0 a=candidate:1332981290 1 udp 2113937151 192.168.112.1 48481 typ host generation 0 a=candidate:1332981290 2 udp 2113937151 192.168.112.1 48481 typ host generation 0 a=candidate:305256454 1 tcp 1509957375 10.13.0.241 39486 typ host generation 0 a=candidate:305256454 2 tcp 1509957375 10.13.0.241 39486 typ host generation 0 a=candidate:2703806356 1 tcp 1509957375 75.148.206.241 47638 typ host generation 0 a=candidate:2703806356 2 tcp 1509957375 75.148.206.241 47638 typ host generation 0 a=candidate:1618237094 1 tcp 1509957375 172.16.209.1 45507 typ host generation 0 a=candidate:1618237094 2 tcp 1509957375 172.16.209.1 45507 typ host generation 0 a=candidate:2370331815 1 tcp 1509957375 192.168.112.1 47777 typ host generation 0 a=candidate:2370331815 2 tcp 1509957375 192.168.112.1 47777 typ host generation 0 a=ice-ufrag:6d9sdwyicUWXxuVR a=ice-pwd:iqqO1sPgO/pTOgt1yD1eqF83 a=ice-options:google-ice a=sendrecv a=mid:audio a=rtcp-mux a=crypto:1 AES_CM_128_HMAC_SHA1_80 inline:CnYf8+szqtOsTGT3LRtnqzOolnHfAIXByrlm1gLg a=ssrc:2355611039 cname:pvLhMzb2m7ASX0uU a=ssrc:2355611039 msid:zf4MUOMfklOVOx2pSXfJOxivUiCmM7fop3ig a0 a=ssrc:2355611039 mslabel:zf4MUOMfklOVOx2pSXfJOxivUiCmM7fop3ig a=ssrc:2355611039 label:zf4MUOMfklOVOx2pSXfJOxivUiCmM7fop3iga0 m=video 44516 RTP/SAVPF 100 101 102 c=IN IP4 10.13.0.241 a=rtpmap:100 VP8/90000 a=rtpmap:101 red/90000 a=rtpmap:102 ulpfec/90000 a=rtcp:44516 IN IP4 10.13.0.241 a=candidate:2104331942 1 udp 2113937151 10.13.0.241 44516 typ host generation 0 a=candidate:2104331942 2 udp 2113937151 10.13.0.241 44516 typ host generation 0 a=candidate:3247670995 1 udp 2113937151 75.148.206.241 37598 typ host generation 0 a=candidate:3247670995 2 udp 2113937151 75.148.206.241 37598 typ host generation 0 a=candidate:1170023432 1 udp 2113937151 172.16.209.1 37561 typ host generation 0 a=candidate:1170023432 2 udp 2113937151 172.16.209.1 37561 typ host generation 0 a=candidate:1332981290 1 udp 2113937151 192.168.112.1 48481 typ host generation 0 a=candidate:1332981290 2 udp 2113937151 192.168.112.1 48481 typ host generation 0 a=candidate:305256454 1 tcp 1509957375 10.13.0.241 39486 typ host generation 0 a=candidate:305256454 2 tcp 1509957375 10.13.0.241 39486 typ host generation 0 a=candidate:2703806356 1 tcp 1509957375 75.148.206.241 47638 typ host generation 0 a=candidate:2703806356 2 tcp 1509957375 75.148.206.241 47638 typ host generation 0 a=candidate:1618237094 1 tcp 1509957375 172.16.209.1 45507 typ host generation 0 a=candidate:1618237094 2 tcp 1509957375 172.16.209.1 45507 typ host generation 0 a=candidate:2370331815 1 tcp 1509957375 192.168.112.1 47777 typ host generation 0 a=candidate:2370331815 2 tcp 1509957375 192.168.112.1 47777 typ host generation 0 a=ice-ufrag:6d9sdwyicUWXxuVR a=ice-pwd:iqqO1sPgO/pTOgt1yD1eqF83 a=ice-options:google-ice a=sendrecv a=mid:video a=rtcp-mux a=crypto:1 AES_CM_128_HMAC_SHA1_80 inline:CnYf8+szqtOsTGT3LRtnqzOolnHfAIXByrlm1gLg a=ssrc:2744183418 cname:pvLhMzb2m7ASX0uU a=ssrc:2744183418 msid:zf4MUOMfklOVOx2pSXfJOxivUiCmM7fop3ig v0 a=ssrc:2744183418 mslabel:zf4MUOMfklOVOx2pSXfJOxivUiCmM7fop3ig a=ssrc:2744183418 label:zf4MUOMfklOVOx2pSXfJOxivUiCmM7fop3igv0


Now we get:
  1. SIPClientTransaction:processResponseargu3(): catched exception:TypeError: Cannot call method 'getAddress' of null jain-sip.js:23398
    1. SIPClientTransaction.processResponseargu3jain-sip.js:23398
    2. SIPClientTransaction.processResponsejain-sip.js:23318
    3. SIPClientTransaction.processResponseargu2jain-sip.js:23374
    4. SIPClientTransaction.processResponsejain-sip.js:23311
    5. WSMsgParser.processMessagejain-sip.js:15452
    6. WSMsgParser.parsermessagejain-sip.js:15418
    7. websocket.onmessagejain-sip.js:20644
  1. StringMsgParser:processHeader(): catched exception:TypeError: Object record-route has no method 'concatenate' jain-sip.js:12169
    1. StringMsgParser.processHeaderjain-sip.js:12169
    2. StringMsgParser.parseSIPMessagestringjain-sip.js:11957
    3. StringMsgParser.parseSIPMessagejain-sip.js:11902
    4. WSMsgParser.parsermessagejain-sip.js:15405
    5. websocket.onmessage
jain-sip.js.patch
Reply all
Reply to author
Forward
0 new messages