OLD | NEW |
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_CRYPTO_STRIKE_REGISTER_CLIENT_H_ | 5 #ifndef NET_QUIC_CRYPTO_STRIKE_REGISTER_CLIENT_H_ |
6 #define NET_QUIC_CRYPTO_STRIKE_REGISTER_CLIENT_H_ | 6 #define NET_QUIC_CRYPTO_STRIKE_REGISTER_CLIENT_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 26 matching lines...) Expand all Loading... |
37 }; | 37 }; |
38 | 38 |
39 StrikeRegisterClient() {} | 39 StrikeRegisterClient() {} |
40 virtual ~StrikeRegisterClient() {} | 40 virtual ~StrikeRegisterClient() {} |
41 | 41 |
42 // Returns true iff the strike register knows about the given orbit. | 42 // Returns true iff the strike register knows about the given orbit. |
43 virtual bool IsKnownOrbit(base::StringPiece orbit) const = 0; | 43 virtual bool IsKnownOrbit(base::StringPiece orbit) const = 0; |
44 // Validate a nonce for freshness and uniqueness. | 44 // Validate a nonce for freshness and uniqueness. |
45 // Will invoke cb->Run(ValidateResponse::nonce_is_valid_and_unique()) | 45 // Will invoke cb->Run(ValidateResponse::nonce_is_valid_and_unique()) |
46 // once the asynchronous operation is complete. | 46 // once the asynchronous operation is complete. |
47 virtual void VerifyNonceIsValidAndUnique( | 47 virtual void VerifyNonceIsValidAndUnique(base::StringPiece nonce, |
48 base::StringPiece nonce, | 48 QuicWallTime now, |
49 QuicWallTime now, | 49 ResultCallback* cb) = 0; |
50 ResultCallback* cb) = 0; | |
51 | 50 |
52 private: | 51 private: |
53 DISALLOW_COPY_AND_ASSIGN(StrikeRegisterClient); | 52 DISALLOW_COPY_AND_ASSIGN(StrikeRegisterClient); |
54 }; | 53 }; |
55 | 54 |
56 } // namespace net | 55 } // namespace net |
57 | 56 |
58 #endif // NET_QUIC_CRYPTO_STRIKE_REGISTER_CLIENT_H_ | 57 #endif // NET_QUIC_CRYPTO_STRIKE_REGISTER_CLIENT_H_ |
OLD | NEW |