Skip to content
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

fix: Dropped query params when obfuscating #1719

Merged
merged 1 commit into from
Jul 12, 2023

Conversation

mrickard
Copy link
Member

Changed http to use pathname instead of path, avoiding exposure of query params

How to Test

Test for this case has been added to tests/unit/instrumentation/http/http.test.js

Related Issues

Fixes #1718
Closes NR-141506

…uery params

Signed-off-by: mrickard <maurice@mauricerickard.com>
Copy link
Member

@bizob2828 bizob2828 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice work, hopefully this will prevent regressions in future

@codecov
Copy link

codecov bot commented Jul 12, 2023

Codecov Report

Merging #1719 (4f7e0fb) into main (20442c6) will not change coverage.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##             main    #1719   +/-   ##
=======================================
  Coverage   96.87%   96.87%           
=======================================
  Files         200      200           
  Lines       39181    39181           
  Branches       24       24           
=======================================
  Hits        37956    37956           
  Misses       1225     1225           
Flag Coverage Δ
esm-unit-tests-14.x 47.80% <ø> (ø)
esm-unit-tests-16.x 92.11% <ø> (ø)
esm-unit-tests-18.x 92.11% <ø> (ø)
integration-tests-14.x 78.98% <100.00%> (ø)
integration-tests-16.x 79.07% <100.00%> (+<0.01%) ⬆️
integration-tests-18.x 79.06% <100.00%> (ø)
unit-tests-14.x 91.41% <100.00%> (+<0.01%) ⬆️
unit-tests-16.x 91.47% <100.00%> (+<0.01%) ⬆️
unit-tests-18.x 91.45% <100.00%> (+<0.01%) ⬆️
versioned-tests-14.x 75.70% <100.00%> (-0.06%) ⬇️
versioned-tests-16.x 77.03% <100.00%> (-0.05%) ⬇️
versioned-tests-18.x 77.03% <100.00%> (-0.05%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
lib/instrumentation/core/http.js 90.84% <100.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@mrickard mrickard merged commit 76112a6 into newrelic:main Jul 12, 2023
20 checks passed
@github-actions github-actions bot mentioned this pull request Jul 13, 2023
@mrickard mrickard deleted the NR-141506/request.uri-query-params branch October 3, 2023 14:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

request.uri can contain query params
2 participants