我正在开发针对 Android 和 iOS 智能手机的基于 cordova 的混合移动应用。
更新:Google 不再支持嵌入式 webview 方法
用例:应用程序对用户进行身份验证,然后访问 Google Calendar API,最后在应用程序上显示用户事件。
注意:我将在没有客户端库的情况下使用 3-legged OAuth 和 Google 数据 API。
问题 要向 Google 调用 OAuth 请求,我应该使用外部浏览器还是 ChromeTabs?
从安全角度来看,哪种方法最合适? 谢谢!
最佳答案
从安全的角度来看,都是一样的,Chrome Custom Tabs 依赖于 Chrome 浏览器信息,在安全上没有区别。
这是关于 Chrome 自定义标签的官方文档
Security: the browser uses Google's Safe Browsing to protect the user and the device from dangerous sites.
从应用集成的角度来看,最好使用 Chrome 自定义标签,因为您不会将用户推出应用以进行登录。但请注意,Chrome 自定义标签仅适用于 Jellybean 及更高版本 (API 16),并且需要在设备上安装 Chrome 45。
关于android - 哪个更安全 : External browser or ChromeTab for authorization?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43006787/