Chromium Code Reviews| 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 REMOTING_PROTOCOL_NEGOTIATING_AUTHENTICATOR_BASE_H_ | 5 #ifndef REMOTING_PROTOCOL_NEGOTIATING_AUTHENTICATOR_BASE_H_ |
| 6 #define REMOTING_PROTOCOL_NEGOTIATING_AUTHENTICATOR_BASE_H_ | 6 #define REMOTING_PROTOCOL_NEGOTIATING_AUTHENTICATOR_BASE_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 60 // * The host never sends its own supported methods back to the client, so once | 60 // * The host never sends its own supported methods back to the client, so once |
| 61 // the host picks a method from the client's list, it's final. | 61 // the host picks a method from the client's list, it's final. |
| 62 // * Any change in this class must maintain compatibility between any version | 62 // * Any change in this class must maintain compatibility between any version |
| 63 // mix of webapp, client plugin and host, for both Me2Me and IT2Me. | 63 // mix of webapp, client plugin and host, for both Me2Me and IT2Me. |
| 64 class NegotiatingAuthenticatorBase : public Authenticator { | 64 class NegotiatingAuthenticatorBase : public Authenticator { |
| 65 public: | 65 public: |
| 66 // Method represents an authentication algorithm. | 66 // Method represents an authentication algorithm. |
| 67 enum class Method { | 67 enum class Method { |
| 68 INVALID, | 68 INVALID, |
| 69 | 69 |
| 70 // SPAKE2 with P224 using access code in plain-text. Used for It2Me. | |
| 71 // TODO(sergeyu): Remove and use SHARED_SECRET_SPAKE2_CURVE25519. | |
|
kelvinp
2016/05/03 00:22:36
Maybe update the comment saying that this cannot b
Jamie
2016/05/03 00:33:27
Done.
| |
| 72 SHARED_SECRET_PLAIN_SPAKE2_P224, | |
| 73 | |
| 70 // SPAKE2 PIN or access code hashed with host_id using HMAC-SHA256. | 74 // SPAKE2 PIN or access code hashed with host_id using HMAC-SHA256. |
| 71 SHARED_SECRET_SPAKE2_P224, | 75 SHARED_SECRET_SPAKE2_P224, |
| 72 SHARED_SECRET_SPAKE2_CURVE25519, | 76 SHARED_SECRET_SPAKE2_CURVE25519, |
| 73 | 77 |
| 74 // SPAKE2 using shared pairing secret. Falls back to PIN-based | 78 // SPAKE2 using shared pairing secret. Falls back to PIN-based |
| 75 // authentication when pairing fails. | 79 // authentication when pairing fails. |
| 76 PAIRED_SPAKE2_P224, | 80 PAIRED_SPAKE2_P224, |
| 77 PAIRED_SPAKE2_CURVE25519, | 81 PAIRED_SPAKE2_CURVE25519, |
| 78 | 82 |
| 79 // Authentication using third-party authentication server. | 83 // Authentication using third-party authentication server. |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 134 RejectionReason rejection_reason_ = INVALID_CREDENTIALS; | 138 RejectionReason rejection_reason_ = INVALID_CREDENTIALS; |
| 135 | 139 |
| 136 private: | 140 private: |
| 137 DISALLOW_COPY_AND_ASSIGN(NegotiatingAuthenticatorBase); | 141 DISALLOW_COPY_AND_ASSIGN(NegotiatingAuthenticatorBase); |
| 138 }; | 142 }; |
| 139 | 143 |
| 140 } // namespace protocol | 144 } // namespace protocol |
| 141 } // namespace remoting | 145 } // namespace remoting |
| 142 | 146 |
| 143 #endif // REMOTING_PROTOCOL_NEGOTIATING_AUTHENTICATOR_BASE_H_ | 147 #endif // REMOTING_PROTOCOL_NEGOTIATING_AUTHENTICATOR_BASE_H_ |
| OLD | NEW |