Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The user-agent string when using KeyVault::Keys::Cryptography::CryptographyClient is not setup correctly. #4466

Closed
ahsonkhan opened this issue Mar 21, 2023 · 1 comment · Fixed by #4467
Assignees
Labels
bug This issue requires a change to an existing behavior in the product in order to be resolved. Client This issue points to a problem in the data-plane of the library. KeyVault
Milestone

Comments

@ahsonkhan
Copy link
Member

The telemetryPackageName parameter within the pipeline ctor (and therefore the user-agent string) for the KeyVault Keys package, when using the CryptographyClient is not setup correctly.

See:

m_pipeline = std::make_shared<Azure::Core::Http::_internal::HttpPipeline>(
options,
"KeyVault",
PackageVersion::ToString(),
std::move(perRetrypolicies),
std::move(perCallpolicies));

In other clients within this package (along with other packages), use a different string. In this case, that would be keyvault-keys:

m_pipeline = std::make_shared<Azure::Core::Http::_internal::HttpPipeline>(
options,
KeyVaultServicePackageName,
PackageVersion::ToString(),
std::move(perRetrypolicies),
std::move(perCallpolicies));

constexpr static const char KeyVaultServicePackageName[] = "keyvault-keys";

cc @gearama

@ahsonkhan ahsonkhan added this to the 2023-03 milestone Mar 21, 2023
@ahsonkhan ahsonkhan self-assigned this Mar 21, 2023
@RickWinter RickWinter added bug This issue requires a change to an existing behavior in the product in order to be resolved. Client This issue points to a problem in the data-plane of the library. labels Mar 27, 2023
@LarryOsterman
Copy link
Member

A minor nit: The package name is keyvault-keys-cpp, not keyvault-keys. THe Azure Core SDK guidelines say that the package name in the user-agent should be the user visible package name, and the user visible package name is azure-security-keyvault-keys-cpp

azure-sdk added a commit to azure-sdk/vcpkg that referenced this issue May 9, 2023
## 4.4.0 (2023-05-09)

### Features Added

- Added support for challenge-based and multi-tenant authentication.

### Bugs Fixed

- [3366](Azure/azure-sdk-for-cpp#4466) Fixed the user-agent string sent to the service to include the "keys" suffix in the value, when using `CryptographyClient`.
JavierMatosD pushed a commit to microsoft/vcpkg that referenced this issue May 10, 2023
* [azure-security-keyvault-certificates-cpp] Update to 4.2.0
## 4.2.0 (2023-05-09)

### Features Added

- Added support for challenge-based and multi-tenant authentication.

* [azure-security-keyvault-secrets-cpp] Update to 4.2.0
## 4.2.0 (2023-05-09)

### Features Added

- Added support for challenge-based and multi-tenant authentication.

* [azure-security-keyvault-keys-cpp] Update to 4.4.0
## 4.4.0 (2023-05-09)

### Features Added

- Added support for challenge-based and multi-tenant authentication.

### Bugs Fixed

- [3366](Azure/azure-sdk-for-cpp#4466) Fixed the user-agent string sent to the service to include the "keys" suffix in the value, when using `CryptographyClient`.
@github-actions github-actions bot locked and limited conversation to collaborators Jun 28, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug This issue requires a change to an existing behavior in the product in order to be resolved. Client This issue points to a problem in the data-plane of the library. KeyVault
Projects
None yet
3 participants