summaryrefslogtreecommitdiff
path: root/searx
diff options
context:
space:
mode:
Diffstat (limited to 'searx')
-rw-r--r--searx/engines/digg.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/searx/engines/digg.py b/searx/engines/digg.py
index 606747a4d..84f1ea599 100644
--- a/searx/engines/digg.py
+++ b/searx/engines/digg.py
@@ -10,6 +10,8 @@
@parse url, title, content, publishedDate, thumbnail
"""
+import random
+import string
from dateutil import parser
from json import loads
from lxml import html
@@ -36,6 +38,10 @@ def request(query, params):
offset = (params['pageno'] - 1) * 10
params['url'] = search_url.format(position=offset,
query=quote_plus(query))
+ params['cookies']['frontend.auid'] = ''.join(random.choice(
+ string.ascii_uppercase +
+ string.ascii_lowercase +
+ string.digits + "+_") for _ in range(22))
return params