Updated on 2026-08-14
This commit is contained in:
parent
a6bf9d2e2f
commit
e181c5a1a7
3 changed files with 44 additions and 4 deletions
|
|
@ -5,6 +5,7 @@ import android.content.Intent
|
|||
import android.net.Uri
|
||||
import androidx.core.net.toUri
|
||||
import com.tangem.common.routing.DeepLinkScheme
|
||||
import com.tangem.common.uri.ExternalUrlValidator
|
||||
import com.tangem.core.navigation.deeplink.DeeplinkLauncher
|
||||
import com.tangem.core.navigation.url.UrlOpener
|
||||
import com.tangem.utils.logging.TangemLogger
|
||||
|
|
@ -24,7 +25,18 @@ internal class DefaultDeeplinkLauncher(
|
|||
DeepLinkScheme.Tangem.scheme,
|
||||
DeepLinkScheme.WalletConnect.scheme,
|
||||
-> launchDeepLink(deeplinkUri)
|
||||
DeepLinkScheme.Https.scheme -> launchDeeplinkOrOpenBrowser(deeplinkUri, link)
|
||||
DeepLinkScheme.Https.scheme -> {
|
||||
if (ExternalUrlValidator.isUriTrusted(link)) {
|
||||
launchDeeplinkOrOpenBrowser(deeplinkUri, link)
|
||||
} else {
|
||||
TangemLogger.i(
|
||||
"""
|
||||
Untrusted HTTPS link dropped
|
||||
|- Received URI: $deeplinkUri
|
||||
""".trimIndent(),
|
||||
)
|
||||
}
|
||||
}
|
||||
else -> {
|
||||
TangemLogger.i(
|
||||
"""
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue