| Index: crypto/rsa_private_key_win.cc
|
| diff --git a/crypto/rsa_private_key_win.cc b/crypto/rsa_private_key_win.cc
|
| index f7363422db8b18928e95c8b2bd98690a0bc7f3d4..c07e2239b35aeadc5b33bd231796f01b2545612f 100644
|
| --- a/crypto/rsa_private_key_win.cc
|
| +++ b/crypto/rsa_private_key_win.cc
|
| @@ -134,6 +134,14 @@ bool RSAPrivateKey::InitProvider() {
|
| PROV_RSA_FULL, CRYPT_VERIFYCONTEXT);
|
| }
|
|
|
| +RSAPrivateKey* RSAPrivateKey::Copy() const {
|
| + scoped_ptr<RSAPrivateKey> copy(new RSAPrivateKey());
|
| + copy->provider_ = CryptContextAddRef(provider_, NULL, 0);
|
| + if (!CryptDuplicateKey(key_.get(), NULL, 0, copy->key_.receive()))
|
| + return NULL;
|
| + return copy.release();
|
| +}
|
| +
|
| bool RSAPrivateKey::ExportPrivateKey(std::vector<uint8>* output) {
|
| // Export the key
|
| DWORD blob_length = 0;
|
|
|