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

Unified Diff: webrtc/pc/srtpfilter.h

Issue 2734643002: Revert of Improve testing of SRTP external auth code paths. (Closed)
Patch Set: Created 3 years, 10 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/pc/externalhmac.cc ('k') | webrtc/pc/srtpfilter.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/pc/srtpfilter.h
diff --git a/webrtc/pc/srtpfilter.h b/webrtc/pc/srtpfilter.h
index 3df787646c740eb819f93986e697de0daabf1237..46b9dea19f38400abdb38f56cabc2eeece1197fb 100644
--- a/webrtc/pc/srtpfilter.h
+++ b/webrtc/pc/srtpfilter.h
@@ -114,18 +114,12 @@
// Returns srtp overhead for rtp packets.
bool GetSrtpOverhead(int* srtp_overhead) const;
- // If external auth is enabled, SRTP will write a dummy auth tag that then
- // later must get replaced before the packet is sent out. Only supported for
- // non-GCM cipher suites and can be checked through "IsExternalAuthActive"
- // if it is actually used. This method is only valid before the RTP params
- // have been set.
- void EnableExternalAuth();
- bool IsExternalAuthEnabled() const;
-
+#if defined(ENABLE_EXTERNAL_AUTH)
// A SRTP filter supports external creation of the auth tag if a non-GCM
// cipher is used. This method is only valid after the RTP params have
// been set.
bool IsExternalAuthActive() const;
+#endif
// Update the silent threshold (in ms) for signaling errors.
void set_signal_silent_time(int signal_silent_time_in_ms);
@@ -175,9 +169,8 @@
// ST_INIT.
ST_RECEIVEDPRANSWER
};
- State state_ = ST_INIT;
- int signal_silent_time_in_ms_ = 0;
- bool external_auth_enabled_ = false;
+ State state_;
+ int signal_silent_time_in_ms_;
std::vector<CryptoParams> offer_params_;
std::unique_ptr<SrtpSession> send_session_;
std::unique_ptr<SrtpSession> recv_session_;
@@ -220,18 +213,12 @@
int GetSrtpOverhead() const;
- // If external auth is enabled, SRTP will write a dummy auth tag that then
- // later must get replaced before the packet is sent out. Only supported for
- // non-GCM cipher suites and can be checked through "IsExternalAuthActive"
- // if it is actually used. This method is only valid before the RTP params
- // have been set.
- void EnableExternalAuth();
- bool IsExternalAuthEnabled() const;
-
+#if defined(ENABLE_EXTERNAL_AUTH)
// A SRTP session supports external creation of the auth tag if a non-GCM
// cipher is used. This method is only valid after the RTP params have
// been set.
bool IsExternalAuthActive() const;
+#endif
// Update the silent threshold (in ms) for signaling errors.
void set_signal_silent_time(int signal_silent_time_in_ms);
@@ -259,8 +246,9 @@
static bool inited_;
static rtc::GlobalLockPod lock_;
int last_send_seq_num_ = -1;
+#if defined(ENABLE_EXTERNAL_AUTH)
bool external_auth_active_ = false;
- bool external_auth_enabled_ = false;
+#endif
RTC_DISALLOW_COPY_AND_ASSIGN(SrtpSession);
};
« no previous file with comments | « webrtc/pc/externalhmac.cc ('k') | webrtc/pc/srtpfilter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698