From db9d97f94df125dfc684ae069ee1a2a54ac2d426 Mon Sep 17 00:00:00 2001 From: Paul Kehrer Date: Sun, 1 Mar 2015 21:04:31 -0600 Subject: s/Format/PrivateFormat --- docs/hazmat/primitives/asymmetric/rsa.rst | 13 +++++++------ docs/hazmat/primitives/asymmetric/serialization.rst | 4 ++-- 2 files changed, 9 insertions(+), 8 deletions(-) (limited to 'docs/hazmat/primitives') diff --git a/docs/hazmat/primitives/asymmetric/rsa.rst b/docs/hazmat/primitives/asymmetric/rsa.rst index 924696db..a8d7bfc0 100644 --- a/docs/hazmat/primitives/asymmetric/rsa.rst +++ b/docs/hazmat/primitives/asymmetric/rsa.rst @@ -94,7 +94,7 @@ to serialize the key. >>> from cryptography.hazmat.primitives import serialization >>> pem = private_key.private_bytes( ... encoding=serialization.Encoding.PEM, - ... format=serialization.Format.PKCS8, + ... format=serialization.PrivateFormat.PKCS8, ... encryption_algorithm=serialization.BestAvailableEncryption(b'mypassword') ... ) >>> pem.splitlines()[0] @@ -107,7 +107,7 @@ It is also possible to serialize without encryption using >>> pem = private_key.private_bytes( ... encoding=serialization.Encoding.PEM, - ... format=serialization.Format.TraditionalOpenSSL, + ... format=serialization.PrivateFormat.TraditionalOpenSSL, ... encryption_algorithm=serialization.NoEncryption() ... ) >>> pem.splitlines()[0] @@ -540,10 +540,10 @@ Key interfaces :attr:`~cryptography.hazmat.primitives.serialization.Encoding.PEM` or :attr:`~cryptography.hazmat.primitives.serialization.Encoding.DER`), format ( - :attr:`~cryptography.hazmat.primitives.serialization.Format.TraditionalOpenSSL` + :attr:`~cryptography.hazmat.primitives.serialization.PrivateFormat.TraditionalOpenSSL` or - :attr:`~cryptography.hazmat.primitives.serialization.Format.PKCS8`) and - encryption algorithm (such as + :attr:`~cryptography.hazmat.primitives.serialization.PrivateFormat.PKCS8`) + and encryption algorithm (such as :class:`~cryptography.hazmat.primitives.serialization.BestAvailableEncryption` or :class:`~cryptography.hazmat.primitives.serialization.NoEncryption`) are chosen to define the exact serialization. @@ -552,7 +552,8 @@ Key interfaces :class:`~cryptography.hazmat.primitives.serialization.Encoding` enum. :param format: A value from the - :class:`~cryptography.hazmat.primitives.serialization.Format` enum. + :class:`~cryptography.hazmat.primitives.serialization.PrivateFormat` + enum. :param encryption_algorithm: An instance of an object conforming to the :class:`~cryptography.hazmat.primitives.serialization.KeySerializationEncryption` diff --git a/docs/hazmat/primitives/asymmetric/serialization.rst b/docs/hazmat/primitives/asymmetric/serialization.rst index 4940ebd4..e11b02ab 100644 --- a/docs/hazmat/primitives/asymmetric/serialization.rst +++ b/docs/hazmat/primitives/asymmetric/serialization.rst @@ -286,11 +286,11 @@ DSA keys look almost identical but begin with ``ssh-dss`` rather than Serialization Formats ~~~~~~~~~~~~~~~~~~~~~ -.. class:: Format +.. class:: PrivateFormat .. versionadded:: 0.8 - An enumeration for key formats. Used with + An enumeration for private key formats. Used with :class:`~cryptography.hazmat.primitives.asymmetric.rsa.RSAPrivateKeyWithSerialization.private_bytes`. .. attribute:: TraditionalOpenSSL -- cgit v1.2.3