Browse Source

engines: use https when possible

Alexandre Flament 10 years ago
parent
commit
99efd790c8

+ 1
- 1
searx/engines/bing_images.py View File

26
 # search-url
26
 # search-url
27
 base_url = 'https://www.bing.com/'
27
 base_url = 'https://www.bing.com/'
28
 search_string = 'images/search?{query}&count=10&first={offset}'
28
 search_string = 'images/search?{query}&count=10&first={offset}'
29
-thumb_url = "http://ts1.mm.bing.net/th?id={ihk}"
29
+thumb_url = "http://ts1.mm.bing.net/th?id={ihk}" # no https, bad certificate
30
 
30
 
31
 # safesearch definitions
31
 # safesearch definitions
32
 safesearch_types = {2: 'STRICT',
32
 safesearch_types = {2: 'STRICT',

+ 2
- 2
searx/engines/currency_convert.py View File

2
 import re
2
 import re
3
 
3
 
4
 categories = []
4
 categories = []
5
-url = 'http://finance.yahoo.com/d/quotes.csv?e=.csv&f=sl1d1t1&s={query}=X'
5
+url = 'https://download.finance.yahoo.com/d/quotes.csv?e=.csv&f=sl1d1t1&s={query}=X'
6
 weight = 100
6
 weight = 100
7
 
7
 
8
 parser_re = re.compile(r'^\W*(\d+(?:\.\d+)?)\W*([a-z]{3})\W*(?:in)?\W*([a-z]{3})\W*$', re.I)  # noqa
8
 parser_re = re.compile(r'^\W*(\d+(?:\.\d+)?)\W*([a-z]{3})\W*(?:in)?\W*([a-z]{3})\W*$', re.I)  # noqa
44
     )
44
     )
45
 
45
 
46
     now_date = datetime.now().strftime('%Y%m%d')
46
     now_date = datetime.now().strftime('%Y%m%d')
47
-    url = 'http://finance.yahoo.com/currency/converter-results/{0}/{1}-{2}-to-{3}.html'  # noqa
47
+    url = 'https://finance.yahoo.com/currency/converter-results/{0}/{1}-{2}-to-{3}.html'  # noqa
48
     url = url.format(
48
     url = url.format(
49
         now_date,
49
         now_date,
50
         resp.search_params['ammount'],
50
         resp.search_params['ammount'],

+ 2
- 2
searx/engines/deezer.py View File

16
 paging = True
16
 paging = True
17
 
17
 
18
 # search-url
18
 # search-url
19
-url = 'http://api.deezer.com/'
19
+url = 'https://api.deezer.com/'
20
 search_url = url + 'search?{query}&index={offset}'
20
 search_url = url + 'search?{query}&index={offset}'
21
 
21
 
22
 embedded_url = '<iframe scrolling="no" frameborder="0" allowTransparency="true" ' +\
22
 embedded_url = '<iframe scrolling="no" frameborder="0" allowTransparency="true" ' +\
23
-    'data-src="http://www.deezer.com/plugins/player?type=tracks&id={audioid}" ' +\
23
+    'data-src="https://www.deezer.com/plugins/player?type=tracks&id={audioid}" ' +\
24
     'width="540" height="80"></iframe>'
24
     'width="540" height="80"></iframe>'
25
 
25
 
26
 
26
 

+ 1
- 1
searx/engines/mixcloud.py View File

17
 paging = True
17
 paging = True
18
 
18
 
19
 # search-url
19
 # search-url
20
-url = 'http://api.mixcloud.com/'
20
+url = 'https://api.mixcloud.com/'
21
 search_url = url + 'search/?{query}&type=cloudcast&limit=10&offset={offset}'
21
 search_url = url + 'search/?{query}&type=cloudcast&limit=10&offset={offset}'
22
 
22
 
23
 embedded_url = '<iframe scrolling="no" frameborder="0" allowTransparency="true" ' +\
23
 embedded_url = '<iframe scrolling="no" frameborder="0" allowTransparency="true" ' +\

+ 1
- 1
searx/engines/stackoverflow.py View File

19
 paging = True
19
 paging = True
20
 
20
 
21
 # search-url
21
 # search-url
22
-url = 'http://stackoverflow.com/'
22
+url = 'https://stackoverflow.com/'
23
 search_url = url+'search?{query}&page={pageno}'
23
 search_url = url+'search?{query}&page={pageno}'
24
 
24
 
25
 # specific xpath variables
25
 # specific xpath variables

+ 1
- 1
searx/engines/vimeo.py View File

23
 paging = True
23
 paging = True
24
 
24
 
25
 # search-url
25
 # search-url
26
-base_url = 'http://vimeo.com'
26
+base_url = 'https://vimeo.com'
27
 search_url = base_url + '/search/page:{pageno}?{query}'
27
 search_url = base_url + '/search/page:{pageno}?{query}'
28
 
28
 
29
 # specific xpath variables
29
 # specific xpath variables