dd-sdk-android
dd-sdk-android copied to clipboard
Android Web View Tracking
Thanks for taking the time for reporting an issue!
Describe what happened
- Unable dynamic add web host in configuration, where we have a lot webview load url with different domain or host especially partner returning different url so we unable add the host in here.
val configuration = Configuration.Builder(
rumEnabled = true
)
.useSite()
.trackInteractions()
**.setWebViewTrackingHosts(hosts)**
.trackLongTasks(durationThreshold)
.useViewTrackingStrategy(strategy)
.build()
val credentials = Credentials(<CLIENT_TOKEN>, <ENV_NAME>, <APP_VARIANT_NAME>, <APPLICATION_ID>)
Datadog.initialize(this, credentials, configuration, trackingConsent)
}
}
Steps to reproduce the issue:
-
setWebViewTrackingHosts(hosts)
Describe what you expected:
- Can the SDK able to support configuration to support all host that called from webview ?
Additional context
- Datadog SDK version: 1.13.0
- Datadog Gradle Plugins version: 1.4.0
- Versions of any other relevant dependencies (OkHttp, …): 4.9.0 OKhttp
- Proguard configuration: Enable Full Mode for R8
- Gradle Plugins: 7.2.0
Hi @Maxwell6635 , and thanks for opening this suggestion.
As of today, this is unfortunately not something that we can do. The goal of this check is that the data catpured inside the webview can only be shared if you own the website displayed, to prevent sharing PII or other information that do not belong to you. Also if a website owned by a third party (partner or otherwise) is using Datadog, we want to avoid capturing the data as those other companies would be blind on their own website.