Skip to content

RUM-2015: Remove PII from WebView event error logging#3250

Merged
hamorillo merged 2 commits into
developfrom
hector.morilloprieto/RUM-2015
Mar 12, 2026
Merged

RUM-2015: Remove PII from WebView event error logging#3250
hamorillo merged 2 commits into
developfrom
hector.morilloprieto/RUM-2015

Conversation

@hamorillo

@hamorillo hamorillo commented Mar 11, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

In MixedWebViewEventConsumer, three error log paths previously logged the full raw WebView event string — which could contain PII (log messages, resource URLs, user data, Session Replay content). This PR replaces the full event content with safe alternatives: the top-level key names for structural errors, and the event character count for JSON parse failures.

Motivation

The full event string was sent to both logcat and Datadog internal telemetry targets, risking exposure of user-generated content. This change ensures PII is not leaked through error logging in the WebView tracking module.

Additional Notes

  • Only MixedWebViewEventConsumer.kt is modified in production code — the other WebView consumers (WebViewRumEventConsumer, WebViewLogEventConsumer, WebViewReplayEventConsumer) already log only static strings with no event content.
  • No API surface changes.

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • Make sure you discussed the feature or bugfix with the maintaining team in an Issue
  • Make sure each commit and the PR mention the Issue number (cf the CONTRIBUTING doc)

@hamorillo
hamorillo force-pushed the hector.morilloprieto/RUM-2015 branch from fc60c47 to 40160a3 Compare March 11, 2026 15:12
@datadog-prod-us1-3

This comment has been minimized.

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 71.46%. Comparing base (d46334a) to head (8df9a8e).
⚠️ Report is 27 commits behind head on develop.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #3250      +/-   ##
===========================================
- Coverage    71.49%   71.46%   -0.03%     
===========================================
  Files          938      938              
  Lines        34667    34667              
  Branches      5874     5874              
===========================================
- Hits         24782    24773       -9     
+ Misses        8247     8246       -1     
- Partials      1638     1648      +10     
Files with missing lines Coverage Δ
...roid/webview/internal/MixedWebViewEventConsumer.kt 100.00% <100.00%> (ø)

... and 33 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@hamorillo
hamorillo marked this pull request as ready for review March 12, 2026 07:39
@hamorillo
hamorillo requested review from a team as code owners March 12, 2026 07:39
@hamorillo
hamorillo merged commit f2674e0 into develop Mar 12, 2026
26 checks passed
@hamorillo
hamorillo deleted the hector.morilloprieto/RUM-2015 branch March 12, 2026 07:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants