[6.0] 4f4be6fc2 Updating devicedetect.vcl to upstream

Dridi Boukelmoune dridi.boukelmoune at gmail.com
Tue Feb 19 15:23:09 UTC 2019


commit 4f4be6fc2b4534e755243cc4551343834b6a1ac2
Author: Dridi Boukelmoune <dridi.boukelmoune at gmail.com>
Date:   Tue Feb 19 15:47:08 2019 +0100

    Updating devicedetect.vcl to upstream

diff --git a/etc/devicedetect.vcl b/etc/devicedetect.vcl
index 1910743f4..cabc16a45 100644
--- a/etc/devicedetect.vcl
+++ b/etc/devicedetect.vcl
@@ -1,4 +1,6 @@
-# Copyright (c) 2012-2014 Varnish Software AS
+#
+# Copyright (c) 2016-2018 Varnish Cache project
+# Copyright (c) 2012-2016 Varnish Software AS
 #
 # Redistribution and use in source and binary forms, with or without
 # modification, are permitted provided that the following conditions
@@ -24,7 +26,7 @@
 # detectdevice.vcl - regex based device detection for Varnish
 # https://github.com/varnishcache/varnish-devicedetect/
 #
-# Author: Lasse Karstensen <lkarsten at varnish-software.com>
+# Original author: Lasse Karstensen <lkarsten at varnish-software.com>
 
 sub devicedetect {
 	unset req.http.X-UA-Device;
@@ -45,7 +47,10 @@ sub devicedetect {
             set req.http.X-UA-Device = "mobile-bot"; }
 		elsif (req.http.User-Agent ~ "(?i)(ads|google|bing|msn|yandex|baidu|ro|career|seznam|)bot" ||
 		    req.http.User-Agent ~ "(?i)(baidu|jike|symantec)spider" ||
+		    req.http.User-Agent ~ "(?i)pingdom" ||
+		    req.http.User-Agent ~ "(?i)facebookexternalhit" ||
 		    req.http.User-Agent ~ "(?i)scanner" ||
+		    req.http.User-Agent ~ "(?i)slurp" ||
 		    req.http.User-Agent ~ "(?i)(web)crawler") {
 			set req.http.X-UA-Device = "bot"; }
 		elsif (req.http.User-Agent ~ "(?i)ipad")        { set req.http.X-UA-Device = "tablet-ipad"; }
@@ -94,8 +99,6 @@ sub devicedetect {
 		    req.http.User-Agent ~ "(?i)playstation portable" ||
 		    req.http.User-Agent ~ "(?i)portalmmm" ||
 		    req.http.User-Agent ~ "(?i)proxinet" ||
-		    req.http.User-Agent ~ "(?i)sonyericsson" ||
-		    req.http.User-Agent ~ "(?i)symbian" ||
 		    req.http.User-Agent ~ "(?i)windows\ ?ce" ||
 		    req.http.User-Agent ~ "(?i)winwap" ||
 		    req.http.User-Agent ~ "(?i)eudoraweb" ||


More information about the varnish-commit mailing list