Browse Source

Add HTTP Referer header to DuckDuckGo requests

closes #2080
Rudis Muiznieks 2 years ago
parent
commit
128b8c7f0a
1 changed files with 1 additions and 0 deletions
  1. 1 0
      searx/engines/duckduckgo.py

+ 1 - 0
searx/engines/duckduckgo.py

@@ -73,6 +73,7 @@ def request(query, params):
     # link again and again ..
 
     params['headers']['Content-Type'] = 'application/x-www-form-urlencoded'
+    params['headers']['Referer'] = 'https://lite.duckduckgo.com/'
 
     # initial page does not have an offset
     if params['pageno'] == 2: