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

Side by Side Diff: net/quic/test_tools/delayed_verify_strike_register_client.h

Issue 1535363003: Switch to standard integer types in net/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: stddef 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 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef NET_QUIC_TEST_TOOLS_DELAYED_VERIFY_STRIKE_REGISTER_CLIENT_H_ 5 #ifndef NET_QUIC_TEST_TOOLS_DELAYED_VERIFY_STRIKE_REGISTER_CLIENT_H_
6 #define NET_QUIC_TEST_TOOLS_DELAYED_VERIFY_STRIKE_REGISTER_CLIENT_H_ 6 #define NET_QUIC_TEST_TOOLS_DELAYED_VERIFY_STRIKE_REGISTER_CLIENT_H_
7 7
8 #include <stdint.h>
9
8 #include <string> 10 #include <string>
9 #include <vector> 11 #include <vector>
10 12
13 #include "base/macros.h"
11 #include "base/strings/string_piece.h" 14 #include "base/strings/string_piece.h"
12 #include "net/quic/crypto/local_strike_register_client.h" 15 #include "net/quic/crypto/local_strike_register_client.h"
13 16
14 namespace net { 17 namespace net {
15 namespace test { 18 namespace test {
16 19
17 // Test helper that allows delaying execution of nonce verification 20 // Test helper that allows delaying execution of nonce verification
18 // callbacks until a later time. 21 // callbacks until a later time.
19 class DelayedVerifyStrikeRegisterClient : public LocalStrikeRegisterClient { 22 class DelayedVerifyStrikeRegisterClient : public LocalStrikeRegisterClient {
20 public: 23 public:
21 DelayedVerifyStrikeRegisterClient(unsigned max_entries, 24 DelayedVerifyStrikeRegisterClient(unsigned max_entries,
22 uint32 current_time_external, 25 uint32_t current_time_external,
23 uint32 window_secs, 26 uint32_t window_secs,
24 const uint8 orbit[8], 27 const uint8_t orbit[8],
25 StrikeRegister::StartupType startup); 28 StrikeRegister::StartupType startup);
26 ~DelayedVerifyStrikeRegisterClient() override; 29 ~DelayedVerifyStrikeRegisterClient() override;
27 30
28 void VerifyNonceIsValidAndUnique(base::StringPiece nonce, 31 void VerifyNonceIsValidAndUnique(base::StringPiece nonce,
29 QuicWallTime now, 32 QuicWallTime now,
30 ResultCallback* cb) override; 33 ResultCallback* cb) override;
31 34
32 // Start queueing verifications instead of executing them immediately. 35 // Start queueing verifications instead of executing them immediately.
33 void StartDelayingVerification() { delay_verifications_ = true; } 36 void StartDelayingVerification() { delay_verifications_ = true; }
34 // Number of verifications that are queued. 37 // Number of verifications that are queued.
(...skipping 16 matching lines...) Expand all
51 bool delay_verifications_; 54 bool delay_verifications_;
52 std::vector<VerifyArgs> pending_verifications_; 55 std::vector<VerifyArgs> pending_verifications_;
53 56
54 DISALLOW_COPY_AND_ASSIGN(DelayedVerifyStrikeRegisterClient); 57 DISALLOW_COPY_AND_ASSIGN(DelayedVerifyStrikeRegisterClient);
55 }; 58 };
56 59
57 } // namespace test 60 } // namespace test
58 } // namespace net 61 } // namespace net
59 62
60 #endif // NET_QUIC_TEST_TOOLS_DELAYED_VERIFY_STRIKE_REGISTER_CLIENT_H_ 63 #endif // NET_QUIC_TEST_TOOLS_DELAYED_VERIFY_STRIKE_REGISTER_CLIENT_H_
OLDNEW
« no previous file with comments | « net/quic/test_tools/crypto_test_utils_openssl.cc ('k') | net/quic/test_tools/delayed_verify_strike_register_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698