Repository navigation
Add W3C Trace Headers to Unsigned Hop-by-Hop Header List - #3805
Conversation
|
Let me know if you'd like me to add a change record or open an issue on the repo as well. |
|
Could I get a review on this from someone? @jonathan343 maybe? This should be a pretty easy change to review. |
alexgromero
left a comment
There was a problem hiding this comment.
Hi @TimPansino, thanks for the writeup!
We're inclined to take this. Could you add two things?
baggageas well, with tests in the same style as the others. It's a separate spec from Trace Context so I can see why it wasn't in scope, but it can also be modified during propagation and is commonly injected alongside the other two.- A changelog entry, which you can generate by running
scripts/new-change.
Also out of curiosity, are you seeing this with a particular service, or is it general to any signed request? Not a blocker either way, just useful context on our end.
Thanks again for the contribution!
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #3805 +/- ##
===========================================
- Coverage 92.59% 92.50% -0.10%
===========================================
Files 68 68
Lines 15634 15866 +232
===========================================
+ Hits 14477 14677 +200
- Misses 1157 1189 +32 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
6b04d30 to
365c246
Compare
I've updated the PR with the addition of We received reports of issues connecting to any service at all when transport was configured to use SigV4 signing. It was only an issue if the user was using multiple sources of W3C headers, such as multiple tracing products. Unfortunately that included our hybrid The original report was actually due to the use of Relevant Changelog Entry from |
alexgromero
left a comment
There was a problem hiding this comment.
Thanks for the updates and the extra context! LGTM ![]()
* release-1.43.115: Bumping version to 1.43.115 Update to latest models Fix race when publishing refreshed credentials (#3835) Bump urllib3 from 2.7.0 to 2.8.0 (#3813) Move Content-Length validation back to botocore (#3831) Add W3C headers to unsigned hop-by-hop header list (#3805) Bump https://github.com/astral-sh/ruff-pre-commit (#3829)
Background:
At newrelic we recently received bug reports of interoperability issues with our APM agent and other tracing vendors when combined with
botocoreand other tracing vendors.W3C Trace Context headers are frequently shared between tracing vendors, and our agent inserts these headers after the request had already been signed by SigV4.
When paired with another tracing provider such as OpenTelemetry, it's possible these headers are injected before request signing as well. When these headers are included in the signature, it unfortunately conflicts with their designed purpose of being mutated throughout the request lifecycle to store up to date tracing information.
The issue is not limited to APM agents running on the same host, as these headers can also be mutated by any intermediary hops such as load balancers or proxies. If any of these run a W3C compliant tracing product, it's possible the headers will be mutated and break the signature.
The following are the W3C Trace Context headers that are designed to be mutated throughout the request lifecycle, with some examples as to why they may be mutated.
sampledflag, or update trace IDs.Description of changes:
SIGNED_HEADERS_BLACKLIST), due to potential mutation by tracing libraries on the same host, or running on a proxy or load balancer.By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.