JavaScript Session Establishment Protocol
lastmod 2021-10-24created 2021-02-037 edits
This document describes the mechanisms for allowing a Javascript application to fully control the signaling plane of a multimedia session via the interface specified in the W3C RTCPeerConnection API, and discusses how this relates to existing signaling protocols.
Simple diagram
- [Recommended] Build the backend services needed for a WebRTC app: STUN, TURN, and signaling - HTML5 Rocks
Jsep-diagram.png
JESP requires the exchange of offers and answers between endpoints (peers), as follows. The media metadata mentioned above. The offers and answers are in the 'Session Description Protocol (SDP)' format, as follows.
v=0
o=- 7614219274584779017 2 IN IP4 127.0.0.1
s=-
t=0 0
a=group:BUNDLE audio video
a=msid-semantic: WMS
m=audio 1 RTP/SAVPF 111 103 104 0 8 107 106 105 13 126
c=IN IP4 0.0.0.0
a=rtcp:1 IN IP4 0.0.0.0
a=ice-ufrag:W2TGCZw2NZHuwlnf
a=ice-pwd:xdQEccP40E+P0L5qTyzDgfmW
a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level
a=mid:audio
a=rtcp-mux
a=crypto:1 AES_CM_128_HMAC_SHA1_80 inline:9c1AHz27dZ9xPI91YNfSlI67/EMkjHHIHORiClQe
a=rtpmap:111 opus/48000/2
…
Simple exchange sequence
WebRTC_Signaling_scenario.jpeg
Signaling transaction flow
- [Recommended] Signaling and video calling - Web API | MDN
WebRTC_-_Signaling_Diagram.png
Documentation
- Javascript Session Establishment Protocol draft-ietf-rtcweb-jsep-03
- https://tools.ietf.org/html/draft-ietf-rtcweb-jsep-03
See also
Favorite site
- [Recommended] WebRTC connectivity - Web APIs | MDN WebRTC connectivity
- [Recommended] The Frozen Mountain iRTC White Paper Series - The Role of Signaling 1 (with annotations for each SDP field)
- WebRTC Signaling explained
- [Recommended] JavaScript Session Establishment Protocol (JSEP) in WebRTC handshake 2 - Also explains SDP contents.