Skip to content

Commit 2181559

Browse files
committed
[submodule:extensions] Add new email: Airmail, BlueMail, eMClient, NaverMailApp, Sparrow, Yahoo
1 parent 14caf6d commit 2181559

File tree

2 files changed

+97
-3
lines changed

2 files changed

+97
-3
lines changed

src/extensions/ua-parser-extensions.js

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ const Crawlers = Object.freeze({
4242
[
4343
// AhrefsBot - https://ahrefs.com/robot
4444
// Amazonbot - https://developer.amazon.com/amazonbot
45-
// Applebot - http://apple.com/go/applebot
4645
// Bingbot - http://www.bing.com/bingbot.htm
4746
// CCBot - https://commoncrawl.org/faq
4847
// Dotbot - https://moz.com/help/moz-procedures/crawlers/dotbot
@@ -54,7 +53,10 @@ const Crawlers = Object.freeze({
5453
// OpenAI's SearchGPT - https://platform.openai.com/docs/bots
5554
// PerplexityBot - https://perplexity.ai/perplexitybot
5655
// SemrushBot - http://www.semrush.com/bot.html
57-
/((?:ahrefs|amazon|apple|bing|cc|dot|duckduck|exa|facebook|gpt|mj12|mojeek|oai-search|perplexity|semrush)bot)\/([\w\.]+)/i,
56+
/((?:ahrefs|amazon|bing|cc|dot|duckduck|exa|facebook|gpt|mj12|mojeek|oai-search|perplexity|semrush)bot)\/([\w\.]+)/i,
57+
58+
// Applebot - http://apple.com/go/applebot
59+
/(applebot(?:-extended)?)\/([\w\.]+)/i,
5860

5961
// Baiduspider https://help.baidu.com/question?prod_id=99&class=0&id=3001
6062
/(baiduspider)[-imagevdonsfcpr]{0,6}\/([\w\.]+)/i,
@@ -195,8 +197,10 @@ const ExtraDevices = Object.freeze({
195197

196198
const Emails = Object.freeze({
197199
browser : [
200+
[
198201
// Evolution / Kontact/KMail / [Microsoft/Mac] Outlook / Thunderbird
199-
[/(evolution|kmail2?|kontact|(?:microsoft |mac)outlook|thunderbird)[\s\/]([\w\.]+)/i], [NAME, VERSION, [TYPE, EMAIL]]
202+
/(airmail|bluemail|emclient|evolution|foxmail|kmail2?|kontact|(?:microsoft |mac)?outlook(?:-express)?|navermailapp|(?!chrom.+)sparrow|thunderbird|yahoo)(?:m.+ail; |[\/ ])([\w\.]+)/i
203+
], [NAME, VERSION, [TYPE, EMAIL]]
200204
]
201205
});
202206

test/specs/browser-emails.json

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,34 @@
11
[
2+
{
3+
"desc" : "Airmail",
4+
"ua" : "Airmail 1.0 rv:148 (Macintosh; Mac OS X 10.8.3; en_BE)",
5+
"expect" :
6+
{
7+
"name" : "Airmail",
8+
"version" : "1.0",
9+
"type" : "email"
10+
}
11+
},
12+
{
13+
"desc" : "BlueMail",
14+
"ua" : "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) BlueMail/0.10.31 Chrome/61.0.3163.100 Electron/2.0.18 Safari/537.36",
15+
"expect" :
16+
{
17+
"name" : "BlueMail",
18+
"version" : "0.10.31",
19+
"type" : "email"
20+
}
21+
},
22+
{
23+
"desc" : "BlueMail",
24+
"ua" : "Mozilla/5.0 (iPhone; CPU iPhone OS 12_0_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/16A405 BlueMail iOS",
25+
"expect" :
26+
{
27+
"name" : "BlueMail",
28+
"version" : "iOS",
29+
"type" : "email"
30+
}
31+
},
232
{
333
"desc" : "Evolution",
434
"ua" : "Evolution/3.52.3",
@@ -9,6 +39,26 @@
939
"type" : "email"
1040
}
1141
},
42+
{
43+
"desc" : "eM Client",
44+
"ua" : "eMClient/9.2.2157.0",
45+
"expect" :
46+
{
47+
"name" : "eMClient",
48+
"version" : "9.2.2157.0",
49+
"type" : "email"
50+
}
51+
},
52+
{
53+
"desc" : "Foxmail",
54+
"ua" : "Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.110 Safari/537.36 foxmail/7.2.15.80",
55+
"expect" :
56+
{
57+
"name" : "foxmail",
58+
"version" : "7.2.15.80",
59+
"type" : "email"
60+
}
61+
},
1262
{
1363
"desc" : "KMail",
1464
"ua" : "KMail/4.14.10 (FreeBSD/12.0-CURRENT; KDE/4.14.10; amd64; ; )",
@@ -59,6 +109,26 @@
59109
"type" : "email"
60110
}
61111
},
112+
{
113+
"desc" : "NaverMailApp",
114+
"ua" : "NaverMailApp/2.1.23 (Android 10; SM-N960N)",
115+
"expect" :
116+
{
117+
"name" : "NaverMailApp",
118+
"version" : "2.1.23",
119+
"type" : "email"
120+
}
121+
},
122+
{
123+
"desc" : "Sparrow",
124+
"ua" : "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/604.5.6 (KHTML, like Gecko) Sparrow/1043.1",
125+
"expect" :
126+
{
127+
"name" : "Sparrow",
128+
"version" : "1043.1",
129+
"type" : "email"
130+
}
131+
},
62132
{
63133
"desc" : "Thunderbird",
64134
"ua" : "Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0",
@@ -68,5 +138,25 @@
68138
"version" : "78.13.0",
69139
"type" : "email"
70140
}
141+
},
142+
{
143+
"desc" : "Yahoo! Mail",
144+
"ua" : "YahooMobile/1.0 (mail; 3.0.5.1311380); (Linux; U; Android 4.0.3; htc_runnymede Build/ICE_CREAM_SANDWICH_MR1);",
145+
"expect" :
146+
{
147+
"name" : "Yahoo",
148+
"version" : "3.0.5.1311380",
149+
"type" : "email"
150+
}
151+
},
152+
{
153+
"desc" : "Yahoo! Mail",
154+
"ua" : "YahooMobileMail/1.0 (Android Mail; 1.3.10) (supersonic;HTC;PC36100;2.3.5/GRJ90) ",
155+
"expect" :
156+
{
157+
"name" : "Yahoo",
158+
"version" : "1.3.10",
159+
"type" : "email"
160+
}
71161
}
72162
]

0 commit comments

Comments
 (0)