diff options
author | Daniel Cheng <dcheng@chromium.org> | 2021-11-10 23:13:54 +0000 |
---|---|---|
committer | Michal Klocek <michal.klocek@qt.io> | 2022-07-25 07:37:20 +0000 |
commit | 1c316daff337ed065e66e42141d60209a957be22 (patch) | |
tree | 1012b6cbd8609ae99a1a030189ae3cc2064ed8eb | |
parent | bb8a10a90551248e5da3d569a6f3731a5a47a968 (diff) | |
download | qtwebengine-chromium-1c316daff337ed065e66e42141d60209a957be22.tar.gz |
[Backport] Make base::UnguessableToken::operator!= constant time.
This is a followup to https://crrev.com/c/3023887, which made operator==
constant time by using BoringSSL helpers. The same CL also aimed to make
operator!= constant time, but accidentally delegated to base::Token's
operator== which is not constant time.
Patch reviewed on: https://chromium-review.googlesource.com/c/chromium/src/+/3269926
Bug: 1004921
Task-number: QTBUG-104477
Change-Id: Ieda8fb6a736ced143831d9bcde75cddaaff50243
Reviewed-by: Marc Mutz <marc.mutz@qt.io>
-rw-r--r-- | chromium/base/unguessable_token.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/chromium/base/unguessable_token.h b/chromium/base/unguessable_token.h index 83a22862608..20e6569f992 100644 --- a/chromium/base/unguessable_token.h +++ b/chromium/base/unguessable_token.h @@ -100,7 +100,7 @@ class BASE_EXPORT UnguessableToken { bool operator==(const UnguessableToken& other) const; bool operator!=(const UnguessableToken& other) const { - return !(token_ == other.token_); + return !(*this == other); } private: |