Index: chrome/browser/chromeos/login/easy_unlock/easy_unlock_tpm_key_manager.cc |
diff --git a/chrome/browser/chromeos/login/easy_unlock/easy_unlock_tpm_key_manager.cc b/chrome/browser/chromeos/login/easy_unlock/easy_unlock_tpm_key_manager.cc |
index 46058c1692689a87c4506242e7ca86b40e8d6d02..06c58978defd3afc04e80c765e98cac5ba394ce7 100644 |
--- a/chrome/browser/chromeos/login/easy_unlock/easy_unlock_tpm_key_manager.cc |
+++ b/chrome/browser/chromeos/login/easy_unlock/easy_unlock_tpm_key_manager.cc |
@@ -66,14 +66,10 @@ crypto::ScopedSECKEYPrivateKey GetPrivateKeyOnWorkerThread( |
std::vector<uint8> public_key_vector( |
public_key_uint8, public_key_uint8 + public_key.size()); |
- // TODO(davidben): This should be equivalent to calling |
- // FindNSSKeyFromPublicKeyInfoInSlot. |
crypto::ScopedSECKEYPrivateKey rsa_key( |
- crypto::FindNSSKeyFromPublicKeyInfo(public_key_vector)); |
- if (!rsa_key || rsa_key->pkcs11Slot != slot || |
- SECKEY_GetPrivateKeyType(rsa_key.get()) != rsaKey) { |
+ crypto::FindNSSKeyFromPublicKeyInfoInSlot(public_key_vector, slot)); |
pneubeck (no reviews)
2015/05/12 09:48:38
for clarification: this is only equivalent if slot
davidben
2015/05/12 18:00:42
Done. (There are CHECKs up the call chain, so this
|
+ if (!rsa_key || SECKEY_GetPrivateKeyType(rsa_key.get()) != rsaKey) |
return nullptr; |
- } |
return rsa_key.Pass(); |
} |