Skip to content

Commit

Permalink
Fixed UCBrowser webview effect
Browse files Browse the repository at this point in the history
  • Loading branch information
nielsbasjes committed Nov 24, 2017
1 parent e43f43d commit 6ea0a96
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 4 deletions.
33 changes: 33 additions & 0 deletions analyzer/src/main/resources/UserAgents/GoogleChrome.yaml
Expand Up @@ -298,6 +298,9 @@ config:
- 'WebviewAppVersion : 11:@WebViewProduct.version'

- matcher:
require:
- 'agent.product.(1)name="Version"'
- 'agent.product.(1)name="Chrome"'
variable:
- 'WebViewProduct: agent.product.(1)name="Version"^>>.name="Chrome"^<'
extract:
Expand All @@ -307,6 +310,35 @@ config:
- 'WebviewAppName : 12:LookUp[SpecialChromeBrowserNames;@WebViewProduct.name]'
- 'WebviewAppVersion : 12:@WebViewProduct.version'


- matcher:
require:
- 'agent.product.(1)name="Version"'
- 'agent.product.(1)name="Chrome"'
- 'agent.product.(1)name="Safari"'
variable:
- 'WebViewProduct: agent.product.(1)name="Version"^>.name="Chrome"^>>.name="Safari"^<'
extract:
- 'AgentClass : 2500:"Browser Webview"'
- 'AgentName : 2500:"Chrome Webview"'
- 'AgentVersion : 2500:agent.product.(1)name="Chrome"^.version'
- 'WebviewAppName : 12:LookUp[SpecialChromeBrowserNames;@WebViewProduct.name]'
- 'WebviewAppVersion : 12:@WebViewProduct.version'

- matcher:
require:
- 'agent.product.(1)name="Version"'
- 'agent.product.(1)name="Chrome"'
- 'agent.product.(1)name="Mobile Safari"'
variable:
- 'WebViewProduct: agent.product.(1)name="Version"^>.name="Chrome"^>>.name="Mobile Safari"^<'
extract:
- 'AgentClass : 2500:"Browser Webview"'
- 'AgentName : 2500:"Chrome Webview"'
- 'AgentVersion : 2500:agent.product.(1)name="Chrome"^.version'
- 'WebviewAppName : 12:LookUp[SpecialChromeBrowserNames;@WebViewProduct.name]'
- 'WebviewAppVersion : 12:@WebViewProduct.version'

- lookup:
name: 'KnownWebviewAppNames'
map:
Expand Down Expand Up @@ -515,6 +547,7 @@ config:
"Chromium" : "Chromium"
"Ubuntu Chromium" : "Chromium"
"Epiphany" : "Epiphany"
"UCBrowser" : "UCBrowser"

- matcher:
variable:
Expand Down
8 changes: 4 additions & 4 deletions analyzer/src/main/resources/UserAgents/Huawei.yaml
Expand Up @@ -105,10 +105,10 @@ config:
AgentLanguage : 'Chinese (S)'
AgentLanguageCode : 'zh-cn'
AgentSecurity : 'Strong security'
WebviewAppName : 'Mobile Safari' # It is impossible!!!
WebviewAppNameVersionMajor : 'Mobile Safari 537' #
WebviewAppVersion : '537.36' # FIXME: This must be UCBrowser!
WebviewAppVersionMajor : '537' # To understand and fix.
WebviewAppName : 'UCBrowser'
WebviewAppNameVersionMajor : 'UCBrowser 11'
WebviewAppVersion : '11.6.6.951'
WebviewAppVersionMajor : '11'

- test:
input:
Expand Down

0 comments on commit 6ea0a96

Please sign in to comment.