diff --git a/sdk/keyvault/azure-security-keyvault-keys/CHANGELOG.md b/sdk/keyvault/azure-security-keyvault-keys/CHANGELOG.md index 975420ebf..8f559bdcf 100644 --- a/sdk/keyvault/azure-security-keyvault-keys/CHANGELOG.md +++ b/sdk/keyvault/azure-security-keyvault-keys/CHANGELOG.md @@ -16,6 +16,7 @@ - Removed access to `Iv` field member from `EncryptParameters` and `DecryptParameters`. - Removed `Encrypt(EncryptionAlgorithm, std::vector, context)`. - Removed `Decrypt(DecryptAlgorithm, std::vector, context)`. +- Removed `JsonWebKey::HasPrivateKey()`. - Removed the `MaxPageResults` field from `GetPropertiesOfKeysOptions`, `GetPropertiesOfKeyVersionsOptions`, and `GetDeletedKeysOptions`. - Renamed header `list_keys_single_page_result.hpp` to `list_keys_responses.hpp`. - Updated `BackupKey()` API return type to `BackupKeyResult` model type. diff --git a/sdk/keyvault/azure-security-keyvault-keys/inc/azure/keyvault/keys/json_web_key.hpp b/sdk/keyvault/azure-security-keyvault-keys/inc/azure/keyvault/keys/json_web_key.hpp index d2e5f408c..187b0f362 100644 --- a/sdk/keyvault/azure-security-keyvault-keys/inc/azure/keyvault/keys/json_web_key.hpp +++ b/sdk/keyvault/azure-security-keyvault-keys/inc/azure/keyvault/keys/json_web_key.hpp @@ -101,22 +101,6 @@ namespace Azure { namespace Security { namespace KeyVault { namespace Keys { /// Gets the Y coordinate for the elliptic curve point. std::vector Y; - bool HasPrivateKey() const - { - if (KeyType == KeyVaultKeyType::Rsa || KeyType == KeyVaultKeyType::Ec - || KeyType == KeyVaultKeyType::RsaHsm || KeyType == KeyVaultKeyType::EcHsm) - { - return D.size() > 0; - } - - if (KeyType == KeyVaultKeyType::Oct) - { - return K.size() > 0; - } - - return false; - } - bool SupportsOperation(KeyOperation operation) const { for (auto supportedOperation : m_keyOps) diff --git a/sdk/keyvault/azure-security-keyvault-keys/src/private/local_cryptography_provider.hpp b/sdk/keyvault/azure-security-keyvault-keys/src/private/local_cryptography_provider.hpp index 98b0f162a..6d888f6d7 100644 --- a/sdk/keyvault/azure-security-keyvault-keys/src/private/local_cryptography_provider.hpp +++ b/sdk/keyvault/azure-security-keyvault-keys/src/private/local_cryptography_provider.hpp @@ -44,7 +44,5 @@ namespace Azure { } bool CanRemote() const noexcept override { return m_canRemote; }; - - bool MustRemote() const { return m_canRemote && !m_keyMaterial.HasPrivateKey(); } }; }}}}}} // namespace Azure::Security::KeyVault::Keys::Cryptography::_detail