title: SNIMissingWarning and InsecurePlatformWarning when installing with pip
body: <p>Since installing pip I've been getting messages like:</p>
  
  <pre><code>root@nas:~# pip install requests
  Collecting requests
  /usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:318: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#snimissingwarning.
    SNIMissingWarning
  /usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning.
    InsecurePlatformWarning
    Downloading requests-2.18.4-py2.py3-none-any.whl (88kB)
      100% |████████████████████████████████| 92kB 996kB/s 
  Requirement already satisfied: certifi&gt;=2017.4.17 in /usr/local/lib/python2.7/dist-packages (from requests)
  Collecting chardet&lt;3.1.0,&gt;=3.0.2 (from requests)
    Downloading chardet-3.0.4-py2.py3-none-any.whl (133kB)
      100% |████████████████████████████████| 143kB 2.5MB/s 
  Requirement already satisfied: idna&lt;2.7,&gt;=2.5 in /usr/local/lib/python2.7/dist-packages (from requests)
  Requirement already satisfied: urllib3&lt;1.23,&gt;=1.21.1 in /usr/local/lib/python2.7/dist-packages (from requests)
  Installing collected packages: chardet, requests
  Successfully installed chardet-3.0.4 requests-2.18.4
  </code></pre>
  
  <p>I tried to <a href="https://urllib3.readthedocs.io/en/latest/user-guide.html#ssl-py2" rel="nofollow noreferrer">resolve</a> this by running <code>pip install pyopenssl</code>, followed by <code>pip install urllib3[secure]</code>. Afterwards I opened up the Python interpreter and ran:</p>
  
  <pre><code>&gt;&gt;&gt; import urllib3.contrib.pyopenssl
  &gt;&gt;&gt; urllib3.contrib.pyopenssl.inject_into_urllib3() 
  </code></pre>
  
  <p>No dice. Still getting SNIMissingWarning and InsecurePlatformWarning messages.</p>