Permalink
Browse files

Documentation for the PyOpenSSL contrib module.

  • Loading branch information...
1 parent a105119 commit f41dccb1d2d54d5a45141bcd8f0e3f7606bedffb @kirkeby committed Mar 20, 2013
Showing with 29 additions and 6 deletions.
  1. +10 −0 docs/contrib.rst
  2. +10 −0 docs/index.rst
  3. +9 −6 urllib3/contrib/pyopenssl.py
View
10 docs/contrib.rst
@@ -0,0 +1,10 @@
+Contrib Modules
+===============
+
+These modules implement various extra features, that may not be ready for
+prime time.
+
+SNI-support for Python 2
+------------------------
+
+.. automodule:: urllib3.contrib.pyopenssl
View
10 docs/index.rst
@@ -9,6 +9,7 @@ urllib3 Documentation
managers
helpers
collections
+ contrib
Highlights
@@ -144,6 +145,15 @@ but can also be used independently.
helpers
+Contrib Modules
+---------------
+
+These modules implement various extra features, that may not be ready for
+prime time.
+
+.. toctree::
+
+ contrib
Contributing
============
View
15 urllib3/contrib/pyopenssl.py
@@ -1,13 +1,14 @@
'''SSL with SNI-support for Python 2.
-This is needs the following packages installed:
+This needs the following packages installed:
- ndg-httpsclient (tested with 0.3.2)
- pyOpenSSL (tested with 0.13)
- pyasn1 (tested with 0.1.6)
+* pyOpenSSL (tested with 0.13)
+* ndg-httpsclient (tested with 0.3.2)
+* pyasn1 (tested with 0.1.6)
-To activate it call :func:`inject_into_urllib3`. This can be done in a
-sitecustomize module.
+To activate it call :func:`urllib3.contrib.pyopenssl.inject_into_urllib3`.
+This can be done in a ``sitecustomize`` module, or at any other time before
+your application begins using ``urllib3``.
'''
from ndg.httpsclient.ssl_peer_verification import (ServerSSLCertVerification,
@@ -21,6 +22,8 @@
from .. import connectionpool
from .. import util
+__all__ = ['inject_into_urllib3', 'extract_from_urllib3']
+
# SNI only *really* works if we can read the subjectAltName of certificates.
HAS_SNI = SUBJ_ALT_NAME_SUPPORT

0 comments on commit f41dccb

Please sign in to comment.