summaryrefslogtreecommitdiffstats
path: root/chromeos/dbus/fake_cryptohome_client.cc
diff options
context:
space:
mode:
authordkrahn@chromium.org <dkrahn@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-10-10 22:41:53 +0000
committerdkrahn@chromium.org <dkrahn@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-10-10 22:41:53 +0000
commit0c0c09bad1d7f32eb223ed50f84aa4aba5688adb (patch)
tree5e0fe81957c0107ec028ea765a9a87edd240e313 /chromeos/dbus/fake_cryptohome_client.cc
parentd77beb759e0fda10629fb3fdc348f83d94b05c5e (diff)
downloadchromium_src-0c0c09bad1d7f32eb223ed50f84aa4aba5688adb.zip
chromium_src-0c0c09bad1d7f32eb223ed50f84aa4aba5688adb.tar.gz
chromium_src-0c0c09bad1d7f32eb223ed50f84aa4aba5688adb.tar.bz2
Add support for the Pkcs11GetTpmTokenInfoForUser cryptohome call.
This call already existed but had not been added to CryptohomeClient. BUG=chromium:205206 TEST=unit, manual Review URL: https://codereview.chromium.org/26407002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@228033 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chromeos/dbus/fake_cryptohome_client.cc')
-rw-r--r--chromeos/dbus/fake_cryptohome_client.cc10
1 files changed, 9 insertions, 1 deletions
diff --git a/chromeos/dbus/fake_cryptohome_client.cc b/chromeos/dbus/fake_cryptohome_client.cc
index 67883c5..32d7145 100644
--- a/chromeos/dbus/fake_cryptohome_client.cc
+++ b/chromeos/dbus/fake_cryptohome_client.cc
@@ -191,12 +191,20 @@ void FakeCryptohomeClient::Pkcs11IsTpmTokenReady(
void FakeCryptohomeClient::Pkcs11GetTpmTokenInfo(
const Pkcs11GetTpmTokenInfoCallback& callback) {
const char kStubUserPin[] = "012345";
+ const int kStubSlot = 0;
base::MessageLoop::current()->PostTask(
FROM_HERE,
base::Bind(callback,
DBUS_METHOD_CALL_SUCCESS,
std::string(crypto::kTestTPMTokenName),
- std::string(kStubUserPin)));
+ std::string(kStubUserPin),
+ kStubSlot));
+}
+
+void FakeCryptohomeClient::Pkcs11GetTpmTokenInfoForUser(
+ const std::string& username,
+ const Pkcs11GetTpmTokenInfoCallback& callback) {
+ Pkcs11GetTpmTokenInfo(callback);
}
bool FakeCryptohomeClient::InstallAttributesGet(const std::string& name,