Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7)

Side by Side Diff: talk/session/media/mediasession.h

Issue 1528843005: Add support for GCM cipher suites from RFC 7714. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Added PeerConnection tests using GCM ciphers, fixed passing of flag through DtlsTransportChannel. Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * libjingle 2 * libjingle
3 * Copyright 2004 Google Inc. 3 * Copyright 2004 Google Inc.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are met: 6 * modification, are permitted provided that the following conditions are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright notice, 8 * 1. Redistributions of source code must retain the above copyright notice,
9 * this list of conditions and the following disclaimer. 9 * this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright notice, 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 struct MediaSessionOptions { 96 struct MediaSessionOptions {
97 MediaSessionOptions() : 97 MediaSessionOptions() :
98 recv_audio(true), 98 recv_audio(true),
99 recv_video(false), 99 recv_video(false),
100 data_channel_type(DCT_NONE), 100 data_channel_type(DCT_NONE),
101 is_muc(false), 101 is_muc(false),
102 vad_enabled(true), // When disabled, removes all CN codecs from SDP. 102 vad_enabled(true), // When disabled, removes all CN codecs from SDP.
103 rtcp_mux_enabled(true), 103 rtcp_mux_enabled(true),
104 bundle_enabled(false), 104 bundle_enabled(false),
105 video_bandwidth(kAutoBandwidth), 105 video_bandwidth(kAutoBandwidth),
106 data_bandwidth(kDataMaxBandwidth) { 106 data_bandwidth(kDataMaxBandwidth),
107 enable_gcm_ciphers(false) {
pthatcher1 2015/12/18 20:31:32 Same here: can you change it to enable_gcm_crypto_
joachim 2015/12/19 15:26:23 Done.
107 } 108 }
108 109
109 bool has_audio() const { 110 bool has_audio() const {
110 return recv_audio || HasSendMediaStream(MEDIA_TYPE_AUDIO); 111 return recv_audio || HasSendMediaStream(MEDIA_TYPE_AUDIO);
111 } 112 }
112 bool has_video() const { 113 bool has_video() const {
113 return recv_video || HasSendMediaStream(MEDIA_TYPE_VIDEO); 114 return recv_video || HasSendMediaStream(MEDIA_TYPE_VIDEO);
114 } 115 }
115 bool has_data() const { return data_channel_type != DCT_NONE; } 116 bool has_data() const { return data_channel_type != DCT_NONE; }
116 117
(...skipping 20 matching lines...) Expand all
137 bool recv_audio; 138 bool recv_audio;
138 bool recv_video; 139 bool recv_video;
139 DataChannelType data_channel_type; 140 DataChannelType data_channel_type;
140 bool is_muc; 141 bool is_muc;
141 bool vad_enabled; 142 bool vad_enabled;
142 bool rtcp_mux_enabled; 143 bool rtcp_mux_enabled;
143 bool bundle_enabled; 144 bool bundle_enabled;
144 // bps. -1 == auto. 145 // bps. -1 == auto.
145 int video_bandwidth; 146 int video_bandwidth;
146 int data_bandwidth; 147 int data_bandwidth;
148 bool enable_gcm_ciphers;
147 TransportOptions transport_options; 149 TransportOptions transport_options;
148 150
149 struct Stream { 151 struct Stream {
150 Stream(MediaType type, 152 Stream(MediaType type,
151 const std::string& id, 153 const std::string& id,
152 const std::string& sync_label, 154 const std::string& sync_label,
153 int num_sim_layers) 155 int num_sim_layers)
154 : type(type), id(id), sync_label(sync_label), 156 : type(type), id(id), sync_label(sync_label),
155 num_sim_layers(num_sim_layers) { 157 num_sim_layers(num_sim_layers) {
156 } 158 }
(...skipping 391 matching lines...) Expand 10 before | Expand all | Expand 10 after
548 void GetSupportedDataCryptoSuites(std::vector<int>* crypto_suites); 550 void GetSupportedDataCryptoSuites(std::vector<int>* crypto_suites);
549 void GetDefaultSrtpCryptoSuites(std::vector<int>* crypto_suites); 551 void GetDefaultSrtpCryptoSuites(std::vector<int>* crypto_suites);
550 void GetSupportedAudioCryptoSuiteNames( 552 void GetSupportedAudioCryptoSuiteNames(
551 std::vector<std::string>* crypto_suite_names); 553 std::vector<std::string>* crypto_suite_names);
552 void GetSupportedVideoCryptoSuiteNames( 554 void GetSupportedVideoCryptoSuiteNames(
553 std::vector<std::string>* crypto_suite_names); 555 std::vector<std::string>* crypto_suite_names);
554 void GetSupportedDataCryptoSuiteNames( 556 void GetSupportedDataCryptoSuiteNames(
555 std::vector<std::string>* crypto_suite_names); 557 std::vector<std::string>* crypto_suite_names);
556 void GetDefaultSrtpCryptoSuiteNames( 558 void GetDefaultSrtpCryptoSuiteNames(
557 std::vector<std::string>* crypto_suite_names); 559 std::vector<std::string>* crypto_suite_names);
560 void FilterGcmCiphers(std::vector<int>* crypto_suites);
561 void FilterGcmCipherNames(std::vector<std::string>* crypto_suites);
558 562
559 } // namespace cricket 563 } // namespace cricket
560 564
561 #endif // TALK_SESSION_MEDIA_MEDIASESSION_H_ 565 #endif // TALK_SESSION_MEDIA_MEDIASESSION_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698