Support for traditional OpenSSL and PKCS8 RSA private key serialization

This temporarily uses the backend to do it until the alternate approach is ready. DSA/ECDSA and public key support will follow if this is deemed 
wut. Can it really not do PEM encryption for PKCS8 keys? (I can see why you
wouldn't want to, but still...).

On Sat Nov 29 2014 at 3:49:11 PM Paul Kehrer <notifications@github.com>
wrote:

> In docs/hazmat/primitives/asymmetric/serialization.rst:
>
> > @@ -114,6 +114,53 @@ all begin with ``-----BEGIN {format}-----`` and end with ``-----END
> >          is not supported by the backend.
> >
> >
> > +Serializers
> > +~~~~~~~~~~~
> > +
> > +.. class:: PKCS8(enctype, password)
> > +
> > +    .. versionadded:: 0.7
> > +
> > +    A serializer for the PKCS #8 format.
> > +
> > +    :param enctype: :class:`~cryptography.hazmat.primitives.serialization.EncryptionTypes`
> > +
> > +    :param bytes password: The password for encryption.
> > +
> > +.. class:: TraditionalOpenSSL(enctype, password)
>
> So only support encryption on PKCS8 for the moment and add a
> PEMEncryption() later when we switch to the alternate approach? I believe
> OpenSSL can only do PEM encryption on these traditional keys.
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/pyca/cryptography/pull/1503/files#r21056471>.
>