Back to module index

Go to module by name

cryptography.hazmat.primitives.serialization

cryptography.hazmat.primitives

cryptography.hazmat

cryptography

cryptography.hazmat.primitives.serialization.pkcs7

This module has no docstring.

Classes

PKCS7Options

An enumeration.
Binary = <PKCS7Options.Binary: "Don't translate input data into canonical MIME format">
DetachedSignature = <PKCS7Options.DetachedSignature: "Don't embed data in the PKCS7 structure">
NoAttributes = <PKCS7Options.NoAttributes: "Don't embed authenticatedAttributes">
NoCapabilities = <PKCS7Options.NoCapabilities: "Don't embed SMIME capabilities">
NoCerts = <PKCS7Options.NoCerts: "Don't embed signer certificate">
Text = <PKCS7Options.Text: 'Add text/plain MIME type'>

PKCS7SignatureBuilder

add_certificate(self, certificate: cryptography.x509.base.Certificate) -> 'PKCS7SignatureBuilder'
add_signer(self, certificate: cryptography.x509.base.Certificate, private_key: Union[cryptography.hazmat.primitives.asymmetric.rsa.RSAPrivateKey, cryptography.hazmat.primitives.asymmetric.ec.EllipticCurvePrivateKey], hash_algorithm: Union[cryptography.hazmat.primitives.hashes.SHA1, cryptography.hazmat.primitives.hashes.SHA224, cryptography.hazmat.primitives.hashes.SHA256, cryptography.hazmat.primitives.hashes.SHA384, cryptography.hazmat.primitives.hashes.SHA512]) -> 'PKCS7SignatureBuilder'
set_data(self, data: bytes) -> 'PKCS7SignatureBuilder'
sign(self, encoding: cryptography.hazmat.primitives._serialization.Encoding, options: Iterable[cryptography.hazmat.primitives.serialization.pkcs7.PKCS7Options], backend: Any = None) -> bytes

Functions

load_der_pkcs7_certificates

load_der_pkcs7_certificates(data: bytes) -> List[cryptography.x509.base.Certificate]

load_pem_pkcs7_certificates

load_pem_pkcs7_certificates(data: bytes) -> List[cryptography.x509.base.Certificate]

serialize_certificates

serialize_certificates(certs: List[cryptography.x509.base.Certificate], encoding: cryptography.hazmat.primitives._serialization.Encoding) -> bytes

Modules

ec

hashes

rsa

serialization

typing

utils

x509