decrypt Method
Decrypts the XML.
Syntax
def decrypt() -> None: ...
Remarks
This method decrypts the specified XML.
To begin first specify a XML document by setting input_file, or input_xml.
The symmetric_key property specifies the key used to decrypt the data. This may be set before calling on_decrypt or inside the on_encrypted_data_info event. The on_encrypted_data_info event fires once for each encrypted element when on_decrypt is called.
If the data was encrypted using an session key, set the Cert* properties to the certificate with private key before calling on_decrypt. The certificate will be used to decrypt the encrypted session key. In this case the symmetric_key property is ignored.
The following properties are applicable when calling this method:
- symmetric_key
- certificate
Input and Output Properties
The class will determine the source and destination of the input and output based on which properties are set.
The order in which the input properties are checked is as follows:
When a valid source is found the search stops. The order in which the output properties are checked is as follows:- output_file
- output_xml: The output data is written to this property if no other destination is specified.