webrtc/pc
Bjorn A Mellem 8e1343aeda Add an alt-protocol to SDP to indicate which m= sections use a plugin transport.
The plugin transport parameters (a=x-opaque: lines) relate to how to create and
set up a plugin transport.  When SDP bundle is used, the x-opaque line needs to
be copied into the bundled m= section.  This means x-opaque can appear on a
section even if the offerer does not intend to use the transport for the media
described by that section.  Consequently, the answerer cannot currently tell
whether the caller is offering an alternate transport for media, data, or both.

This change adds an a=x-alt-protocol: line to SDP.  The value following this
line matches the <protocol> part of the x-opaque:<protocol>:<params> line.
However, alt-protocol is not bundled--it only ever applies to the m= section
that contains the line.  This allows the offerer to express which m= sections
should actually use an alternate transport, even in the case of bundle.

Note that this is still limited by the available configuration options:
datagram transport can be used for media (audio + video) and/or data.  It is
still not possible to use it for audio but not video, or vice versa.

PeerConnection places an alt-protocol line in each media (audio/video) m=
section if it is configured to use a datagram transport for media.  It places
an alt-protocol line in each data m= section if it is configured to use a
datagram transport for data channels.  PeerConnection leaves alt-protocol in
media (audio/video) m= sections of the answer if it is configured to use a
datagram transport for media, and in data m= sections of the answer if it is
configured to use a datagram transport for data channels.

JsepTransport now negotiates use of the datagram transport independently for
media and data channels.  It only uses it for media if the m= sections for
bundled audio/video have an alt-protocol line matching the x-opaque protocol,
and only uses it for data channels if a bundled m= section for data has an
alt-protocol line matching the x-opaque protocol.

