-
Notifications
You must be signed in to change notification settings - Fork 9
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
[FEATURE]: Ability to hide queryString from generated spans #172
Comments
Hello @sdwa0, Thank you for bringing this to our attention. From what I understand, the module sends the full URL here, and the agent (or intake?) split it. I’m also surprised that query strings are not obfuscated by default, especially because the agent obfuscate some span metadata by default since v7.48.0. I’d recommend reviewing the documentation on Trace Obfuscation here. From what I understand, you may need to update the agent configuration with the following: apm_config:
enabled: true
obfuscation:
http:
## Enables obfuscation of query strings in URLs. Disabled by default.
remove_query_string: true
remove_paths_with_digits: true I hope this solves your issue. Keep me posted. Thank you. |
Thanks, @dmehala for the reply. The old ingress-nginx version we were using was instrumented with nginx-opentracing module v0.19.0. From the code of the old module, it seems to have been sending the full URL too. If that's the case, it is strange that full URLs with query strings started showing up after the switch to nginx-datadog. FWIW, no agent version upgrades were done around the switch, and obfuscation of query strings was never enabled. What might be the cause of the difference in the behavior? |
You're right @sdwa0, the old module source code is indeed identical. The discrepancy may be due to how the Datadog agent or intake processes the incoming trace. Unfortunately, I don’t have the bandwidth to investigate this further at the moment. I strongly recommend opening a support ticket to get a deeper investigation and resolution. They should be able to provide more insights into what might be causing this behavior. Let me know if there's anything else I can help with! |
Noted. Thanks for taking a look, @dmehala. I have opened a support request. I will update here if anything is discovered there. |
I noticed dd-trace libraries for a few other languages provide a way to avoid sending query strings in |
You may have noticed that not all dd-trace libraries are identical in functionality. While I understand Thank you for bringing this up. |
Describe the goal of the feature
When we switched from an old version of ingress-nginx instrumented with nginx-opentracing module to using nginx-datadog , we noticed query parameters are appended to the
http.url
span attribute. Also, there is a new span attributehttp.url_details.queryString
that contains the list of all query parameter.I am not sure if this is due to the switch to nginx-datadog though. I couldn't find a related difference in code between nginx-opentracing and nginx-datadog.
Regardless, an ability to hide query string from generated spans would be useful. There could be services that write PII data on query string, even though that is a bad security practice. An ability to hide it will avoid that from surfacing on Datadog.
Is your feature request related to a problem?
No response
Describe alternatives you've considered
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: