3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the Revised BSD License.
6 This program is distributed in the hope that it will be useful,
7 but WITHOUT ANY WARRANTY; without even the implied warranty of
8 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
9 Revised BSD License for more details.
11 Copyright 2004-2023 iDB Support - https://idb.osdn.jp/support/category.php?act=view&id=1
12 Copyright 2004-2023 Game Maker 2k - https://idb.osdn.jp/support/category.php?act=view&id=2
14 $FileInfo: useragents.php - Last Update: 6/22/2023 SVN 984 - Author: cooldude2k $
17 function user_agent_check($user_agent) {
18 global $Settings, $UserAgentName, $AltUserAgentName, $RName, $AltName;
19 if(!isset($Settings['log_spiders_bots'])) {
20 $Settings['log_spiders_bots'] = "yes"; }
21 if($Settings['log_spiders_bots']!=="yes") {
23 if (preg_match("/".preg_quote("; 008/", "/")."/i", $user_agent)) {
25 if (preg_match("/".preg_quote("Aboundex", "/")."/i", $user_agent)) {
27 if (preg_match("/".preg_quote("AboutUsBot", "/")."/i", $user_agent)) {
29 if (preg_match("/".preg_quote("AhrefsBot", "/")."/i", $user_agent)) {
31 if (preg_match("/".preg_quote("ia_archiver", "/")."/i", $user_agent)) {
33 if (preg_match("/".preg_quote("aiHitBot", "/")."/i", $user_agent)) {
35 if (preg_match("/".preg_quote("AlkalineBot", "/")."/i", $user_agent)) {
37 if (preg_match("/".preg_quote("AltaVista", "/")."/i", $user_agent)) {
39 if (preg_match("/".preg_quote("Ask Jeeves", "/")."/i", $user_agent)) {
40 return "Ask Jeeves"; }
41 if (preg_match("/".preg_quote("Teoma", "/")."/i", $user_agent)) {
42 return "Ask Jeeves"; }
43 if (preg_match("/".preg_quote("WhatCMS", "/")."/i", $user_agent)) {
45 if (preg_match("/".preg_quote("askpeter_bot", "/")."/i", $user_agent)) {
47 if (preg_match("/".preg_quote("ASPseek", "/")."/i", $user_agent)) {
49 if (preg_match("/".preg_quote("Baiduspider", "/")."/i", $user_agent)) {
51 if (preg_match("/".preg_quote("BaiduImagespider", "/")."/i", $user_agent)) {
53 if (preg_match("/".preg_quote("Baidu", "/")."/i", $user_agent)) {
54 if (!preg_match("/".preg_quote("BIDUBrowser", "/")."/i", $user_agent)) {
57 if (preg_match("/".preg_quote("bingbot", "/")."/i", $user_agent)) {
59 if (preg_match("/".preg_quote("msnbot", "/")."/i", $user_agent)) {
61 if (preg_match("/".preg_quote("AdIdxBot", "/")."/i", $user_agent)) {
63 if (preg_match("/".preg_quote("CatchBot", "/")."/i", $user_agent)) {
65 if (preg_match("/".preg_quote("Cityreview Robot", "/")."/i", $user_agent)) {
66 return "Cityreview"; }
67 if (preg_match("/".preg_quote("CCBot", "/")."/i", $user_agent)) {
68 return "CommonCrawl"; }
69 if (preg_match("/".preg_quote("cmsworldmap.com", "/")."/i", $user_agent)) {
70 return "CMSWorldMap"; }
71 if (preg_match("/".preg_quote("CSE HTML Validator", "/")."/i", $user_agent)) {
72 return "CSE HTML Validator"; }
73 if (preg_match("/".preg_quote("discobot", "/")."/i", $user_agent)) {
74 return "DiscoveryEngine"; }
75 if (preg_match("/".preg_quote("DnsQueries", "/")."/i", $user_agent)) {
76 return "DNSQueries"; }
77 if (preg_match("/".preg_quote("Domnutch-Bot", "/")."/i", $user_agent)) {
79 if (preg_match("/".preg_quote("DotBot", "/")."/i", $user_agent)) {
81 if (preg_match("/".preg_quote("DuckDuckBot", "/")."/i", $user_agent)) {
82 return "DuckDuckGo"; }
83 if (preg_match("/".preg_quote("Exabot", "/")."/i", $user_agent)) {
85 if (preg_match("/".preg_quote("Ezooms", "/")."/i", $user_agent)) {
87 if (preg_match("/".preg_quote("facebookexternalhit", "/")."/i", $user_agent)) {
89 if (preg_match("/".preg_quote("Feedtrace-bot", "/")."/i", $user_agent)) {
90 return "FeedtraceBot"; }
91 if (preg_match("/".preg_quote("findfiles.net", "/")."/i", $user_agent)) {
92 return "FindFiles Bot"; }
93 if (preg_match("/".preg_quote("FreeWebMonitoring", "/")."/i", $user_agent)) {
94 return "FreeWebMonitoring"; }
95 if (preg_match("/".preg_quote("FlightDeckReportsBot", "/")."/i", $user_agent)) {
96 return "FlightDeck Reports"; }
97 if (preg_match("/".preg_quote("GIDBot", "/")."/i", $user_agent)) {
98 return "GIDNetwork"; }
99 if (preg_match("/".preg_quote("ichiro", "/")."/i", $user_agent)) {
100 return "Goo Japan"; }
101 if (preg_match("/".preg_quote("moget", "/")."/i", $user_agent)) {
102 return "Goo Japan"; }
103 if (preg_match("/".preg_quote("mogimogi", "/")."/i", $user_agent)) {
104 return "Goo Japan"; }
105 if (preg_match("/".preg_quote("AdsBot-Google", "/")."/i", $user_agent)) {
107 if (preg_match("/".preg_quote("FeedFetcher-Google", "/")."/i", $user_agent)) {
109 if (preg_match("/".preg_quote("GoogleProducer", "/")."/i", $user_agent)) {
111 if (preg_match("/".preg_quote("Storebot-Google", "/")."/i", $user_agent)) {
113 if (preg_match("/".preg_quote("APIs-Google", "/")."/i", $user_agent)) {
115 if (preg_match("/".preg_quote("Google-InspectionTool", "/")."/i", $user_agent)) {
117 if (preg_match("/".preg_quote("AppEngine-Google", "/")."/i", $user_agent)) {
119 if (preg_match("/".preg_quote("Googlebot", "/")."/i", $user_agent)) {
121 if (preg_match("/".preg_quote("Mediapartners-Google", "/")."/i", $user_agent)) {
123 if (preg_match("/".preg_quote("ChatGPT-User", "/")."/i", $user_agent)) {
125 if (preg_match("/".preg_quote("Gigabot", "/")."/i", $user_agent)) {
126 return "Gigablast"; }
127 if (preg_match("/".preg_quote("Grub", "/")."/i", $user_agent)) {
129 if (preg_match("/".preg_quote("Hailoobot", "/")."/i", $user_agent)) {
130 return "Hailoobot"; }
131 if (preg_match("/".preg_quote("AOLBuild", "/")."/i", $user_agent)) {
133 if (preg_match("|".preg_quote("HTML/XML Validator", "|")."|i", $user_agent)) {
134 return "HTML/XML Validator"; }
135 if (preg_match("/".preg_quote("Huaweisymantecspider", "/")."/i", $user_agent)) {
136 return "Huaweisymantecspider"; }
137 if (preg_match("|".preg_quote("iDB-VerCheck", "|")."|i", $user_agent)) {
138 return "iDB Version Checker"; }
139 if (preg_match("|".preg_quote("iDB-Forum", "|")."|i", $user_agent)) {
140 return "iDB Message Board"; }
141 if (preg_match("|".preg_quote("DF2k-VerCheck", "|")."|i", $user_agent)) {
142 return "DF2k Version Checker"; }
143 if (preg_match("|".preg_quote("DF2k-Forum", "|")."|i", $user_agent)) {
144 return "DF2k Message Board"; }
145 if (preg_match("|".preg_quote($UserAgentName, "|")."|i", $user_agent)) {
146 return $RName." Message Board"; }
147 if (preg_match("|".preg_quote($AltUserAgentName, "|")."|i", $user_agent)) {
148 return $AltName." Message Board"; }
149 if (preg_match("/".preg_quote("Infoseek", "/")."/i", $user_agent)) {
151 if (preg_match("/".preg_quote("IRLbot", "/")."/i", $user_agent)) {
153 if (preg_match("/".preg_quote("Linguee Bot", "/")."/i", $user_agent)) {
155 if (preg_match("/".preg_quote("Lycos", "/")."/i", $user_agent)) {
157 if (preg_match("/".preg_quote("LexxeBot", "/")."/i", $user_agent)) {
159 if (preg_match("/".preg_quote("MJ12bot", "/")."/i", $user_agent)) {
160 return "Majestic-12"; }
161 if (preg_match("/".preg_quote("MLBot", "/")."/i", $user_agent)) {
163 if (preg_match("/".preg_quote("montastic-monitor", "/")."/i", $user_agent)) {
164 return "Montastic"; }
165 if (preg_match("/".preg_quote("montastic-webmonitor", "/")."/i", $user_agent)) {
166 return "Montastic"; }
167 if (preg_match("/".preg_quote("mozDex", "/")."/i", $user_agent)) {
169 if (preg_match("/".preg_quote("Mail.Ru", "/")."/i", $user_agent)) {
171 if (preg_match("/".preg_quote("MP3Bot", "/")."/i", $user_agent)) {
173 if (preg_match("/".preg_quote("mxbot", "/")."/i", $user_agent)) {
175 if (preg_match("/".preg_quote("NaverBot", "/")."/i", $user_agent)) {
177 if (preg_match("/".preg_quote("NetSprint", "/")."/i", $user_agent)) {
178 return "NetSprint"; }
179 if (preg_match("/".preg_quote("NextGenSearchBot", "/")."/i", $user_agent)) {
181 if (preg_match("/".preg_quote("; oBot\/", "/")."/i", $user_agent)) {
183 if (preg_match("/".preg_quote("Openbot", "/")."/i", $user_agent)) {
185 if (preg_match("/".preg_quote("Page2RSS", "/")."/i", $user_agent)) {
187 if (preg_match("/".preg_quote("Peew", "/")."/i", $user_agent)) {
189 if (preg_match("/".preg_quote("PicoSearch", "/")."/i", $user_agent)) {
190 return "PicoSearch"; }
191 if (preg_match("/".preg_quote("Plukkie", "/")."/i", $user_agent)) {
193 if (preg_match("/".preg_quote("Purebot", "/")."/i", $user_agent)) {
194 return "PuritySearch"; }
195 if (preg_match("/".preg_quote("QweeryBot", "/")."/i", $user_agent)) {
196 return "QweeryBot"; }
197 if (preg_match("/".preg_quote("R6_FeedFetcher", "/")."/i", $user_agent)) {
199 if (preg_match("/".preg_quote("radian6_linkcheck", "/")."/i", $user_agent)) {
201 if (preg_match("/".preg_quote("smerity", "/")."/i", $user_agent)) {
202 return "Schwa Lab"; }
203 if (preg_match("/".preg_quote("ScoutJet", "/")."/i", $user_agent)) {
205 if (preg_match("/".preg_quote("Search17Bot", "/")."/i", $user_agent)) {
207 if (preg_match("/".preg_quote("Setooz", "/")."/i", $user_agent)) {
209 if (preg_match("/".preg_quote("Speedy Spider", "/")."/i", $user_agent)) {
210 return "Entireweb"; }
211 if (preg_match("/".preg_quote("Argus", "/")."/i", $user_agent)) {
213 if (preg_match("/".preg_quote("seexie.com_bot", "/")."/i", $user_agent)) {
215 if (preg_match("/".preg_quote("SemrushBot", "/")."/i", $user_agent)) {
216 return "SemrushBot"; }
217 if (preg_match("/".preg_quote("SiteBot", "/")."/i", $user_agent)) {
219 if (preg_match("/".preg_quote("Sogou", "/")."/i", $user_agent)) {
221 if (preg_match("/".preg_quote("Sosospider", "/")."/i", $user_agent)) {
223 if (preg_match("/".preg_quote("spbot", "/")."/i", $user_agent)) {
225 if (preg_match("/".preg_quote("Speedy Spider", "/")."/i", $user_agent)) {
227 if (preg_match("/".preg_quote("SpiderMonkey", "/")."/i", $user_agent)) {
228 return "SpiderMonkey"; }
229 if (preg_match("/".preg_quote("Spider_Monkey", "/")."/i", $user_agent)) {
230 return "SpiderMonkey"; }
231 if (preg_match("/".preg_quote("SISTRIX Crawler", "/")."/i", $user_agent)) {
232 return "SISTRIX Crawler"; }
233 if (preg_match("/".preg_quote("Szukacz", "/")."/i", $user_agent)) {
234 return "Szukacz.pl"; }
235 if (preg_match("/".preg_quote("tangyang9@gmail.com", "/")."/i", $user_agent)) {
236 return "tangyangbot"; }
237 if (preg_match("/".preg_quote("Thriceler", "/")."/i", $user_agent)) {
238 return "Thriceler"; }
239 if (preg_match("/".preg_quote("TotalValidator", "/")."/i", $user_agent)) {
240 return "Total Validator"; }
241 if (preg_match("/".preg_quote("Twitterbot", "/")."/i", $user_agent)) {
242 return "Twitterbot"; }
243 if (preg_match("/".preg_quote("Ultraseek", "/")."/i", $user_agent)) {
244 return "UltraSeek"; }
245 if (preg_match("/".preg_quote("Validator.nu", "/")."/i", $user_agent)) {
246 return "Validator.nu"; }
247 if (preg_match("/".preg_quote("Voyager", "/")."/i", $user_agent)) {
249 if (preg_match("/".preg_quote("W3CRobot", "/")."/i", $user_agent)) {
250 return "W3C Checklink"; }
251 if (preg_match("/".preg_quote("W3C-checklink", "/")."/i", $user_agent)) {
252 return "W3C Checklink"; }
253 if (preg_match("/".preg_quote("FeedValidator", "/")."/i", $user_agent)) {
254 return "W3C Validator"; }
255 if (preg_match("/".preg_quote("W3C_CSS_Validator", "/")."/i", $user_agent)) {
256 return "W3C Validator"; }
257 if (preg_match("/".preg_quote("W3C_Validator", "/")."/i", $user_agent)) {
258 return "W3C Validator"; }
259 if (preg_match("/".preg_quote("WDG_SiteValidator", "/")."/i", $user_agent)) {
260 return "WDG Validator"; }
261 if (preg_match("/".preg_quote("WDG_Validator", "/")."/i", $user_agent)) {
262 return "WDG Validator"; }
263 if (preg_match("/".preg_quote("HTTP Compression Test", "/")."/i", $user_agent)) {
264 return "WhatsMyIP"; }
265 if (preg_match("/".preg_quote("HuaweiSymantecSpider", "/")."/i", $user_agent)) {
266 return "Huawei Symantec"; }
267 if (preg_match("/".preg_quote("WhatsMyIP.org", "/")."/i", $user_agent)) {
268 return "WhatsMyIP"; }
269 if (preg_match("/".preg_quote("WTABOT", "/")."/i", $user_agent)) {
271 if (preg_match("/".preg_quote("Yahoo", "/")."/i", $user_agent)) {
273 if (preg_match("/".preg_quote("Slurp", "/")."/i", $user_agent)) {
275 if (preg_match("/".preg_quote("Yandex", "/")."/i", $user_agent)) {
277 if (preg_match("/".preg_quote("YaDirectFetcher", "/")."/i", $user_agent)) {
279 if (preg_match("/".preg_quote("YoudaoBot", "/")."/i", $user_agent)) {
280 return "YoudaoBot"; }
281 if (preg_match("/".preg_quote("YodaoBot", "/")."/i", $user_agent)) {
283 if (preg_match("/".preg_quote("PyWWW-Get", "/")."/i", $user_agent)) {
284 return "PyWWW-Get"; }
285 if (preg_match("/".preg_quote("curl", "/")."/i", $user_agent)) {
287 if (preg_match("/".preg_quote("Yeti", "/")."/i", $user_agent)) {
288 return "NHN Naver"; }