Bug: webrtc:9719
Change-Id: I773e4fc10c57d815afcd76a2a74da38dd0c52b3b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/154763
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Commit-Queue: Bjorn Mellem <mellem@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29351}
2019-09-30 23:10:34 +00:00
..
test Delete almost all default methods on PeerConnectionInterface 2019-09-18 16:27:44 +00:00
audio_rtp_receiver.cc Refactor Rtp Receivers to accept SSRC 0. 2019-09-16 21:29:58 +00:00
audio_rtp_receiver.h Refactor Rtp Receivers to accept SSRC 0. 2019-09-16 21:29:58 +00:00
audio_track.cc Deprecating ThreadChecker specific interface. 2019-04-08 16:58:07 +00:00
audio_track.h Remove rtc_base/scoped_ref_ptr.h. 2019-01-25 20:29:58 +00:00
BUILD.gn Reland "Reland "Refactor SCTP data channels to use DataChannelTransportInterface."" 2019-09-24 17:10:52 +00:00
channel_interface.h Creating Simulcast offer and answer in Peer Connection. 2019-01-28 18:56:02 +00:00
channel_manager_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
channel_manager.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
channel_manager.h Move MediaTransportInterface out of the libjingle_peerconnection_api target 2019-09-13 10:49:56 +00:00
channel_unittest.cc Proxy OnRtcpPacketReceived to the worker thread in channel tests. 2019-09-23 19:59:48 +00:00
channel.cc Only handle each RTCP once. 2019-09-18 16:54:39 +00:00
channel.h Only handle each RTCP once. 2019-09-18 16:54:39 +00:00
composite_data_channel_transport.cc Unset sinks when deleting CompositeDataChannelTransport. 2019-09-24 22:35:44 +00:00
composite_data_channel_transport.h Unset sinks when deleting CompositeDataChannelTransport. 2019-09-24 22:35:44 +00:00
composite_rtp_transport_test.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
composite_rtp_transport.cc Format almost everything. 2019-07-08 13:45:15 +00:00
composite_rtp_transport.h Reland: Implement true negotiation for DatagramTransport with fallback to RTP. 2019-06-07 20:14:36 +00:00
data_channel_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
data_channel.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
data_channel.h Make ID of datachannel stats not depend on dc.id 2019-07-31 13:19:08 +00:00
datagram_rtp_transport.cc Make the RtpHeaderParserImpl available to tests and tools only. 2019-08-29 15:56:40 +00:00
datagram_rtp_transport.h Move MediaTransportInterface out of the libjingle_peerconnection_api target 2019-09-13 10:49:56 +00:00
DEPS Remove +api from internal DEPS files. 2019-01-28 11:17:00 +00:00
dtls_srtp_transport_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
dtls_srtp_transport.cc Format almost everything. 2019-07-08 13:45:15 +00:00
dtls_srtp_transport.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
dtls_transport_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
dtls_transport.cc Expose SSL ciphersuite on the webrtc::DtlsTransport interface 2019-04-12 08:29:59 +00:00
dtls_transport.h Delete unneeded includes of async_invoker.h 2019-04-16 07:28:06 +00:00
dtmf_sender_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
dtmf_sender.cc Format almost everything. 2019-07-08 13:45:15 +00:00
dtmf_sender.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
external_hmac.cc (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
external_hmac.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
ice_server_parsing_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
ice_server_parsing.cc Format almost everything. 2019-07-08 13:45:15 +00:00
ice_server_parsing.h Export symbols needed by the Chromium component build (part 8). 2019-04-02 10:13:36 +00:00
ice_transport_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
ice_transport.cc Fix comment - ice transport is cleared on the networking thread. 2019-04-09 09:12:10 +00:00
ice_transport.h Add IceTransportInterface object 2019-01-30 16:16:51 +00:00
jitter_buffer_delay_interface.h Remove SetLatency/GetLatency from MediaSourceInterface API level 2019-04-18 19:11:31 +00:00
jitter_buffer_delay_proxy.h Remove SetLatency/GetLatency from MediaSourceInterface API level 2019-04-18 19:11:31 +00:00
jitter_buffer_delay_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
jitter_buffer_delay.cc Remove SetLatency/GetLatency from MediaSourceInterface API level 2019-04-18 19:11:31 +00:00
jitter_buffer_delay.h Remove SetLatency/GetLatency from MediaSourceInterface API level 2019-04-18 19:11:31 +00:00
jsep_ice_candidate.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
jsep_session_description_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
jsep_session_description.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
jsep_transport_controller_unittest.cc Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
jsep_transport_controller.cc Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
jsep_transport_controller.h Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
jsep_transport_unittest.cc Reland "Reland "Refactor SCTP data channels to use DataChannelTransportInterface."" 2019-09-24 17:10:52 +00:00
jsep_transport.cc Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
jsep_transport.h Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
local_audio_source_unittest.cc (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
local_audio_source.cc (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
local_audio_source.h Remove rtc_base/scoped_ref_ptr.h. 2019-01-25 20:29:58 +00:00
media_protocol_names.cc Reland "Reland "Version 2 "Refactoring DataContentDescription class""" 2019-05-13 18:37:47 +00:00
media_protocol_names.h Reland "Reland "Version 2 "Refactoring DataContentDescription class""" 2019-05-13 18:37:47 +00:00
media_session_unittest.cc Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
media_session.cc Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
media_session.h Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
media_stream_observer.cc Use Abseil container algorithms in pc/ 2019-01-29 02:33:50 +00:00
media_stream_observer.h Remove rtc_base/scoped_ref_ptr.h. 2019-01-25 20:29:58 +00:00
media_stream_track.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
media_stream_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
media_stream.cc Format almost everything. 2019-07-08 13:45:15 +00:00
media_stream.h Remove rtc_base/scoped_ref_ptr.h. 2019-01-25 20:29:58 +00:00
OWNERS Remove zhihuang@webrtc.org from OWNERS 2019-08-19 22:37:51 +00:00
peer_connection_bundle_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
peer_connection_crypto_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
peer_connection_data_channel_unittest.cc Reland "Reland "Refactor SCTP data channels to use DataChannelTransportInterface."" 2019-09-24 17:10:52 +00:00
peer_connection_end_to_end_unittest.cc Delete AudioDecoder method IncomingPacket 2019-09-24 08:30:24 +00:00
peer_connection_factory_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
peer_connection_factory.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
peer_connection_factory.h Move MediaTransportInterface out of the libjingle_peerconnection_api target 2019-09-13 10:49:56 +00:00
peer_connection_histogram_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
peer_connection_ice_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
peer_connection_integrationtest.cc Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
peer_connection_interface_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
peer_connection_internal.h Use RtpSender/RtpReceiver track ID for legacy GetStats 2019-03-27 18:14:00 +00:00
peer_connection_jsep_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
peer_connection_media_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
peer_connection_rampup_tests.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
peer_connection_rtp_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
peer_connection_signaling_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
peer_connection_simulcast_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
peer_connection_wrapper.cc Format almost everything. 2019-07-08 13:45:15 +00:00
peer_connection_wrapper.h Move rtc::FunctionView to the public API 2019-03-21 15:23:05 +00:00
peer_connection.cc Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
peer_connection.h Allow receive-only use of datagram transport for data channels. 2019-09-26 20:01:06 +00:00
proxy_unittest.cc Fully qualify googletest symbols. 2019-04-09 17:18:20 +00:00
remote_audio_source.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
remote_audio_source.h Remove SetLatency/GetLatency from MediaSourceInterface API level 2019-04-18 19:11:31 +00:00
rtc_stats_collector_unittest.cc Always pass arguments to INSTANTIATE_TEST_SUITE_P. 2019-09-24 08:56:24 +00:00
rtc_stats_collector.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
rtc_stats_collector.h Implement RTCRemoteInboundRtpStreamStats for both audio and video. 2019-05-27 12:45:22 +00:00
rtc_stats_integrationtest.cc Fix rare audioLevel flake in RTCStatsIntegrationTest. 2019-09-13 11:35:22 +00:00
rtc_stats_traversal_unittest.cc Fully qualify googletest symbols. 2019-04-09 17:18:20 +00:00
rtc_stats_traversal.cc Implement RTCRemoteInboundRtpStreamStats for both audio and video. 2019-05-27 12:45:22 +00:00
rtc_stats_traversal.h Remove rtc_base/scoped_ref_ptr.h. 2019-01-25 20:29:58 +00:00
rtcp_mux_filter_unittest.cc (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
rtcp_mux_filter.cc (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
rtcp_mux_filter.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
rtp_media_utils_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
rtp_media_utils.cc Reland "Make negotiationneeded processing in PeerConnection spec compliant." 2019-04-16 12:04:33 +00:00
rtp_media_utils.h Reland "Make negotiationneeded processing in PeerConnection spec compliant." 2019-04-16 12:04:33 +00:00
rtp_parameters_conversion_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
rtp_parameters_conversion.cc Negotiate use of RTCP loss notification feedback (LNTF) 2019-05-24 12:44:14 +00:00
rtp_parameters_conversion.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
rtp_receiver.cc Format almost everything. 2019-07-08 13:45:15 +00:00
rtp_receiver.h Refactor Rtp Receivers to accept SSRC 0. 2019-09-16 21:29:58 +00:00
rtp_sender_receiver_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
rtp_sender.cc Guard GenerateUniqueId() against concurrent access. 2019-07-26 17:52:49 +00:00
rtp_sender.h Add RtpSenderInterface.SetStreams 2019-05-20 18:38:06 +00:00
rtp_transceiver_unittest.cc (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
rtp_transceiver.cc Implement RTCRtpTransceiver.setCodecPreferences 2019-05-01 20:14:59 +00:00
rtp_transceiver.h Implement RTCRtpTransceiver.setCodecPreferences 2019-05-01 20:14:59 +00:00
rtp_transport_internal.h Remove rtp_ and rtcp_packet_transport() from the RtpTransport interface. 2019-05-24 23:58:46 +00:00
rtp_transport_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
rtp_transport.cc Format almost everything. 2019-07-08 13:45:15 +00:00
rtp_transport.h Remove rtp_ and rtcp_packet_transport() from the RtpTransport interface. 2019-05-24 23:58:46 +00:00
sctp_data_channel_transport.cc Reland "Reland "Refactor SCTP data channels to use DataChannelTransportInterface."" 2019-09-24 17:10:52 +00:00
sctp_data_channel_transport.h Reland "Reland "Refactor SCTP data channels to use DataChannelTransportInterface."" 2019-09-24 17:10:52 +00:00
sctp_transport_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
sctp_transport.cc Implement max-channels for SCTP datachannels. 2019-05-21 10:24:41 +00:00
sctp_transport.h Implement max-channels for SCTP datachannels. 2019-05-21 10:24:41 +00:00
sctp_utils_unittest.cc Fully qualify googletest symbols. 2019-04-09 17:18:20 +00:00
sctp_utils.cc Reland "Reland "Refactor SCTP data channels to use DataChannelTransportInterface."" 2019-09-24 17:10:52 +00:00
sctp_utils.h Reland "Reland "Refactor SCTP data channels to use DataChannelTransportInterface."" 2019-09-24 17:10:52 +00:00
sdp_serializer_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
sdp_serializer.cc Reland "Adding a restriction for legal RID values." 2019-04-09 21:19:31 +00:00
sdp_serializer.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
sdp_utils.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
sdp_utils.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
session_description_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
session_description.cc Format almost everything. 2019-07-08 13:45:15 +00:00
session_description.h Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
simulcast_description.cc Format almost everything. 2019-07-08 13:45:15 +00:00
simulcast_description.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
srtp_filter_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
srtp_filter.cc Format almost everything. 2019-07-08 13:45:15 +00:00
srtp_filter.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
srtp_session_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
srtp_session.cc Deprecating ThreadChecker specific interface. 2019-04-08 16:58:07 +00:00
srtp_session.h Remove rtc_base/scoped_ref_ptr.h. 2019-01-25 20:29:58 +00:00
srtp_transport_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
srtp_transport.cc Format almost everything. 2019-07-08 13:45:15 +00:00
srtp_transport.h Format almost everything. 2019-07-08 13:45:15 +00:00
stats_collector_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
stats_collector.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
stats_collector.h Reporting audio device underrun counter 2019-08-16 11:49:55 +00:00
stream_collection.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
track_media_info_map_unittest.cc Split out RtpSource from libjingle_peerconnection_api 2019-09-02 14:04:47 +00:00
track_media_info_map.cc [clang-tidy] Apply performance-for-range-copy fixes. 2019-01-28 09:53:50 +00:00
track_media_info_map.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
transport_stats.cc [clang-tidy] Apply performance-move-const-arg fixes (misc). 2019-02-05 15:12:20 +00:00
transport_stats.h Add support for RTCTransportStats.selectedCandidatePairChanges 2019-08-28 13:22:08 +00:00
used_ids_unittest.cc Always pass arguments to INSTANTIATE_TEST_SUITE_P. 2019-09-24 08:56:24 +00:00
used_ids.h Add support for two-byte RTP header extensions to UsedRtpHeaderExtensionIds 2019-06-24 08:50:07 +00:00
video_rtp_receiver.cc Refactor Rtp Receivers to accept SSRC 0. 2019-09-16 21:29:58 +00:00
video_rtp_receiver.h Refactor Rtp Receivers to accept SSRC 0. 2019-09-16 21:29:58 +00:00
video_track_source.cc Format almost everything. 2019-07-08 13:45:15 +00:00
video_track_source.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
video_track_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
video_track.cc Format almost everything. 2019-07-08 13:45:15 +00:00
video_track.h Remove rtc_base/scoped_ref_ptr.h. 2019-01-25 20:29:58 +00:00
webrtc_sdp_unittest.cc Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
webrtc_sdp.cc Add an alt-protocol to SDP to indicate which m= sections use a plugin transport. 2019-09-30 23:10:34 +00:00
webrtc_sdp.h Export symbols needed by the Chromium component build (part 8). 2019-04-02 10:13:36 +00:00
webrtc_session_description_factory.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
webrtc_session_description_factory.h Format almost everything. 2019-07-08 13:45:15 +00:00