[Python-modules-team] Bug#761620: annoying warning
Daniele Tricoli
eriol at mornie.org
Thu Sep 18 17:30:54 UTC 2014
Hello Erwan,
On Monday 15 September 2014 07:56:52 Erwan David wrote:
> Since urllib3 does not do SNI, I cannot activate verification (the
> wrong certificate is retrieved)
urllib3 supports SNI, see here to configure it correctly:
http://urllib3.readthedocs.org/en/latest/contrib.html#module-urllib3.contrib.pyopenssl
All the required dependencies are in Debian and for Python 2 I
put them in Recommends.
Are python-ndg-httpsclient, python-openssl and python-pyasn1 installed?
> SInce latest versioneach time it is launched I get followibng message:
>
> /usr/lib/python2.7/dist-packages/urllib3/connectionpool.py:732:
> InsecureRequestWarning: Unverified HTTPS request is being made. Adding
> certificate verification is strongly advised. See:
> https://urllib3.readthedocs.org/en/latest/security.html (This warning will
> only appear once by default.) InsecureRequestWarning)
This is a new feature of urllib3 1.9.
> My only solutions is to drop all errors from script (which is run
> hourly from crontab), thus making me unaware of any other problem.
>
> Id I specify to *not* verify it is because I cannot use it duie to the
> limitations of the lib.
Can you try, at first, to enable SNI? As I said, urllib3 can do SNI.
> So, how can I disable this warning ?
You can disable urllib warnings as specified here:
https://urllib3.readthedocs.org/en/latest/security.html#insecurerequestwarning
But remember that making unverified HTTPS requests is not a good pratice and
you can use SNI with urllib3 so I suggest you to enamble it.
HTH,
--
Daniele Tricoli 'Eriol'
http://mornie.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.alioth.debian.org/pipermail/python-modules-team/attachments/20140918/e27eb91e/attachment.sig>
More information about the Python-modules-team
mailing list