In this article
Pretty Good Privacy (PGP) is a decryption program that provides cryptographic privacy and authentication for data communication. PGP is popularly used to digitally sign, encrypt or decrypt email messages or files being transferred over the Internet.
This Snap decrypts PGP-encrypted data provided as an input stream using the private key and passphrase. This Snap should be attached to the input binary data stream to be decrypted in the pipeline.
The default security in the JRE limits the key length for encryption keys. For stronger encryption keys, you would need to manually install the Java Cryptographic Extension JARs on your JCC nodes. |
Snap Type
PGP Decrypt Snap is a TRANSFORM-type Snap that transforms binary documents.
None.
The Snap might fail while processing very large signed files.
Works in Ultra Pipelines.
Input | Document Binary Binary or Document |
| Any Snap that produces binary data in the output view such as File Reader or Compress. |
Output | Document Binary Binary or Document |
| Any Snap that accepts binary data in the input view such as File Writer or Decompress. |
Error | Error handling is a generic way to handle errors without losing data or failing the Snap execution. You can handle the errors that the Snap might encounter while running the Pipeline by choosing one of the following options from the When errors occur list under the Views tab. The available options are:
Learn more about Error handling in Pipelines. |
Field Name | Field Type | Description | |
---|---|---|---|
Label* Default Value: PGP Decrypt | String | Specify the name for the Snap. You can use a more specific label, especially if you have more than one of the same Snap in your Pipeline. | |
Signed File Default Value: Deselected | Checkbox | Specify if the selected file is a signed file. | |
Skip Verification Default Value: Deselected | Checkbox | Select this checkbox to skip the verification if there is an issue with the signature in the encrypted file. | |
Snap Execution
| Dropdown list | Select one of the three modes in which the Snap executes. Available options are:
|
The following example includes Sample input data which is successfully encrypted using the PGP Encrypt Snap and then decrypted using the PGP Decrypt Snap.
We will start with a JSON Generator Snap which has a sample message "Hello World", which is formatted and written as JSON binary data for the PGP Encrypt Snap to ingest.
We can see that the Message is Encrypted as the output of the PGP Encrypt Snap.
We will write the file out as File_encrypt.pgp to the SnapLogic DB. Then we proceed to decrypt the encrypted file and write it to the SnapLogic DB as File_decrypt.txt.
We can see that the output from the Decrypt Snap matches our original raw unencrypted data:
We have successfully decrypted the message.
Important Steps to Successfully Reuse Pipelines
|