Chromium Code Reviews| Index: chromeos/dbus/auth_policy_client.h |
| diff --git a/chromeos/dbus/auth_policy_client.h b/chromeos/dbus/auth_policy_client.h |
| index 550edea4e9eb75ecb573fdaf59f6d078a4ff1d69..c25a39f88c495145468858e87acabec4998a7f15 100644 |
| --- a/chromeos/dbus/auth_policy_client.h |
| +++ b/chromeos/dbus/auth_policy_client.h |
| @@ -29,6 +29,7 @@ namespace chromeos { |
| class CHROMEOS_EXPORT AuthPolicyClient : public DBusClient { |
| public: |
| using JoinCallback = base::Callback<void(int error_code)>; |
| + using RefreshPoliciesCallback = base::Callback<void(bool success)>; |
| ~AuthPolicyClient() override; |
| @@ -36,16 +37,27 @@ class CHROMEOS_EXPORT AuthPolicyClient : public DBusClient { |
| // For normal usage, access the singleton via DBusThreadManager::Get(). |
| static AuthPolicyClient* Create(); |
| - // TODO(rsorokin): Write more descriptive comment. |
| - // Calls JoinADDomain. Uses |machine_name| to join it to the domain. |user|, |
| - // |password_fd| are credentials of the AD user which have right to join the |
| - // domain. |password_fd| is a file descriptor password is read from. |
| - // The caller should close it after the call. |
| + // Calls JoinADDomain. It runs "net ads join ..." which joins machine to |
| + // Active directory domain. |
| + // |machine_name| is a name for a local machine. |user|, |
| + // |password_fd| are credentials of the Active directory account which has |
| + // right to join the machine to the domain. |password_fd| is a file descriptor |
| + // password is read from. The caller should close it after the call. |
| // |callback| is called after the method call succeeds. |
| virtual void JoinAdDomain(const std::string& machine_name, |
| const std::string& user, |
| int password_fd, |
| const JoinCallback& callback) = 0; |
|
hashimoto
2016/11/10 23:02:19
nit: Put blank lines between methods.
Roman Sorokin (ftl)
2016/11/14 14:10:18
Done.
|
| + // Refresh{Device,User}Policies fetch GPO files with policies from Active |
|
hashimoto
2016/11/10 23:02:19
Please write a comment for each method.
If you wan
Roman Sorokin (ftl)
2016/11/14 14:10:18
Done.
|
| + // directory server, parse it, encode it into protobuf and send to |
| + // SessionManager. Callback is called after that. |
| + // Calls RefreshDevicePolicies - handle policies for the device. |
| + virtual void RefreshDevicePolicies( |
| + const RefreshPoliciesCallback& callback) = 0; |
| + // Calls RefreshUserPolicies - handle policies for the user specified by |
| + // |account_id|. |
| + virtual void RefreshUserPolicies(const std::string& account_id, |
| + const RefreshPoliciesCallback& callback) = 0; |
| protected: |
| // Create() should be used instead. |