- class pyhanko.sign.ades.api.GenericCommitment(value)
- PROOF_OF_ORIGIN = 1
- PROOF_OF_RECEIPT = 2
- PROOF_OF_DELIVERY = 3
- PROOF_OF_SENDER = 4
- PROOF_OF_APPROVAL = 5
- PROOF_OF_CREATION = 6
- class pyhanko.sign.ades.api.CAdESSignedAttrSpec(commitment_type: Optional[CommitmentTypeIndication] = None, timestamp_content: bool = False, signature_policy_identifier: Optional[SignaturePolicyIdentifier] = None, signer_attributes: Optional[SignerAttrSpec] = None)
Class that controls signed CAdES attributes on a PDF signature.
- commitment_type: Optional[CommitmentTypeIndication] = None
Signature commitment type. Can be one of the standard values, or a custom one.
- timestamp_content: bool = False
Indicate whether the signature should include a signed timestamp.
This should be contrasted with unsigned timestamps: a signed timestamp proves that the signature was created after some point in time, while an unsigned timestamp computed over the signed content proves that the signature existed before said point in time.
- signature_policy_identifier: Optional[SignaturePolicyIdentifier] = None
Signature policy identifier to embed into the signature.
Right now, pyHanko does not “understand” signature policies, so the signature policy identifier will be taken at face value and embedded without paying any heed to the actual rules of the signature policy. It is the API user’s responsibility to make sure that all relevant provisions of the signature policy are adhered to.
- signer_attributes: Optional[SignerAttrSpec] = None
Settings for signer’s attributes, to be included in a
signer-attributes-v2attribute on the signature.
- class pyhanko.sign.ades.api.SignerAttrSpec(claimed_attrs: Iterable[AttCertAttribute], certified_attrs: Iterable[AttributeCertificateV2])
Class that controls the
signer-attributes-v2signed CAdES attribute.
These represent attributes of the signing entity, not the signature or signed content.
Out of the box, only basic claimed attributes and certified attributes through V2 X.509 attribute certificates are supported.
- claimed_attrs: Iterable[AttCertAttribute]
Attributes claimed by the signer without further justification.
- certified_attrs: Iterable[AttributeCertificateV2]
Attribute certificates containing signer attributes.