Accept non URL-encoded headers by xrmx · Pull Request #4103 · open-telemetry/opentelemetry-python

@xrmx changed the title Accept non urlencoded headers Accept non URL-encoded headers

Aug 2, 2024
Add a liberal boolean parameter to parse_env_headers default to False to
keep backward compatibility for the function.
If liberal=True we try to parse the string even if it does comply with
the the W3C Baggage HTTP header format to be more compatible with other
other languages SDKs that accept non URL-encoded headers by default.

@xrmx

@xrmx

@xrmx xrmx marked this pull request as ready for review

August 5, 2024 09:28

@xrmx xrmx requested a review from a team

August 5, 2024 09:28

@lzchen

xrmx added a commit to xrmx/opentelemetry-python that referenced this pull request

Aug 19, 2024
After open-telemetry#4103 we accept non url-encoded headers for OTLP. Naively this
implementation only accepts digits, ascii letters, underscores (\w) and spaces.
Instead broaden the accepted chars to what we accept for urlencoded
values so that we accepts = to allow for base64 encoded values.

@xrmx xrmx mentioned this pull request

Aug 19, 2024

11 tasks