Commit c61a7be
authored
feat: XML Views Automasking options (#299)
## Summary
Support maskText, maskTextInput, maskSensitive for Android Native XML
Views
## How did you test this change?
<!--
Frontend - Leave a screencast or a screenshot to visually describe the
changes.
-->
## Are there any deployment considerations?
<!--
Backend - Do we need to consider migrations or backfilling data?
-->
<!-- CURSOR_SUMMARY -->
---
> [!NOTE]
> Adds auto-masking for Android XML views and refactors masking to a new
MaskTarget/MaskMatcher API, updating capture/instrumentation and e2e
demo package paths.
>
> - **SDK • Session Replay/Masking**:
> - **New masking module** `replay/masking`: introduce
`MaskTarget`/`MaskMatcher`, `ComposeMaskTarget`, `NativeMaskTarget`
(handles `EditText`/`TextView`, passwords, hints, contentDescription),
and `SensitiveAreasCollector` (now uses `LDLogger`).
> - **Privacy**: `PrivacyProfile` matchers rewritten to operate on
`MaskTarget` (`textInput`, `text`, `sensitive`).
> - **Capture/Instrumentation**: `CaptureSource` now accepts `LDLogger`
and uses new `masking.SensitiveAreasCollector`; `ReplayInstrumentation`
creates logger and passes it to `CaptureSource`.
> - Remove old `replay/MaskMatcher.kt` and old
`SensitiveAreasCollector`.
> - **E2E App**:
> - Move Smoothie demo to `com.example.androidobservability.smoothie`;
update `AndroidManifest.xml`, `MainActivity`, and adapter imports.
> - `SmoothieAdapter`: call `ldMask()` on image view to mark as
sensitive.
>
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
60a4713. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->1 parent 6e6c388 commit c61a7be
File tree
14 files changed
+364
-262
lines changed- e2e/android/app/src/main
- java/com/example/androidobservability
- smoothie
- sdk/@launchdarkly/observability-android
- lib/src/main/kotlin/com/launchdarkly/observability/replay
- masking
14 files changed
+364
-262
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
| 29 | + | |
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| |||
Lines changed: 2 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
| 27 | + | |
27 | 28 | | |
28 | 29 | | |
29 | 30 | | |
| |||
86 | 87 | | |
87 | 88 | | |
88 | 89 | | |
89 | | - | |
| 90 | + | |
90 | 91 | | |
91 | 92 | | |
92 | 93 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
Lines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
17 | 18 | | |
| 19 | + | |
| 20 | + | |
18 | 21 | | |
19 | 22 | | |
20 | 23 | | |
| |||
37 | 40 | | |
38 | 41 | | |
39 | 42 | | |
| 43 | + | |
40 | 44 | | |
41 | 45 | | |
42 | 46 | | |
| |||
46 | 50 | | |
47 | 51 | | |
48 | 52 | | |
49 | | - | |
| 53 | + | |
50 | 54 | | |
51 | 55 | | |
52 | 56 | | |
| |||
Lines changed: 0 additions & 20 deletions
This file was deleted.
Lines changed: 9 additions & 46 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
4 | | - | |
5 | | - | |
6 | | - | |
| 3 | + | |
| 4 | + | |
7 | 5 | | |
8 | 6 | | |
9 | 7 | | |
| |||
15 | 13 | | |
16 | 14 | | |
17 | 15 | | |
18 | | - | |
| 16 | + | |
19 | 17 | | |
20 | 18 | | |
21 | 19 | | |
| |||
40 | 38 | | |
41 | 39 | | |
42 | 40 | | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
| 41 | + | |
| 42 | + | |
49 | 43 | | |
50 | 44 | | |
51 | 45 | | |
| |||
54 | 48 | | |
55 | 49 | | |
56 | 50 | | |
57 | | - | |
58 | | - | |
| 51 | + | |
| 52 | + | |
59 | 53 | | |
60 | 54 | | |
61 | 55 | | |
| |||
64 | 58 | | |
65 | 59 | | |
66 | 60 | | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
74 | | - | |
75 | | - | |
76 | | - | |
77 | | - | |
78 | | - | |
79 | | - | |
80 | | - | |
81 | | - | |
82 | | - | |
83 | | - | |
84 | | - | |
85 | | - | |
86 | | - | |
87 | | - | |
88 | | - | |
89 | | - | |
90 | | - | |
91 | | - | |
92 | | - | |
93 | | - | |
94 | | - | |
95 | | - | |
96 | | - | |
97 | | - | |
98 | | - | |
99 | | - | |
| 61 | + | |
| 62 | + | |
100 | 63 | | |
101 | 64 | | |
102 | 65 | | |
| |||
Lines changed: 4 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
68 | 69 | | |
69 | 70 | | |
70 | 71 | | |
71 | | - | |
72 | 72 | | |
73 | 73 | | |
74 | 74 | | |
| |||
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
80 | | - | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
81 | 83 | | |
82 | 84 | | |
83 | 85 | | |
| |||
Lines changed: 0 additions & 189 deletions
This file was deleted.
0 commit comments