How can Google detect a request is from a WebView?

后端 未结 6 1736
青春惊慌失措
青春惊慌失措 2021-02-12 14:05

Google announced that they \"will no longer allow OAuth requests to Google in embedded browsers known as \'web-views\'\".

In Android, requests from WebViews get

6条回答
  •  忘了有多久
    2021-02-12 14:33

    You can differentiate via the user agent string. See https://mobiforge.com/research-analysis/webviews-and-user-agent-strings

    e.g. default chrome browser contains the following "(KHTML, like Gecko) Chrome/xx.xx..." but default webviews are of the following pattern "(KHTML, like Gecko) Version/4.0 Chrome/xx.xx.." It seems webview has an extra version string.

提交回复
热议问题