Comments (12)
@iwanbk, you can specifiy the full ws uri in the demo web. No need to modify the code for that.
Please, specify the full string of the ws uri within the demo web: ws://my.domain.com:4062
from jssip.
@jmillan
Hi, i modify the code because i thought it failed because jssip automatically convert ws://my.domain.com:4062 to ws://my.domain.com:4062/ (add a trailing slash).
And just realized that it still works with kamailio even with trailing slash.
Btw, have you tested jssip with webrtc2sip?
from jssip.
@iwanbk The URI ws://my.domain.com:4062/
is 100% valid, so if webrtc2sip fails to parse it there is a bug in webrtc2sip, not in JsSIP ;)
from jssip.
Closing the issue since it's not a bug in JsSIP but in a 3rd party server.
from jssip.
@ibc
Sorry if i was not clear.
Even with ws://my.domain.com:4062 (without trailing slash), it is not work.
You can see again my javascript console message, there is no trailing slash.
from jssip.
This is error message from webrtc2sip
WARNING | 20121017-110236.991 | repro | RESIP:TRANSPORT | 140109811562240 | ConnectionBase.cxx:320 | Malformed Content-Length in connection-based transport. Not much we can do to fix this. SipMessage::Exception Missing header Content-Length @ SipMessage.cxx:1371
WARNING | 20121017-110238.024 | repro | RESIP:TRANSPORT | 140109811562240 | ConnectionBase.cxx:320 | Malformed Content-Length in connection-based transport. Not much we can do to fix this. SipMessage::Exception Missing header Content-Length @ SipMessage.cxx:1371
from jssip.
JsSIP does not add a Content-Length header since it's not mandatory (WebSocket it's a message boundary transport). See http://tools.ietf.org/html/draft-ietf-sipcore-sip-websocket-04#section-5.1
5.1. General
Each SIP message MUST be carried within a single WebSocket message,
and a WebSocket message MUST NOT contain more than one SIP message.
Because the WebSocket transport preserves message boundaries, the use
of the Content-Length header in SIP messages is optional when they
are transported using the WebSocket sub-protocol.
So it's a bug in webrtc2sip server.
from jssip.
Yeah,
As per section 5.1 in http://tools.ietf.org/html/draft-ietf-sipcore-sip-websocket-04, the Content-Length header in a SIP message is optional when using WebSocket as transport. It is hence a bug in webrtc2sip, which should respect a SIP message without such a header.
from jssip.
I've reported the bug in webrtc2sip server: http://code.google.com/p/webrtc2sip/issues/detail?id=5
Please follow it ;)
from jssip.
@jmillan Even if it's optional, does it hurt to send it? If it helps I'd be all for it.
from jssip.
JsSIP master now adds always a Content-Lenght header (regardless it's not mandatory). Let's make happy buggy servers from 3rd parties.
from jssip.
🍰
from jssip.
Related Issues (20)
- Make a call with error 488 Not Acceptable Here How to fix it HOT 1
- JsSIP Logger Override Functionality Not Working As Expected in v3.7.7 HOT 1
- UnMute Call HOT 2
- How not to get microphone permission HOT 1
- For SIP server Account Register Working? HOT 2
- Abnormal session cancellation method under race condition
- Type definition errors in 3.10.0 HOT 1
- Error when getting video track status on Firefox
- Play audio or tone to remote user. HOT 2
- The new JsSIP.UA(configuration).call method does not return the status after execution
- import JsSIP from "jssip"; 打印JsSIP undefined HOT 2
- Error 'setLocalDescription' on Chrome HOT 1
- BYE: Request-URI does not point to us HOT 33
- Incorrect SDP a=sendrecv in firefox HOT 7
- I want to send and Receive message using JSSIP
- Sending a silent stream on latest Chrome HOT 1
- Error when trying to change the microphone during a call HOT 1
- Add custom header JsSIP - Asterisk HOT 1
- JsSIP processing re-INVITE HOT 1
- SDP is cut off between recieving 200 OK and the sdp event being emitted
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jssip.