Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright 2015 The WebRTC Project Authors. All rights reserved. | 2 * Copyright 2015 The WebRTC Project Authors. All rights reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| (...skipping 24 matching lines...) Expand all Loading... | |
| 35 } | 35 } |
| 36 | 36 |
| 37 namespace cricket { | 37 namespace cricket { |
| 38 | 38 |
| 39 class TransportController : public sigslot::has_slots<>, | 39 class TransportController : public sigslot::has_slots<>, |
| 40 public rtc::MessageHandler { | 40 public rtc::MessageHandler { |
| 41 public: | 41 public: |
| 42 // If |redetermine_role_on_ice_restart| is true, ICE role is redetermined | 42 // If |redetermine_role_on_ice_restart| is true, ICE role is redetermined |
| 43 // upon setting a local transport description that indicates an ICE restart. | 43 // upon setting a local transport description that indicates an ICE restart. |
| 44 // For the constructor that doesn't take this parameter, it defaults to true. | 44 // For the constructor that doesn't take this parameter, it defaults to true. |
| 45 // | |
| 46 // |crypto_options| is used to determine if created DTLS transports negotiate | |
| 47 // GCM crypto suites or not. | |
| 45 TransportController(rtc::Thread* signaling_thread, | 48 TransportController(rtc::Thread* signaling_thread, |
| 46 rtc::Thread* network_thread, | 49 rtc::Thread* network_thread, |
| 47 PortAllocator* port_allocator, | 50 PortAllocator* port_allocator, |
| 48 bool redetermine_role_on_ice_restart); | 51 bool redetermine_role_on_ice_restart, |
| 49 | 52 const rtc::CryptoOptions& crypto_options); |
| 50 TransportController(rtc::Thread* signaling_thread, | |
| 51 rtc::Thread* network_thread, | |
| 52 PortAllocator* port_allocator); | |
| 53 | 53 |
| 54 virtual ~TransportController(); | 54 virtual ~TransportController(); |
| 55 | 55 |
| 56 rtc::Thread* signaling_thread() const { return signaling_thread_; } | 56 rtc::Thread* signaling_thread() const { return signaling_thread_; } |
| 57 rtc::Thread* network_thread() const { return network_thread_; } | 57 rtc::Thread* network_thread() const { return network_thread_; } |
| 58 | 58 |
| 59 PortAllocator* port_allocator() const { return port_allocator_; } | 59 PortAllocator* port_allocator() const { return port_allocator_; } |
| 60 | 60 |
| 61 // Can only be set before transports are created. | 61 // Can only be set before transports are created. |
| 62 // TODO(deadbeef): Make this an argument to the constructor once BaseSession | 62 // TODO(deadbeef): Make this an argument to the constructor once BaseSession |
| (...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 255 | 255 |
| 256 // Aggregate state for TransportChannelImpls. | 256 // Aggregate state for TransportChannelImpls. |
| 257 IceConnectionState connection_state_ = kIceConnectionConnecting; | 257 IceConnectionState connection_state_ = kIceConnectionConnecting; |
| 258 bool receiving_ = false; | 258 bool receiving_ = false; |
| 259 IceGatheringState gathering_state_ = kIceGatheringNew; | 259 IceGatheringState gathering_state_ = kIceGatheringNew; |
| 260 | 260 |
| 261 IceConfig ice_config_; | 261 IceConfig ice_config_; |
| 262 IceRole ice_role_ = ICEROLE_CONTROLLING; | 262 IceRole ice_role_ = ICEROLE_CONTROLLING; |
| 263 bool redetermine_role_on_ice_restart_; | 263 bool redetermine_role_on_ice_restart_; |
| 264 uint64_t ice_tiebreaker_ = rtc::CreateRandomId64(); | 264 uint64_t ice_tiebreaker_ = rtc::CreateRandomId64(); |
| 265 rtc::CryptoOptions crypto_options_; | |
| 265 rtc::SSLProtocolVersion ssl_max_version_ = rtc::SSL_PROTOCOL_DTLS_12; | 266 rtc::SSLProtocolVersion ssl_max_version_ = rtc::SSL_PROTOCOL_DTLS_12; |
|
pthatcher1
2017/04/17 22:12:41
Should we move ssl_max_version_ into CryptoOptions
Taylor Brandstetter
2017/04/20 07:20:40
Seems like a good idea (though for a separate CL).
| |
| 266 rtc::scoped_refptr<rtc::RTCCertificate> certificate_; | 267 rtc::scoped_refptr<rtc::RTCCertificate> certificate_; |
| 267 rtc::AsyncInvoker invoker_; | 268 rtc::AsyncInvoker invoker_; |
| 268 // True if QUIC is used instead of DTLS. | 269 // True if QUIC is used instead of DTLS. |
| 269 bool quic_ = false; | 270 bool quic_ = false; |
| 270 | 271 |
| 271 webrtc::MetricsObserverInterface* metrics_observer_ = nullptr; | 272 webrtc::MetricsObserverInterface* metrics_observer_ = nullptr; |
| 272 | 273 |
| 273 RTC_DISALLOW_COPY_AND_ASSIGN(TransportController); | 274 RTC_DISALLOW_COPY_AND_ASSIGN(TransportController); |
| 274 }; | 275 }; |
| 275 | 276 |
| 276 } // namespace cricket | 277 } // namespace cricket |
| 277 | 278 |
| 278 #endif // WEBRTC_P2P_BASE_TRANSPORTCONTROLLER_H_ | 279 #endif // WEBRTC_P2P_BASE_TRANSPORTCONTROLLER_H_ |
| OLD | NEW |