diff options
author | Laurens Van Houtven <_@lvh.cc> | 2014-03-29 11:30:06 +0100 |
---|---|---|
committer | Laurens Van Houtven <_@lvh.cc> | 2014-03-29 11:30:06 +0100 |
commit | e8b2d3013a3d1536f6bf9ae5ca7ee0752d710311 (patch) | |
tree | 1ba50249feda18e16954ae9fe181112cef80b96f /doc | |
parent | 63e99fe6f9ee799ae9914a3704b1fe540cc8a4b7 (diff) | |
parent | 4064ea18c2a68bb5d6e82f40be7ecddc0752d6f9 (diff) | |
download | pyopenssl-e8b2d3013a3d1536f6bf9ae5ca7ee0752d710311.tar.gz |
Merge branch 'ecdhe' of git://github.com/amluto/pyopenssl into ecdhe
Diffstat (limited to 'doc')
-rw-r--r-- | doc/api/ssl.rst | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/doc/api/ssl.rst b/doc/api/ssl.rst index da7cfb7..b581450 100644 --- a/doc/api/ssl.rst +++ b/doc/api/ssl.rst @@ -110,6 +110,17 @@ Context, Connection. .. versionadded:: 0.14 +.. py:data:: ELLIPTIC_CURVE_DESCRIPTIONS + + A dictionary mapping short names of elliptic curves to textual + descriptions. This dictionary contains exactly the set of curves + supported by the OpenSSL build in use. + + The keys are the curve names that can be passed into + Constants used with :py:meth:`Context.set_tmp_ecdh_curve` to + specify which elliptical curve should be used for ECDHE key exchange. + + .. py:data:: OPENSSL_VERSION_NUMBER An integer giving the version number of the OpenSSL library used to build this @@ -316,6 +327,19 @@ Context objects have the following methods: Load parameters for Ephemeral Diffie-Hellman from *dhfile*. +.. py:method:: Context.set_tmp_ecdh_curve(curve_name) + + Select a curve to use for ECDHE key exchange. + + The valid values of *curve_name* are the keys in + :py:data:`ELLIPTIC_CURVE_DESCRIPTIONS`. + + Raises a ``ValueError`` if the linked OpenSSL was not compiled with + elliptical curve support, or the specified curve is not available. + + :param curve_name: The 'short name' of a curve, e.g. 'prime256v1' + :type curve_name: str + :return: None .. py:method:: Context.set_app_data(data) |