| Index: chrome/browser/chromeos/cros/login_library.h
|
| diff --git a/chrome/browser/chromeos/cros/login_library.h b/chrome/browser/chromeos/cros/login_library.h
|
| index 0628e2f3b68cba50a656e00726ade950697c3588..7b6e9982d5b8a4ee57b469eedf65aaf0dd91cac2 100644
|
| --- a/chrome/browser/chromeos/cros/login_library.h
|
| +++ b/chrome/browser/chromeos/cros/login_library.h
|
| @@ -26,13 +26,57 @@ class LoginLibrary {
|
| // Requests that the Upstart signal login-prompt-ready be emitted.
|
| virtual bool EmitLoginPromptReady() = 0;
|
|
|
| + // Check whether or not |email| is present on the whitelist.
|
| + // If so, we return true and store the signature passed when |email| was
|
| + // whitelisted in |OUT_signature|.
|
| + // If not, we return false and don't touch the output parameter.
|
| + virtual bool CheckWhitelist(const std::string& email,
|
| + std::vector<uint8>* OUT_signature) = 0;
|
| +
|
| + // Fetch the value associated with |name|, if its present.
|
| + // If so, we return true, store the info in |OUT_value|, and store the
|
| + // signature passed when the property was initially stored in |OUT_signature|.
|
| + // If not, we return false and don't touch the output parameters.
|
| + virtual bool RetrieveProperty(const std::string& name,
|
| + std::string* OUT_value,
|
| + std::vector<uint8>* OUT_signature) = 0;
|
| +
|
| // Attempts to asynchronously set the provided public key as the
|
| // Owner's public key for this device. |public_key_der| should be a
|
| // DER-encoded PKCS11 SubjectPublicKeyInfo structure.
|
| // Returns true if the attempt was successfully started.
|
| // callback->Run() will be called when the operation is complete.
|
| - virtual bool SetOwnerKey(const std::vector<uint8>& public_key_der,
|
| - Delegate<bool>* callback) = 0;
|
| + virtual bool SetOwnerKeyAsync(const std::vector<uint8>& public_key_der,
|
| + Delegate<bool>* callback) = 0;
|
| +
|
| + // Attempts to issue a signed async request to store |name|=|value|.
|
| + // |signature| must by a SHA1 with RSA encryption signature over the string
|
| + // "name=value" with the owner's private key.
|
| + // Returns true if the attempt was successfully started.
|
| + // callback->Run() will be called when the operation is complete.
|
| + virtual bool StorePropertyAsync(const std::string& name,
|
| + const std::string& value,
|
| + const std::vector<uint8>& signature,
|
| + Delegate<bool>* callback) = 0;
|
| +
|
| + // Attempts to issue a signed async request to whitelist |email|.
|
| + // |signature| must by a SHA1 with RSA encryption signature over |email|
|
| + // with the owner's private key.
|
| + // Returns true if the attempt was successfully started.
|
| + // callback->Run() will be called when the operation is complete.
|
| + virtual bool WhitelistAsync(const std::string& email,
|
| + const std::vector<uint8>& signature,
|
| + Delegate<bool>* callback) = 0;
|
| +
|
| + // Attempts to issue a signed async request to remove |email| from the
|
| + // whitelist of users allowed to log in to this machine.
|
| + // |signature| must by a SHA1 with RSA encryption signature over |email|
|
| + // with the owner's private key.
|
| + // Returns true if the attempt was successfully started.
|
| + // callback->Run() will be called when the operation is complete.
|
| + virtual bool UnwhitelistAsync(const std::string& email,
|
| + const std::vector<uint8>& signature,
|
| + Delegate<bool>* callback) = 0;
|
|
|
| // Tells the session manager to start a logged-in session for the user
|
| // |user_email|. |unique_id| is meant to be used when we have a non-human-
|
|
|