| 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 #include "sync/internal_api/sync_encryption_handler_impl.h" | 5 #include "sync/internal_api/sync_encryption_handler_impl.h" |
| 6 | 6 |
| 7 #include <queue> | 7 #include <queue> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/base64.h" | 10 #include "base/base64.h" |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 case IMPLICIT_PASSPHRASE: | 90 case IMPLICIT_PASSPHRASE: |
| 91 return sync_pb::NigoriSpecifics::IMPLICIT_PASSPHRASE; | 91 return sync_pb::NigoriSpecifics::IMPLICIT_PASSPHRASE; |
| 92 case KEYSTORE_PASSPHRASE: | 92 case KEYSTORE_PASSPHRASE: |
| 93 return sync_pb::NigoriSpecifics::KEYSTORE_PASSPHRASE; | 93 return sync_pb::NigoriSpecifics::KEYSTORE_PASSPHRASE; |
| 94 case CUSTOM_PASSPHRASE: | 94 case CUSTOM_PASSPHRASE: |
| 95 return sync_pb::NigoriSpecifics::CUSTOM_PASSPHRASE; | 95 return sync_pb::NigoriSpecifics::CUSTOM_PASSPHRASE; |
| 96 case FROZEN_IMPLICIT_PASSPHRASE: | 96 case FROZEN_IMPLICIT_PASSPHRASE: |
| 97 return sync_pb::NigoriSpecifics::FROZEN_IMPLICIT_PASSPHRASE; | 97 return sync_pb::NigoriSpecifics::FROZEN_IMPLICIT_PASSPHRASE; |
| 98 default: | 98 default: |
| 99 NOTREACHED(); | 99 NOTREACHED(); |
| 100 return sync_pb::NigoriSpecifics::IMPLICIT_PASSPHRASE;; | 100 return sync_pb::NigoriSpecifics::IMPLICIT_PASSPHRASE; |
| 101 }; | 101 }; |
| 102 } | 102 } |
| 103 | 103 |
| 104 bool IsExplicitPassphrase(PassphraseType type) { | 104 bool IsExplicitPassphrase(PassphraseType type) { |
| 105 return type == CUSTOM_PASSPHRASE || type == FROZEN_IMPLICIT_PASSPHRASE; | 105 return type == CUSTOM_PASSPHRASE || type == FROZEN_IMPLICIT_PASSPHRASE; |
| 106 } | 106 } |
| 107 | 107 |
| 108 } // namespace | 108 } // namespace |
| 109 | 109 |
| 110 SyncEncryptionHandlerImpl::Vault::Vault( | 110 SyncEncryptionHandlerImpl::Vault::Vault( |
| (...skipping 1237 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1348 | 1348 |
| 1349 base::Time SyncEncryptionHandlerImpl::GetExplicitPassphraseTime() const { | 1349 base::Time SyncEncryptionHandlerImpl::GetExplicitPassphraseTime() const { |
| 1350 if (passphrase_type_ == FROZEN_IMPLICIT_PASSPHRASE) | 1350 if (passphrase_type_ == FROZEN_IMPLICIT_PASSPHRASE) |
| 1351 return migration_time(); | 1351 return migration_time(); |
| 1352 else if (passphrase_type_ == CUSTOM_PASSPHRASE) | 1352 else if (passphrase_type_ == CUSTOM_PASSPHRASE) |
| 1353 return custom_passphrase_time(); | 1353 return custom_passphrase_time(); |
| 1354 return base::Time(); | 1354 return base::Time(); |
| 1355 } | 1355 } |
| 1356 | 1356 |
| 1357 } // namespace browser_sync | 1357 } // namespace browser_sync |
| OLD | NEW |