x-ms-authorization-auxiliary header should be redacted #17271
Labels
Azure.Core
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.
Milestone
Is your feature request related to a problem? Please describe.
x-ms-authorization-auxiliary
header's value is logged byNetworkTraceLoggingPolicy
, because onlyauthorization
header is redacted.azure-sdk-for-python/sdk/core/azure-core/azure/core/pipeline/policies/_universal.py
Line 283 in 2e6022b
Even though
x-ms-authorization-auxiliary
is not supported by Track 2 SDK yet (#8313), Azure CLI is manually adding this header to support cross-tenant auth (Azure/azure-cli#16797).Describe the solution you'd like
Make an
ARMNetworkTraceLoggingPolicy
, just likeARMHttpLoggingPolicy
. SDKs should useARMNetworkTraceLoggingPolicy
instead ofNetworkTraceLoggingPolicy
, so thatx-ms-authorization-auxiliary
can also be redacted.NetworkTraceLoggingPolicy
is created inxxxClientConfiguration
, likeNetworkManagementClientConfiguration
(which belongs to a specific SDK):azure-sdk-for-python/sdk/network/azure-mgmt-network/azure/mgmt/network/_configuration.py
Line 59 in 3bf5688
We should change this line to
but this of course requires all existing SDKs to be regenerated.
Describe alternatives you've considered
Add the redacting
x-ms-authorization-auxiliary
behavior directly toNetworkTraceLoggingPolicy
fromazure-core
.The text was updated successfully, but these errors were encountered: