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 CHROMEOS_DBUS_CRYPTOHOME_CLIENT_H_ | 5 #ifndef CHROMEOS_DBUS_CRYPTOHOME_CLIENT_H_ |
6 #define CHROMEOS_DBUS_CRYPTOHOME_CLIENT_H_ | 6 #define CHROMEOS_DBUS_CRYPTOHOME_CLIENT_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <string> | 10 #include <string> |
(...skipping 17 matching lines...) Expand all Loading... | |
28 class GetKeyDataRequest; | 28 class GetKeyDataRequest; |
29 class MountRequest; | 29 class MountRequest; |
30 class RemoveKeyRequest; | 30 class RemoveKeyRequest; |
31 class SetBootAttributeRequest; | 31 class SetBootAttributeRequest; |
32 class UpdateKeyRequest; | 32 class UpdateKeyRequest; |
33 | 33 |
34 class Identification; | 34 class Identification; |
35 | 35 |
36 } // namespace cryptohome | 36 } // namespace cryptohome |
37 | 37 |
38 namespace google { | |
39 namespace protobuf { | |
40 class MessageLite; | |
41 } | |
Daniel Erat
2017/03/06 21:18:26
nit: add // namespace protobuf
igorcov
2017/03/09 12:22:57
Done.
| |
42 } // namespace google | |
43 | |
38 namespace chromeos { | 44 namespace chromeos { |
39 | 45 |
40 // CryptohomeClient is used to communicate with the Cryptohome service. | 46 // CryptohomeClient is used to communicate with the Cryptohome service. |
41 // All method should be called from the origin thread (UI thread) which | 47 // All method should be called from the origin thread (UI thread) which |
42 // initializes the DBusThreadManager instance. | 48 // initializes the DBusThreadManager instance. |
43 class CHROMEOS_EXPORT CryptohomeClient : public DBusClient { | 49 class CHROMEOS_EXPORT CryptohomeClient : public DBusClient { |
44 public: | 50 public: |
45 // Constant that will be passed to AsyncMethodCallback to indicate that | 51 // Constant that will be passed to AsyncMethodCallback to indicate that |
46 // cryptohome is not ready yet. | 52 // cryptohome is not ready yet. |
47 static const int kNotReadyAsyncId; | 53 static const int kNotReadyAsyncId; |
(...skipping 500 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
548 | 554 |
549 // Asynchronously calls FlushAndSignBootAttributes method. |callback| is | 555 // Asynchronously calls FlushAndSignBootAttributes method. |callback| is |
550 // called after method call, and with reply protobuf. | 556 // called after method call, and with reply protobuf. |
551 // FlushAndSignBootAttributes makes all pending boot attribute settings | 557 // FlushAndSignBootAttributes makes all pending boot attribute settings |
552 // available, and have them signed by a special TPM key. This method always | 558 // available, and have them signed by a special TPM key. This method always |
553 // fails after any user, publuc, or guest session starts. | 559 // fails after any user, publuc, or guest session starts. |
554 virtual void FlushAndSignBootAttributes( | 560 virtual void FlushAndSignBootAttributes( |
555 const cryptohome::FlushAndSignBootAttributesRequest& request, | 561 const cryptohome::FlushAndSignBootAttributesRequest& request, |
556 const ProtobufMethodCallback& callback) = 0; | 562 const ProtobufMethodCallback& callback) = 0; |
557 | 563 |
564 virtual void AsyncTpmUpdateFirmwareManagementParameters( | |
Daniel Erat
2017/03/06 21:18:26
add a comment documenting what this does. can you
igorcov
2017/03/09 12:22:57
Done.
| |
565 const std::string& method_name, | |
Daniel Erat
2017/03/06 21:18:26
i think that this leaks too many of the IPC implem
igorcov
2017/03/09 12:22:57
Done.
| |
566 const google::protobuf::MessageLite& request, | |
567 const ProtobufMethodCallback& callback) = 0; | |
568 | |
558 protected: | 569 protected: |
559 // Create() should be used instead. | 570 // Create() should be used instead. |
560 CryptohomeClient(); | 571 CryptohomeClient(); |
561 | 572 |
562 private: | 573 private: |
563 DISALLOW_COPY_AND_ASSIGN(CryptohomeClient); | 574 DISALLOW_COPY_AND_ASSIGN(CryptohomeClient); |
564 }; | 575 }; |
565 | 576 |
566 } // namespace chromeos | 577 } // namespace chromeos |
567 | 578 |
568 #endif // CHROMEOS_DBUS_CRYPTOHOME_CLIENT_H_ | 579 #endif // CHROMEOS_DBUS_CRYPTOHOME_CLIENT_H_ |
OLD | NEW |