-
Notifications
You must be signed in to change notification settings - Fork 857
Description
Background
The current implementation of the OTLP Exporter targets net462 and netstandard2.0 and relies on Grpc.Core, which has been officially marked for deprecation. Continued use of this deprecated package significantly increases security risks, including potential vulnerabilities due to lack of active maintenance and ongoing security updates. Eliminating this dependency is crucial to ensure a secure, maintainable, and reliable implementation moving forward.
Impact
- No Impact to .NET Targets: There is no impact to .NET targets as they currently do not have any direct dependency on
Grpc.CoreAPIs. - Impact on .NET Framework Applications: .NET Framework applications will lose the ability to send telemetry data via gRPC when using either HTTP or HTTPS URLs. This limitation exists because the .NET Framework lacks built-in or fully supported APIs capable of handling gRPC communication consistently across both secure (
HTTPS) and non-secure (HTTP) protocols. Although some packages offer limited HTTPS support, they do not provide comprehensive support for both protocols.
Workarounds
-
Use WinHttpHandler:
Customers can continue using gRPC over HTTPS by leveraging theOpenTelemetry.Exporter.OtlpExporterOptions.HttpClientFactoryproperty. Adding aWinHttpHandleras shown below will enable telemetry data to be sent successfully, but only when using an HTTPS endpoint, such ashttps://localhost:4317/.The
WinHttpHandlerclass is available through the NuGet package System.Net.Http.WinHttpHandler.
exporterOptions.HttpClientFactory = () => new HttpClient(new WinHttpHandler());
- Stay with an earlier version: Alternatively, customers can continue using a version equal to or lower than
OpenTelemetry.Exporter.OpenTelemetryProtocolversion1.11.2to maintain existing functionality without changes.
SIG Discussion (3/25/2025)
During the SIG meeting on March 25, we discussed this dependency removal, highlighting agreement on prioritizing security by phasing out deprecated dependencies. The consensus was clear about moving forward with this change, acknowledging potential impacts, and providing suitable workarounds.
Runtime Version
net462, netstandard2.0
cc: @open-telemetry/dotnet-maintainers @open-telemetry/dotnet-approvers