OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2011 The WebRTC Project Authors. All rights reserved. | 2 * Copyright 2011 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 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
116 return channel_->GetOption(opt, value); | 116 return channel_->GetOption(opt, value); |
117 } | 117 } |
118 int GetError() override { return channel_->GetError(); } | 118 int GetError() override { return channel_->GetError(); } |
119 bool GetStats(ConnectionInfos* infos) override { | 119 bool GetStats(ConnectionInfos* infos) override { |
120 return channel_->GetStats(infos); | 120 return channel_->GetStats(infos); |
121 } | 121 } |
122 const std::string SessionId() const override { return channel_->SessionId(); } | 122 const std::string SessionId() const override { return channel_->SessionId(); } |
123 | 123 |
124 virtual bool SetSslMaxProtocolVersion(rtc::SSLProtocolVersion version); | 124 virtual bool SetSslMaxProtocolVersion(rtc::SSLProtocolVersion version); |
125 | 125 |
| 126 virtual bool SetEnableGcmCiphers(bool enable); |
| 127 |
| 128 bool IsEnableGcmCiphers() const override; |
| 129 |
126 // Set up the ciphers to use for DTLS-SRTP. If this method is not called | 130 // Set up the ciphers to use for DTLS-SRTP. If this method is not called |
127 // before DTLS starts, or |ciphers| is empty, SRTP keys won't be negotiated. | 131 // before DTLS starts, or |ciphers| is empty, SRTP keys won't be negotiated. |
128 // This method should be called before SetupDtls. | 132 // This method should be called before SetupDtls. |
129 bool SetSrtpCryptoSuites(const std::vector<int>& ciphers) override; | 133 bool SetSrtpCryptoSuites(const std::vector<int>& ciphers) override; |
130 | 134 |
131 // Find out which DTLS-SRTP cipher was negotiated | 135 // Find out which DTLS-SRTP cipher was negotiated |
132 bool GetSrtpCryptoSuite(int* cipher) override; | 136 bool GetSrtpCryptoSuite(int* cipher) override; |
133 | 137 |
134 bool GetSslRole(rtc::SSLRole* role) const override; | 138 bool GetSslRole(rtc::SSLRole* role) const override; |
135 bool SetSslRole(rtc::SSLRole role) override; | 139 bool SetSslRole(rtc::SSLRole role) override; |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
222 rtc::Thread* worker_thread_; // Everything should occur on this thread. | 226 rtc::Thread* worker_thread_; // Everything should occur on this thread. |
223 // Underlying channel, owned by transport_. | 227 // Underlying channel, owned by transport_. |
224 TransportChannelImpl* const channel_; | 228 TransportChannelImpl* const channel_; |
225 rtc::scoped_ptr<rtc::SSLStreamAdapter> dtls_; // The DTLS stream | 229 rtc::scoped_ptr<rtc::SSLStreamAdapter> dtls_; // The DTLS stream |
226 StreamInterfaceChannel* downward_; // Wrapper for channel_, owned by dtls_. | 230 StreamInterfaceChannel* downward_; // Wrapper for channel_, owned by dtls_. |
227 std::vector<int> srtp_ciphers_; // SRTP ciphers to use with DTLS. | 231 std::vector<int> srtp_ciphers_; // SRTP ciphers to use with DTLS. |
228 bool dtls_active_ = false; | 232 bool dtls_active_ = false; |
229 rtc::scoped_refptr<rtc::RTCCertificate> local_certificate_; | 233 rtc::scoped_refptr<rtc::RTCCertificate> local_certificate_; |
230 rtc::SSLRole ssl_role_; | 234 rtc::SSLRole ssl_role_; |
231 rtc::SSLProtocolVersion ssl_max_version_; | 235 rtc::SSLProtocolVersion ssl_max_version_; |
| 236 bool enable_gcm_ciphers_; |
232 rtc::Buffer remote_fingerprint_value_; | 237 rtc::Buffer remote_fingerprint_value_; |
233 std::string remote_fingerprint_algorithm_; | 238 std::string remote_fingerprint_algorithm_; |
234 | 239 |
235 RTC_DISALLOW_COPY_AND_ASSIGN(DtlsTransportChannelWrapper); | 240 RTC_DISALLOW_COPY_AND_ASSIGN(DtlsTransportChannelWrapper); |
236 }; | 241 }; |
237 | 242 |
238 } // namespace cricket | 243 } // namespace cricket |
239 | 244 |
240 #endif // WEBRTC_P2P_BASE_DTLSTRANSPORTCHANNEL_H_ | 245 #endif // WEBRTC_P2P_BASE_DTLSTRANSPORTCHANNEL_H_ |
OLD | NEW |