diff options
| author | Alexandre Flament <alex@al-f.net> | 2015-04-26 19:12:17 +0200 |
|---|---|---|
| committer | Alexandre Flament <alex@al-f.net> | 2015-04-26 19:12:17 +0200 |
| commit | 8806002886eeb998df54f3b44d8ad43513f58880 (patch) | |
| tree | fa8b8190d02a574a8a4aa75e1975bca134e55731 /searx | |
| parent | 99efd790c8e24a9e7d1ab1220e1da96cdd0a8003 (diff) | |
| parent | 187617498a0dea17e51950f1ad5e96bb4826367d (diff) | |
Merge remote-tracking branch 'origin/ssl' into https
Diffstat (limited to 'searx')
| -rw-r--r-- | searx/webapp.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/searx/webapp.py b/searx/webapp.py index 13c965e0d..38780220e 100644 --- a/searx/webapp.py +++ b/searx/webapp.py @@ -61,6 +61,16 @@ except: from sys import exit exit(1) +# check if the pyopenssl, ndg-httpsclient, pyasn1 packages are installed. +# They are needed for SSL connection without trouble, see #298 +try: + import OpenSSL.SSL # NOQA + import ndg.httpsclient # NOQA + import pyasn1 # NOQA +except ImportError: + logger.critical("The pyopenssl, ndg-httpsclient, pyasn1 packages have to be installed.\n" + "Some HTTPS connections will failed") + logger = logger.getChild('webapp') |