]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Use fake User-Agent in URL redirector plugin 1454/head
authorAndrew Lewis <nerf@judo.za.org>
Thu, 23 Feb 2017 16:54:15 +0000 (18:54 +0200)
committerAndrew Lewis <nerf@judo.za.org>
Thu, 23 Feb 2017 16:54:15 +0000 (18:54 +0200)
src/plugins/lua/url_redirector.lua

index cf90b8de7b5f3480ad9b75911df3ea01ab6a0d74..208bde614f20c7c2cbe33974259d6186070affd6 100644 (file)
@@ -89,6 +89,9 @@ local function resolve_cached(task, orig_url, url, key, param, ntries)
     end
 
     rspamd_http.request{
+      headers = {
+        ['User-Agent'] = 'Mozilla/5.0 (Maemo; Linux armv7l; rv:10.0.1) Gecko/20100101 Firefox/10.0.1 Fennec/10.0.1',
+      },
       url = url,
       task = task,
       method = 'head',