| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_CORE_QUIC_CRYPTO_SERVER_STREAM_H_ | 5 #ifndef NET_QUIC_CORE_QUIC_CRYPTO_SERVER_STREAM_H_ |
| 6 #define NET_QUIC_CORE_QUIC_CRYPTO_SERVER_STREAM_H_ | 6 #define NET_QUIC_CORE_QUIC_CRYPTO_SERVER_STREAM_H_ |
| 7 | 7 |
| 8 #include <cstdint> | 8 #include <cstdint> |
| 9 #include <memory> | 9 #include <memory> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 130 virtual void ProcessClientHello( | 130 virtual void ProcessClientHello( |
| 131 QuicReferenceCountedPointer<ValidateClientHelloResultCallback::Result> | 131 QuicReferenceCountedPointer<ValidateClientHelloResultCallback::Result> |
| 132 result, | 132 result, |
| 133 std::unique_ptr<ProofSource::Details> proof_source_details, | 133 std::unique_ptr<ProofSource::Details> proof_source_details, |
| 134 std::unique_ptr<ProcessClientHelloResultCallback> done_cb); | 134 std::unique_ptr<ProcessClientHelloResultCallback> done_cb); |
| 135 | 135 |
| 136 // Hook that allows the server to set QuicConfig defaults just | 136 // Hook that allows the server to set QuicConfig defaults just |
| 137 // before going through the parameter negotiation step. | 137 // before going through the parameter negotiation step. |
| 138 virtual void OverrideQuicConfigDefaults(QuicConfig* config); | 138 virtual void OverrideQuicConfigDefaults(QuicConfig* config); |
| 139 | 139 |
| 140 // Returns client address used to generate and validate source address token. |
| 141 virtual const QuicSocketAddress GetClientAddress(); |
| 142 |
| 140 private: | 143 private: |
| 141 friend class test::QuicCryptoServerStreamPeer; | 144 friend class test::QuicCryptoServerStreamPeer; |
| 142 | 145 |
| 143 class ValidateCallback : public ValidateClientHelloResultCallback { | 146 class ValidateCallback : public ValidateClientHelloResultCallback { |
| 144 public: | 147 public: |
| 145 explicit ValidateCallback(QuicCryptoServerStream* parent); | 148 explicit ValidateCallback(QuicCryptoServerStream* parent); |
| 146 // To allow the parent to detach itself from the callback before deletion. | 149 // To allow the parent to detach itself from the callback before deletion. |
| 147 void Cancel(); | 150 void Cancel(); |
| 148 | 151 |
| 149 // From ValidateClientHelloResultCallback | 152 // From ValidateClientHelloResultCallback |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 274 // FinishProcessingHandshakeMessageAfterProcessClientHello. Note that this | 277 // FinishProcessingHandshakeMessageAfterProcessClientHello. Note that this |
| 275 // field is mutually exclusive with validate_client_hello_cb_. | 278 // field is mutually exclusive with validate_client_hello_cb_. |
| 276 ProcessClientHelloCallback* process_client_hello_cb_; | 279 ProcessClientHelloCallback* process_client_hello_cb_; |
| 277 | 280 |
| 278 DISALLOW_COPY_AND_ASSIGN(QuicCryptoServerStream); | 281 DISALLOW_COPY_AND_ASSIGN(QuicCryptoServerStream); |
| 279 }; | 282 }; |
| 280 | 283 |
| 281 } // namespace net | 284 } // namespace net |
| 282 | 285 |
| 283 #endif // NET_QUIC_CORE_QUIC_CRYPTO_SERVER_STREAM_H_ | 286 #endif // NET_QUIC_CORE_QUIC_CRYPTO_SERVER_STREAM_H_ |
| OLD | NEW |