Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(32)

Side by Side Diff: chromeos/cryptohome/cryptohome_parameters.cc

Issue 506943002: Wire up GetKeyDataEx() in Chrome (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@d_1_367847_move_to_mount_ex
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "chromeos/cryptohome/cryptohome_parameters.h" 5 #include "chromeos/cryptohome/cryptohome_parameters.h"
6 6
7 #include "chromeos/dbus/cryptohome/key.pb.h"
8
7 namespace cryptohome { 9 namespace cryptohome {
8 10
9
10 Identification::Identification(const std::string& user_id) : user_id(user_id) { 11 Identification::Identification(const std::string& user_id) : user_id(user_id) {
11 } 12 }
12 13
13 bool Identification::operator==(const Identification& other) const { 14 bool Identification::operator==(const Identification& other) const {
14 return user_id == other.user_id; 15 return user_id == other.user_id;
15 } 16 }
16 17
17 KeyDefinition::KeyDefinition(const std::string& key, 18 KeyDefinition::KeyDefinition(const std::string& key,
18 const std::string& label, 19 const std::string& label,
19 int /*AuthKeyPrivileges*/ privileges) 20 int /*AuthKeyPrivileges*/ privileges)
(...skipping 22 matching lines...) Expand all
42 43
43 Authorization::Authorization(const KeyDefinition& key_def) 44 Authorization::Authorization(const KeyDefinition& key_def)
44 : key(key_def.key), 45 : key(key_def.key),
45 label(key_def.label) { 46 label(key_def.label) {
46 } 47 }
47 48
48 bool Authorization::operator==(const Authorization& other) const { 49 bool Authorization::operator==(const Authorization& other) const {
49 return key == other.key && label == other.label; 50 return key == other.key && label == other.label;
50 } 51 }
51 52
52 MountParameters::MountParameters(bool ephemeral) : ephemeral(ephemeral) { 53 RetrievedKeyData::ProviderData::ProviderData(const std::string& name)
54 : name(name) {
53 } 55 }
54 56
55 MountParameters::~MountParameters() { 57 RetrievedKeyData::RetrievedKeyData(Type type,
58 const std::string& label,
59 int64 revision) : type(type),
60 label(label),
61 privileges(0),
62 revision(revision) {
63 }
64
65 MountParameters::MountParameters(bool ephemeral) : ephemeral(ephemeral) {
56 } 66 }
57 67
58 bool MountParameters::operator==(const MountParameters& other) const { 68 bool MountParameters::operator==(const MountParameters& other) const {
59 return ephemeral == other.ephemeral && create_keys == other.create_keys; 69 return ephemeral == other.ephemeral && create_keys == other.create_keys;
60 } 70 }
61 71
72 MountParameters::~MountParameters() {
73 }
74
62 } // namespace cryptohome 75 } // namespace cryptohome
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698