OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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_QUIC_CRYPTO_SERVER_CONFIG_PEER_H_ | 5 #ifndef NET_QUIC_TEST_TOOLS_QUIC_CRYPTO_SERVER_CONFIG_PEER_H_ |
6 #define NET_QUIC_TEST_TOOLS_QUIC_CRYPTO_SERVER_CONFIG_PEER_H_ | 6 #define NET_QUIC_TEST_TOOLS_QUIC_CRYPTO_SERVER_CONFIG_PEER_H_ |
7 | 7 |
8 #include "net/quic/core/crypto/quic_crypto_server_config.h" | 8 #include "net/quic/core/crypto/quic_crypto_server_config.h" |
9 | 9 |
10 namespace net { | 10 namespace net { |
11 namespace test { | 11 namespace test { |
12 | 12 |
13 // Peer for accessing otherwise private members of a QuicCryptoServerConfig. | 13 // Peer for accessing otherwise private members of a QuicCryptoServerConfig. |
14 class QuicCryptoServerConfigPeer { | 14 class QuicCryptoServerConfigPeer { |
15 public: | 15 public: |
16 explicit QuicCryptoServerConfigPeer( | 16 explicit QuicCryptoServerConfigPeer( |
17 const QuicCryptoServerConfig* server_config) | 17 const QuicCryptoServerConfig* server_config) |
18 : server_config_(server_config) {} | 18 : server_config_(server_config) {} |
19 | 19 |
| 20 // Returns the proof source. |
| 21 ProofSource* GetProofSource(); |
| 22 |
20 // Returns the primary config. | 23 // Returns the primary config. |
21 scoped_refptr<QuicCryptoServerConfig::Config> GetPrimaryConfig(); | 24 scoped_refptr<QuicCryptoServerConfig::Config> GetPrimaryConfig(); |
22 | 25 |
23 // Returns the config associated with |config_id|. | 26 // Returns the config associated with |config_id|. |
24 scoped_refptr<QuicCryptoServerConfig::Config> GetConfig( | 27 scoped_refptr<QuicCryptoServerConfig::Config> GetConfig( |
25 std::string config_id); | 28 std::string config_id); |
26 | 29 |
27 // Generates a new valid source address token. | 30 // Generates a new valid source address token. |
28 std::string NewSourceAddressToken( | 31 std::string NewSourceAddressToken( |
29 std::string config_id, | 32 std::string config_id, |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 uint32_t server_nonce_strike_register_window_secs(); | 100 uint32_t server_nonce_strike_register_window_secs(); |
98 | 101 |
99 private: | 102 private: |
100 const QuicCryptoServerConfig* server_config_; | 103 const QuicCryptoServerConfig* server_config_; |
101 }; | 104 }; |
102 | 105 |
103 } // namespace test | 106 } // namespace test |
104 } // namespace net | 107 } // namespace net |
105 | 108 |
106 #endif // NET_QUIC_TEST_TOOLS_QUIC_CRYPTO_SERVER_CONFIG_PEER_H_ | 109 #endif // NET_QUIC_TEST_TOOLS_QUIC_CRYPTO_SERVER_CONFIG_PEER_H_ |
OLD | NEW |