browser 2.5.3 → 2.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +28 -18
- data/.travis.yml +3 -3
- data/CHANGELOG.md +33 -0
- data/README.md +3 -2
- data/bot_exceptions.yml +1 -0
- data/bots.yml +39 -10
- data/browser.gemspec +1 -1
- data/lib/browser/accept_language.rb +1 -2
- data/lib/browser/aliases.rb +4 -4
- data/lib/browser/base.rb +6 -0
- data/lib/browser/bot.rb +1 -0
- data/lib/browser/browser.rb +4 -2
- data/lib/browser/detect_version.rb +2 -0
- data/lib/browser/device.rb +8 -1
- data/lib/browser/device/switch.rb +19 -0
- data/lib/browser/facebook.rb +4 -2
- data/lib/browser/instagram.rb +21 -0
- data/lib/browser/middleware.rb +3 -2
- data/lib/browser/platform/ios.rb +2 -2
- data/lib/browser/rails.rb +1 -1
- data/lib/browser/version.rb +1 -1
- data/search_engines.yml +2 -2
- data/test/browser_test.rb +6 -1
- data/test/rails_test.rb +10 -0
- data/test/sample_app.rb +11 -0
- data/test/test_helper.rb +1 -1
- data/test/ua.yml +113 -109
- data/test/ua_bots.yml +88 -60
- data/test/ua_search_engines.yml +6 -6
- data/test/unit/accept_language_test.rb +10 -0
- data/test/unit/bots_test.rb +7 -0
- data/test/unit/device_test.rb +10 -0
- data/test/unit/facebook_test.rb +20 -0
- data/test/unit/instagram_test.rb +20 -0
- metadata +8 -7
- data/gemfiles/rails4.gemfile +0 -4
data/lib/browser/device.rb
CHANGED
@@ -15,6 +15,7 @@ require "browser/device/wii"
|
|
15
15
|
require "browser/device/wiiu"
|
16
16
|
require "browser/device/blackberry_playbook"
|
17
17
|
require "browser/device/surface"
|
18
|
+
require "browser/device/switch"
|
18
19
|
require "browser/device/tv"
|
19
20
|
require "browser/device/xbox_one"
|
20
21
|
require "browser/device/xbox_360"
|
@@ -34,6 +35,7 @@ module Browser
|
|
34
35
|
BlackBerryPlaybook,
|
35
36
|
WiiU,
|
36
37
|
Wii,
|
38
|
+
Switch,
|
37
39
|
KindleFire,
|
38
40
|
Kindle,
|
39
41
|
PlayStation4,
|
@@ -134,6 +136,11 @@ module Browser
|
|
134
136
|
end
|
135
137
|
alias_method :wiiu?, :nintendo_wiiu?
|
136
138
|
|
139
|
+
def nintendo_switch?
|
140
|
+
id == :switch
|
141
|
+
end
|
142
|
+
alias_method :switch?, :nintendo_switch?
|
143
|
+
|
137
144
|
def blackberry_playbook?
|
138
145
|
id == :playbook
|
139
146
|
end
|
@@ -174,7 +181,7 @@ module Browser
|
|
174
181
|
|
175
182
|
# Detect if browser is Nintendo.
|
176
183
|
def nintendo?
|
177
|
-
wii? || wiiu?
|
184
|
+
wii? || wiiu? || switch?
|
178
185
|
end
|
179
186
|
|
180
187
|
# Detect if browser is console (currently Xbox, PlayStation, or Nintendo).
|
data/lib/browser/facebook.rb
CHANGED
@@ -0,0 +1,21 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Browser
|
4
|
+
class Instagram < Base
|
5
|
+
def id
|
6
|
+
:instagram
|
7
|
+
end
|
8
|
+
|
9
|
+
def name
|
10
|
+
"Instagram"
|
11
|
+
end
|
12
|
+
|
13
|
+
def full_version
|
14
|
+
ua[%r[Instagram ([\d.]+)], 1]
|
15
|
+
end
|
16
|
+
|
17
|
+
def match?
|
18
|
+
ua =~ /Instagram/
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
data/lib/browser/middleware.rb
CHANGED
@@ -6,10 +6,11 @@ require "browser/middleware/context"
|
|
6
6
|
module Browser
|
7
7
|
class Middleware
|
8
8
|
# Detect the most common assets.
|
9
|
-
ASSETS_REGEX =
|
9
|
+
ASSETS_REGEX =
|
10
|
+
/\.(css|png|jpe?g|gif|js|svg|ico|flv|mov|m4v|ogg|swf)\z/i.freeze
|
10
11
|
|
11
12
|
# Detect the ACCEPT header. IE8 send */*.
|
12
|
-
ACCEPT_REGEX = %r[(text/html|\*/\*)]
|
13
|
+
ACCEPT_REGEX = %r[(text/html|\*/\*)].freeze
|
13
14
|
|
14
15
|
def initialize(app, &block)
|
15
16
|
raise ArgumentError, "Browser::Middleware requires a block" unless block
|
data/lib/browser/platform/ios.rb
CHANGED
data/lib/browser/rails.rb
CHANGED
@@ -10,7 +10,7 @@ module Browser
|
|
10
10
|
|
11
11
|
initializer "browser" do
|
12
12
|
ActiveSupport.on_load(:action_controller) do
|
13
|
-
::ActionController::
|
13
|
+
::ActionController::Metal.send :include, Browser::ActionController
|
14
14
|
Browser::Middleware::Context.send(
|
15
15
|
:include,
|
16
16
|
Browser::Middleware::Context::Additions
|
data/lib/browser/version.rb
CHANGED
data/search_engines.yml
CHANGED
data/test/browser_test.rb
CHANGED
@@ -105,6 +105,11 @@ class BrowserTest < Minitest::Test
|
|
105
105
|
assert_equal "0", browser.version
|
106
106
|
end
|
107
107
|
|
108
|
+
test "ignores malformed strings when comparing versions" do
|
109
|
+
browser = Browser.new("Chrome/65.0.3325.99.FreeBrowser.3.0.5")
|
110
|
+
refute browser.chrome?(">=65")
|
111
|
+
end
|
112
|
+
|
108
113
|
test "detects unknown id" do
|
109
114
|
browser = Browser.new("Unknown")
|
110
115
|
assert_equal :generic, browser.id
|
@@ -132,7 +137,7 @@ class BrowserTest < Minitest::Test
|
|
132
137
|
browser = Browser.new("", accept_language: accept_language)
|
133
138
|
languages = browser.accept_language.map(&:full)
|
134
139
|
|
135
|
-
assert_equal [
|
140
|
+
assert_equal %w[en-US en pt-BR pt], languages
|
136
141
|
end
|
137
142
|
|
138
143
|
test "removes duplicate items" do
|
data/test/rails_test.rb
CHANGED
@@ -19,4 +19,14 @@ class RailsTest < Minitest::Test
|
|
19
19
|
assert_equal 200, last_response.status
|
20
20
|
assert_equal "Chrome:en-US", last_response.body
|
21
21
|
end
|
22
|
+
|
23
|
+
test "renders json" do
|
24
|
+
get "/api/pages", {}, "HTTP_USER_AGENT" => Browser["COMMONCRAWL"],
|
25
|
+
"HTTP_ACCEPT" => "application/json",
|
26
|
+
"HTTP_ACCEPT_LANGUAGE" => "en-US;q=0.8"
|
27
|
+
|
28
|
+
assert_equal 200, last_response.status
|
29
|
+
assert_equal true, JSON.parse(last_response.body)["isBot"]
|
30
|
+
assert_equal "en-US", JSON.parse(last_response.body)["acceptLanguages"][0]
|
31
|
+
end
|
22
32
|
end
|
data/test/sample_app.rb
CHANGED
@@ -9,6 +9,15 @@ class PagesController < ActionController::Base
|
|
9
9
|
end
|
10
10
|
end
|
11
11
|
|
12
|
+
class PotsController < ActionController::API
|
13
|
+
def index
|
14
|
+
render json: {
|
15
|
+
isBot: browser.bot?,
|
16
|
+
acceptLanguages: browser.accept_language.map(&:full)
|
17
|
+
}
|
18
|
+
end
|
19
|
+
end
|
20
|
+
|
12
21
|
class SampleApp < Rails::Application
|
13
22
|
config.secret_token = "99f19f08db7a37bdcb9d6701f54dca"
|
14
23
|
config.secret_key_base = "99f19f08db7a37bdcb9d6701f54dca"
|
@@ -29,6 +38,8 @@ class SampleApp < Rails::Application
|
|
29
38
|
}
|
30
39
|
|
31
40
|
get "/home", to: "pages#home"
|
41
|
+
|
42
|
+
get "/api/pages", to: "pots#index"
|
32
43
|
end
|
33
44
|
|
34
45
|
config.middleware.use Browser::Middleware do
|
data/test/test_helper.rb
CHANGED
data/test/ua.yml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
|
-
ADOBE_AIR:
|
1
|
+
ADOBE_AIR: "Mozilla/5.0 (Macintosh; U; Intel Mac OS X; de) AppleWebKit/533.19.4 (KHTML, like Gecko) AdobeAIR/13.0"
|
2
2
|
ALIPAY_ANDROID: "Mozilla/5.0 (Linux; U; Android 4.2.1; zh-cn; HUAWEI G610-T00 Build/HuaweiG610-T00) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30 AlipayDefined(nt:WIFI,ws:360|640|1.5) AliApp(AP/9.0.1.073001) AlipayClient/9.0.1.073001 GCanvas/1.4.2.15"
|
3
3
|
ALIPAY_IOS: "Mozilla/5.0 (iPhone; CPU iPhone OS 7_0 like Mac OS X) AppleWebKit/537.51.1 (KHTML, like Gecko) Version/7.0 Mobile/11A465 Safari/9537.53 AliApp(AP/2.3.4) AlipayClient/2.3.4"
|
4
|
-
ANDROID:
|
4
|
+
ANDROID: "Android SDK 1.5r3: Mozilla/5.0 (Linux; U; Android 1.5; de-; sdk Build/CUPCAKE) AppleWebkit/528.5+ (KHTML, like Gecko) Version/3.1.2 Mobile Safari/525.20.1"
|
5
5
|
ANDROID_CUPCAKE: Mozilla/5.0 (Linux; U; Android 1.5; en-gb; T-Mobile G1 Build/CRC1) AppleWebKit/528.5+ (KHTML, like Gecko) Version/3.1.2 Mobile Safari/525.20.1
|
6
6
|
ANDROID_DONUT: Mozilla/5.0 (Linux; U; Android 1.6; ar-us; SonyEricssonX10i Build/R2BA026) AppleWebKit/528.5+ (KHTML, like Gecko) Version/3.1.2 Mobile Safari/525.20.1
|
7
7
|
ANDROID_ECLAIR_21: Mozilla/5.0 (Linux; U; Android 2.1; en-us; Nexus One Build/ERD62) AppleWebKit/530.17 (KHTML, like Gecko) Version/4.0 Mobile Safari/530.17
|
@@ -19,118 +19,122 @@ ANDROID_NEXUS_PLAYER: Mozilla/5.0 (Linux; Android 5.0; Nexus Player Build/LRX21V
|
|
19
19
|
ANDROID_OREO: Mozilla/5.0 (Linux; Android 8.0.0; Pixel Build/OPR6.170623.012) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/60.03112.107 Mobile Safari/537.36
|
20
20
|
ANDROID_TV: Mozilla/5.0 (Linux; Android 5.0; ADT-1 Build/LRW87K) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/37.0.0.0 Mobile Safari/537.36
|
21
21
|
ANDROID_WEBVIEW: Mozilla/5.0 (Linux; Android 5.1.1; Nexus 5 Build/LMY48B; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/43.0.2357.65 Mobile Safari/537.36
|
22
|
-
ANDROID_WITH_SAFARI:
|
23
|
-
BLACKBERRY10:
|
24
|
-
BLACKBERRY4:
|
25
|
-
BLACKBERRY5:
|
26
|
-
BLACKBERRY6:
|
27
|
-
BLACKBERRY7:
|
28
|
-
BLACKBERRY:
|
29
|
-
CHROME:
|
30
|
-
CHROME_OS:
|
31
|
-
COREMEDIA:
|
22
|
+
ANDROID_WITH_SAFARI: "Mozilla/5.0 (Linux; U; Android 4.3; en-us; SCH-I535 Build/JSS15J) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30"
|
23
|
+
BLACKBERRY10: "Mozilla/5.0 (BB10; Touch) AppleWebKit/537.10+ (KHTML, like Gecko) Version/10.0.9.1675 Mobile Safari/537.10+"
|
24
|
+
BLACKBERRY4: "BlackBerry8100/4.2.1 Profile/MIDP-2.0 Configuration/CLDC-1.1 VendorID/103"
|
25
|
+
BLACKBERRY5: "BlackBerry9000/5.0.0.93 Profile/MIDP-2.0 Configuration/CLDC-1.1 VendorID/179"
|
26
|
+
BLACKBERRY6: "Mozilla/5.0 (BlackBerry; U; BlackBerry AAAA; en-US) AppleWebKit/534.11+ (KHTML, like Gecko) Version/6.0.0.141 Mobile Safari/534.11+"
|
27
|
+
BLACKBERRY7: "Mozilla/5.0 (BlackBerry; U; BlackBerry AAAA; en-US) AppleWebKit/534.11+ (KHTML, like Gecko) Version/7.0.0.1 Mobile Safari/534.11+"
|
28
|
+
BLACKBERRY: "BlackBerry7100i/4.1.0 Profile/MIDP-2.0 Configuration/CLDC-1.1 VendorID/103"
|
29
|
+
CHROME: "Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_4; en-US) AppleWebKit/533.4 (KHTML, like Gecko) Chrome/5.0.375.99 Safari/533.4"
|
30
|
+
CHROME_OS: "Mozilla/5.0 (X11; CrOS x86_64 3701.81.0) AppleWebKit/537.31 (KHTML, like Gecko) Chrome/26.0.1410.57 Safari/537.31."
|
31
|
+
COREMEDIA: "Apple Mac OS X v10.6.4 CoreMedia v1.0.0.10F569"
|
32
32
|
CUSTOM_APP: "Our App 0.0.1 (Linux; Android 4.0.3; HTC Ruby Build/IML74K; en_CA)"
|
33
33
|
ELECTRON: "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.143 Electron/1.4.12 Safari/537.36"
|
34
34
|
FACEBOOK: Mozilla/5.0 (iPhone; CPU iPhone OS 10_3_3 like Mac OS X) AppleWebKit/603.3.8 (KHTML, like Gecko) Mobile/14G60 [FBAN/FBIOS;FBAV/135.0.0.45.90;FBBV/66877072;FBDV/iPhone9,3;FBMD/iPhone;FBSN/iOS;FBSV/10.3.3;FBSS/2;FBCR/AT&T;FBID/phone;FBLC/en_US;FBOP/5;FBRV/0]
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
35
|
+
FACEBOOK_ANDROID: "Mozilla/5.0 (Linux; Android 9; ONEPLUS A6003 Build/PKQ1.180716.001; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/73.0.3683.90 Mobile Safari/537.36 [FB_IAB/FB4A;FBAV/214.0.0.43.83;]"
|
36
|
+
FACEBOOK_IOS: "Mozilla/5.0 (iPhone; CPU iPhone OS 12_1_4 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/16D57 [FBAN/FBIOS;FBDV/iPhone11,2;FBMD/iPhone;FBSN/iOS;FBSV/12.1.4;FBSS/3;FBCR/KPN NL;FBID/phone;FBLC/en_GB;FBOP/5]"
|
37
|
+
FIREFOX: "Mozilla/5.0 (X11; U; Linux i686; pl-PL; rv:1.9.0.2) Gecko/20121223 Ubuntu/9.25 (jaunty) Firefox/3.8"
|
38
|
+
FIREFOX_ANDROID: "Mozilla/5.0 (Android; Mobile; rv:40.0) Gecko/40.0 Firefox/40.0"
|
39
|
+
FIREFOX_IOS: "Mozilla/5.0 (iPhone; CPU iPhone OS 9_2 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) FxiOS/1.2 Mobile/13C75 Safari/601.1.46"
|
40
|
+
FIREFOX_MODERN: "Mozilla/5.0 (X11; Ubuntu; Linux armv7l; rv:17.0) Gecko/20100101 Firefox/17.0"
|
41
|
+
FIREFOX_OS: "Mozilla/5.0 (Mobile; rv:18.0) Gecko/18.0 Firefox/18.0"
|
42
|
+
FIREFOX_TABLET: "Mozilla/5.0 (Android; Tablet; rv:14.0) Gecko/14.0 Firefox/14.0"
|
43
|
+
IE10: "Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.1; Trident/6.0; EIE10;ENUSMSN)"
|
44
|
+
IE10_COMPAT: "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; Trident/6.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; EIE10;ENUSMSN)"
|
45
|
+
IE10_X64_WINX64: "Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; Win64; x64; Trident/6.0)"
|
46
|
+
IE11: "Mozilla/5.0 (Windows NT 6.1; Trident/7.0; rv:11.0) like Gecko"
|
47
|
+
IE11_COMPAT: "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.3; WOW64; Trident/7.0; .NET4.0E; .NET4.0C; .NET CLR 3.5.30729; .NET CLR 2.0.50727; .NET CLR 3.0.30729)"
|
48
|
+
IE11_TOUCH_SCREEN: "Mozilla/5.0 (Windows NT 6.3; Win64; x64; Trident/7.0; Touch; rv:11.0) like Gecko"
|
49
|
+
IE6: "Mozilla/5.0 (Windows; U; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 2.0.50727)"
|
50
|
+
IE7: "Mozilla/5.0 (Windows; U; MSIE 7.0; Windows NT 6.0; en-US)"
|
51
|
+
IE8: "Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.2; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0)"
|
52
|
+
IE8_COMPAT: "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; Trident/4.0; SLCC1; Media Center PC 5.0; .NET CLR 3.5.21022)"
|
53
|
+
IE9: "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)"
|
54
|
+
IE9_CHROME_FRAME: "Mozilla/5.0 (Windows NT 6.1; WOW64; chromeframe/26.0.1410.43) AppleWebKit/537.31 (KHTML, like Gecko) Chrome/26.0.1410.43 Safari/537.31"
|
55
|
+
IE9_COMPAT: "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; Trident/5.0)"
|
54
56
|
IE_WITHOUT_TRIDENT: Mozilla/4.0 (compatible; MSIE8.0; Windows NT 6.0) .NET CLR 2.0.50727)
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
57
|
+
INSTAGRAM: "Mozilla/5.0 (iPhone; CPU iPhone OS 11_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E216 Instagram 41.0.0.14.90 (iPhone9,3; iOS 11_3; pl_PL; pl-PL; scale=2.00; gamut=wide; 750x1334)"
|
58
|
+
IOS3: "Mozilla/5.0 (iPad; U; CPU iPhone OS 3_0 like Mac OS X; en-us) AppleWebKit/531.21.10 (KHTML, like Gecko) Version/4.0.4 Mobile/7B314 Safari/531.21.10"
|
59
|
+
IOS4: "Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_0 like Mac OS X; en-us) AppleWebKit/532.9 (KHTML, like Gecko) Version/4.0.5 Mobile/8A293 Safari/6531.22.7"
|
60
|
+
IOS5: "Mozilla/5.0 (iPhone; CPU iPhone OS 5_0 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/5.1 Mobile/9A334 Safari/7534.48.3"
|
61
|
+
IOS6: "Mozilla/5.0 (iPhone; CPU iPhone OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A5376e Safari/8536.25"
|
62
|
+
IOS7: "Mozilla/5.0 (iPhone; CPU iPhone OS 7_0 like Mac OS X) AppleWebKit/537.51.1 (KHTML, like Gecko) Version/7.0 Mobile/11A465 Safari/9537.53"
|
63
|
+
IOS8: "Mozilla/5.0 (iPhone; CPU iPhone OS 8_0 like Mac OS X) AppleWebKit/600.1.4 (KHTML, like Gecko) Version/8.0 Mobile/12A365 Safari/600.1.4"
|
64
|
+
IOS9: "Mozilla/5.0 (iPad; CPU OS 9_0 like Mac OS X) AppleWebKit/601.1.17 (KHTML, like Gecko) Version/8.0 Mobile/13A175 Safari/600.1.4"
|
62
65
|
IOS_WEBVIEW: Mozilla/5.0 (iPhone; CPU iPhone OS 8_4 like Mac OS X) AppleWebKit/600.1.4 (KHTML, like Gecko) Mobile/12H141
|
63
|
-
IPAD:
|
64
|
-
IPHONE:
|
65
|
-
IPOD:
|
66
|
-
KINDLE:
|
67
|
-
KINDLE_FIRE:
|
68
|
-
KINDLE_FIRE_HD:
|
69
|
-
KINDLE_FIRE_HD_MOBILE:
|
70
|
-
LUMIA800:
|
71
|
-
MICRO_MESSENGER:
|
66
|
+
IPAD: "Mozilla/5.0 (iPad; U; CPU OS 3_2 like Mac OS X; en-us) AppleWebKit/531.21.10 (KHTML, like Gecko) Version/4.0.4 Mobile/7B367 Safari/531.21.10"
|
67
|
+
IPHONE: "Mozilla/5.0 (iPhone; U; CPU iPhone OS 3_0 like Mac OS X; en-us) AppleWebKit/420.1 (KHTML, like Gecko) Version/3.0 Mobile/1A542a Safari/419.3"
|
68
|
+
IPOD: "Mozilla/5.0 (iPod; U; CPU like Mac OS X; en) AppleWebKit/420.1 (KHTML, like Gecko) Version/3.0 Mobile/3A100a Safari/419.3"
|
69
|
+
KINDLE: "Mozilla/5.0 (Linux; U; en-US) AppleWebKit/528.5+ (KHTML, like Gecko, Safari/528.5+) Version/4.0 Kindle/3.0 (screen 600×800; rotate)"
|
70
|
+
KINDLE_FIRE: "Mozilla/5.0 (Linux; U; Android 2.3.4; en-us; Kindle Fire Build/GINGERBREAD) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1"
|
71
|
+
KINDLE_FIRE_HD: "Mozilla/5.0 (Linux; U; en-us; KFTT Build/IML74K) AppleWebKit/535.19 (KHTML, like Gecko) Silk/3.4 Safari/535.19 Silk-Accelerated=true"
|
72
|
+
KINDLE_FIRE_HD_MOBILE: "Mozilla/5.0 (Linux; U; Android 4.0.3; en-us; KFTT Build/IML74K) AppleWebKit/535.19 (KHTML, like Gecko) Silk/3.4 Mobile Safari/535.19 Silk-Accelerated=true"
|
73
|
+
LUMIA800: "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0; XBLWP7; ZuneWP7"
|
74
|
+
MICRO_MESSENGER: "Mozilla/5.0 (iPhone; CPU iPhone OS 9_3_1 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/13E238 MicroMessenger/6.3.15 NetType/3G+ Language/zh_CN"
|
72
75
|
MIDP: MIDP-2.0
|
73
|
-
MOBILE_CHROME:
|
74
|
-
MS_EDGE:
|
75
|
-
MS_EDGE_COMPAT:
|
76
|
-
MS_EDGE_MOBILE:
|
77
|
-
NEXUS7:
|
78
|
-
NEXUS_TABLET:
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
76
|
+
MOBILE_CHROME: "Mozilla/5.0 (iPhone; U; CPU iPhone OS 5_1_1 like Mac OS X; en) AppleWebKit/534.46.0 (KHTML, like Gecko) CriOS/19.0.1084.60 Mobile/9B206 Safari/7534.48.3"
|
77
|
+
MS_EDGE: "Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.71 Safari/537.36 Edge/12.0"
|
78
|
+
MS_EDGE_COMPAT: "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.2; WOW64; Trident/8.0; .NET4.0C; .NET4.0E; Tablet PC 2.0; Microsoft Outlook 15.0.4433; ms-office; MSOffice 15)"
|
79
|
+
MS_EDGE_MOBILE: "Mozilla/5.0 (Windows Phone 10.0; Android 4.2.1; DEVICE INFO) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.71 Mobile Safari/537.36 Edge/12.0"
|
80
|
+
NEXUS7: "Mozilla/5.0 (Linux; Android 4.3; Nexus 7 Build/JWR66Y) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.72 Safari/537.36"
|
81
|
+
NEXUS_TABLET: "Mozilla/5.0 (Linux; Android 4.1.1; Nexus 7 Build/JRO03D) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.166 Safari/535.19"
|
82
|
+
NINTENDO_SWITCH: "Mozilla/5.0 (Nintendo Switch; WifiWebAuthApplet) AppleWebKit/601.6 (KHTML, like Gecko) NF/4.0.0.7.9 NintendoBrowser/5.1.0.15785"
|
83
|
+
NINTENDO_WII: "Opera/9.00 (Nintendo Wii; U; ; 1309-9; en)"
|
84
|
+
NINTENDO_WIIU: "Mozilla/5.0 (Nintendo WiiU) AppleWebKit/534.52 (KHTML, like Gecko) NX/2.1.0.8.23 NintendoBrowser/1.1.0.7579.EU"
|
85
|
+
NOKIA: "Mozilla/5.0 (Series40; NokiaX3-02/le6.32; Profile/MIDP-2.1 Configuration/CLDC-1.1) Gecko/20100401 S40OviBrowser/2.0.2.62.10"
|
86
|
+
NOOK: "Mozilla/5.0 (Linux; U; Android 2.3.4; en-us; NOOK BNTV250A Build/GINGERBREAD 1.4.3) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Safari/533.1"
|
87
|
+
OPERA: "Opera/9.80 (Macintosh; Intel Mac OS X 10.7.4; U; en) Presto/2.10.229 Version/11.64"
|
88
|
+
OPERA_ANDROID: "Mozill/5.0 (Linux; Android 4.4.2; A1-810 Build/KOT49H) Apple/WebKit/537.36 (KHTML, like Gecko) Chrome/48.0.25 64.99 Safari/537.36 OPR/35.0.2070.100283"
|
89
|
+
OPERA_MINI: "Opera/9.80 (Android; Opera Mini/7.029952/28.2359;u; fr) Presto/2.8.119 Version/11.10"
|
90
|
+
OPERA_MOBI: "Opera/9.8 (Android 2.3.5; Linux; Opera Mobi/ADR-1205181138; U; en) Presto/2.10.254 Version/12.00"
|
91
|
+
OPERA_NEXT: "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.37 Safari/537.36 OPR/15.0.1147.44 (Edition Next)"
|
88
92
|
OTTER: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/602.1 (KHTML, like Gecko) Otter/0.9.91
|
89
|
-
PHANTOM_JS:
|
90
|
-
PLAYBOOK:
|
91
|
-
PLAYSTATION3:
|
92
|
-
PLAYSTATION4:
|
93
|
-
PSP:
|
94
|
-
PSP_VITA:
|
95
|
-
QQ_BROWSER_ANDROID:
|
96
|
-
QQ_BROWSER_IOS:
|
97
|
-
QQ_BROWSER_MAC:
|
98
|
-
QQ_BROWSER_MAC_LITE:
|
99
|
-
QUICKTIME:
|
100
|
-
SAFARI3:
|
101
|
-
SAFARI4:
|
102
|
-
SAFARI5:
|
103
|
-
SAFARI6:
|
104
|
-
SAFARI7:
|
105
|
-
SAFARI8:
|
106
|
-
SAFARI9:
|
107
|
-
SAFARI:
|
108
|
-
SAFARI_IPAD_WEBAPP_MODE:
|
109
|
-
SAFARI_IPHONE_WEBAPP_MODE:
|
110
|
-
SAMSUNG:
|
111
|
-
SAMSUNG_CHROME:
|
112
|
-
SMART_TV:
|
113
|
-
SURFACE:
|
114
|
-
SYMBIAN:
|
115
|
-
TABLOID:
|
116
|
-
UC_BROWSER:
|
117
|
-
WEIBO_ANDROID:
|
118
|
-
WEIBO_IOS:
|
119
|
-
WINDOWS10:
|
120
|
-
WINDOWS7:
|
121
|
-
WINDOWS81:
|
122
|
-
WINDOWS8:
|
123
|
-
WINDOWS_2000:
|
124
|
-
WINDOWS_2000_SP1:
|
125
|
-
WINDOWS_MOBILE:
|
126
|
-
WINDOWS_PHONE8:
|
127
|
-
WINDOWS_PHONE:
|
128
|
-
WINDOWS_PHONE_81:
|
129
|
-
WINDOWS_VISTA:
|
93
|
+
PHANTOM_JS: "Mozilla/5.0 (Macintosh; Intel Mac OS X) AppleWebKit/534.34 (KHTML, like Gecko) PhantomJS/1.9.0 Safari/534.34"
|
94
|
+
PLAYBOOK: "Mozilla/5.0 (PlayBook; U; RIM Tablet OS 2.1.0; en-US) AppleWebKit/536.2+ (KHTML, like Gecko) Version/7.2.1.0 Safari/536.2+"
|
95
|
+
PLAYSTATION3: "Mozilla/5.0 (PLAYSTATION 3; 3.55)"
|
96
|
+
PLAYSTATION4: "Mozilla/5.0 (PlayStation 4 1.020) AppleWebKit/536.26 (KHTML, like Gecko)"
|
97
|
+
PSP: "Mozilla/4.0 (PSP (PlayStation Portable); 2.00)"
|
98
|
+
PSP_VITA: "Mozilla/5.0 (Playstation Vita 1.61) AppleWebKit/531.22.8 (KHTML, like Gecko) Silk/3.2"
|
99
|
+
QQ_BROWSER_ANDROID: "Mozilla/5.0 (Linux; Android 5.1.1; SM-N9108V Build/LMY47X) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/37.0.0.0 Mobile MQQBrowser/6.2 TBS/036222 Safari/537.36 V1_AND_SQ_6.2.0_320_YYB_D QQ/6.2.0.2655 NetType/WIFI WebP/0.3.0 Pixel/1440"
|
100
|
+
QQ_BROWSER_IOS: "Mozilla/5.0 (iPhone; CPU iPhone OS 9_3_1 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/13E238 QQ/6.3.3.432 V1_IPH_SQ_6.3.3_1_APP_A Pixel/640 Core/UIWebView NetType/WIFI Mem/47"
|
101
|
+
QQ_BROWSER_MAC: "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.98 Safari/537.36 QQBrowser/4.2.4753.400"
|
102
|
+
QQ_BROWSER_MAC_LITE: "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_1) AppleWebKit/602.2.14 (KHTML, like Gecko) Version/10.0.1 Safari/602.2.14 QQBrowserLite/1.0.4"
|
103
|
+
QUICKTIME: "QuickTime/7.6.8 (qtver=7.6.8;os=Windows NT 5.1Service Pack 3)"
|
104
|
+
SAFARI3: "Mozilla/5.0 (Windows; U; Windows NT 6.0; en) AppleWebKit/522.15.5 (KHTML, like Gecko) Version/3.0.3 Safari/522.15.5"
|
105
|
+
SAFARI4: "Mozilla/5.0 (Windows; U; Windows NT 6.0; fr-ch) AppleWebKit/531.9 (KHTML, like Gecko) Version/4.0.3 Safari/531.9"
|
106
|
+
SAFARI5: "Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_6; fr-ch) AppleWebKit/533.19.4 (KHTML, like Gecko) Version/5.0.3 Safari/533.19.4"
|
107
|
+
SAFARI6: "Mozilla/5.0 (iPad; CPU OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A5355d Safari/8536.25"
|
108
|
+
SAFARI7: "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9) AppleWebKit/537.71 (KHTML, like Gecko) Version/7.0 Safari/537.71"
|
109
|
+
SAFARI8: "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_90) AppleWebKit/600.1.25 (KHTML, like Gecko) Version/8.0 Safari/600.1.25"
|
110
|
+
SAFARI9: "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_2) AppleWebKit/601.3.9 (KHTML, like Gecko) Version/9.0.2 Safari/601.3.9"
|
111
|
+
SAFARI: "Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_4; en-us) AppleWebKit/533.17.8 (KHTML, like Gecko) Version/5.0.1 Safari/533.17.8"
|
112
|
+
SAFARI_IPAD_WEBAPP_MODE: "Mozilla/5.0 (iPad; U; CPU OS 3_2_1 like Mac OS X; en-us) AppleWebKit/531.21.10 (KHTML, like Gecko) Mobile/7B405"
|
113
|
+
SAFARI_IPHONE_WEBAPP_MODE: "Mozilla/5.0 (iPhone; U; CPU iPhone OS 3_2 like Mac OS X; en-us) AppleWebKit/531.21.20 (KHTML, like Gecko) Mobile/7B298g"
|
114
|
+
SAMSUNG: "Mozilla/5.0 (Linux; U; Android 4.0.4; en-us; SAMSUNG-SGH-I497 Build/IMM76D) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Safari/534.30"
|
115
|
+
SAMSUNG_CHROME: "Mozilla/5.0 (Linux; Android 4.4.2; en-gb; SAMSUNG GT-I9195/I9195XXUCNEA Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Version/1.5 Chrome/28.0.1500.94 Mobile Safari/537.36"
|
116
|
+
SMART_TV: "Mozilla/5.0 (SmartHub; SMART-TV; U; Linux/SmartTV) AppleWebKit/531.2+ (KHTML, like Gecko) WebBrowser/1.0 SmartTV Safari/531.2+"
|
117
|
+
SURFACE: "Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; ARM; Trident/6.0; Touch)"
|
118
|
+
SYMBIAN: "Nokia5250/10.0.011 (SymbianOS/9.4; U; Series60/5.0 Mozilla/5.0; Profile/MIDP-2.1 Configuration/CLDC-1.1 ) AppleWebKit/525 (KHTML, like Gecko) Safari/525 3gpp-gba"
|
119
|
+
TABLOID: "Mozilla/5.0 (Linux; U; Android 3.0; en-us; Xoom Build/HRI39) AppleWebKit/534.13 (KHTML, like Gecko) Version/4.0 Safari/534.13"
|
120
|
+
UC_BROWSER: "Mozilla/5.0 (Linux; U; Android 4.4.2; en-US; GT-I9500 Build/KOT49H) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 UCBrowser/9.9.4.484 U3/0.8.0 Mobile Safari/533.1"
|
121
|
+
WEIBO_ANDROID: "Mozilla/5.0 (Linux; Android 5.0.2; vivo X5M Build/LRX22G) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/37.0.0.0 Mobile Safari/537.36 Weibo (vivo-vivo X5M__weibo__5.7.1__android__android5.0.2)"
|
122
|
+
WEIBO_IOS: "Mozilla/5.0 (iPhone; CPU iPhone OS 8_4 like Mac OS X) AppleWebKit/600.1.4 (KHTML, like Gecko) Mobile/12H143 Weibo (iPhone7,2__weibo__5.7.1__iphone__os8.4)"
|
123
|
+
WINDOWS10: "Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 10.0; Trident/6.0)"
|
124
|
+
WINDOWS7: "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0) chromeframe/10.0.648.205"
|
125
|
+
WINDOWS81: "Mozilla/5.0 (IE 11.0; Windows NT 6.3; Trident/7.0; .NET4.0E; .NET4.0C; rv:11.0) like Gecko"
|
126
|
+
WINDOWS8: "Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; Trident/6.0)"
|
127
|
+
WINDOWS_2000: "Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 5.0; Trident/6.0)"
|
128
|
+
WINDOWS_2000_SP1: "Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 5.01; Trident/6.0)"
|
129
|
+
WINDOWS_MOBILE: "Mozilla/4.0 (compatible; MSIE 6.0; Windows CE; IEMobile 6.12)"
|
130
|
+
WINDOWS_PHONE8: "Mozilla/5.0 (compatible; MSIE 10.0; Windows Phone 8.0; Trident/6.0; IEMobile/10.0; ARM; Touch; NOKIA; Lumia 920)"
|
131
|
+
WINDOWS_PHONE: "Mozilla/4.0 (compatible; MSIE 7.0; Windows Phone OS 7.0; Trident/3.1; IEMobile/7.0; DELL; Venue Pro)"
|
132
|
+
WINDOWS_PHONE_81: "Mozilla/5.0 (Mobile; Windows Phone 8.1; Android 4.0; ARM; Trident/7.0; Touch; rv:11.0; IEMobile/11.0; NOKIA; Lumia 929) like iPhone OS 7_0_3 Mac OS X AppleWebKit/537 (KHTML, like Gecko) Mobile Safari/537"
|
133
|
+
WINDOWS_VISTA: "Mozilla/5.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; .NET CLR 1.0.3705; .NET CLR 1.1.4322)"
|
130
134
|
WINDOWS_WOW64: "Mozilla/5.0 (Windows NT 6.3; WOW64; Trident/7.0; Touch; rv:11.0) like Gecko"
|
131
|
-
WINDOWS_XP:
|
132
|
-
WINDOWS_XP_64:
|
133
|
-
XBOX360:
|
134
|
-
XBOXONE:
|
135
|
-
XOOM:
|
136
|
-
YANDEX_BROWSER:
|
135
|
+
WINDOWS_XP: "Mozilla/4.0 (compatible; MSIE 7.0b; Windows NT 5.1; FDM; .NET CLR 1.1.4322)"
|
136
|
+
WINDOWS_XP_64: "Mozilla/4.0 (Compatible; MSIE 8.0; Windows NT 5.2; Trident/6.0)"
|
137
|
+
XBOX360: "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0; Xbox), or Mozilla/5.0 (compatible; MSIE 9.0; Windows Phone OS 7.5; Trident/5.0; IEMobile/9.0; Xbox)"
|
138
|
+
XBOXONE: "Mozilla/5.0 (Compatible; MSIE 10.0; Windows NT 6.2; Trident /6.0; Xbox; Xbox One)"
|
139
|
+
XOOM: "Mozilla/5.0 (Linux; U; Android 3.0; en-us; Xoom Build/HRI39) AppleWebKit/534.13 (KHTML, like Gecko) Version/4.0 Safari/534.13"
|
140
|
+
YANDEX_BROWSER: "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2272.118 YaBrowser/15.4.2272.3909 (beta) Yowser/2.0 Safari/537.36"
|