07-28-2021 06:37 AM
Hello Experts,
i’m trying to encrypt one of the field of csv file using Encrypt Field snap.
i have selected transform type as auto and selected account of Passphrase-based Key type.
As a result of encrypt field snap ,field got encrypted.
in next snap i’m mapping encrypted field(column.ciphertext) and other columns and writing data to file.
In second pipeline reading encrypted file and trying to decrypt using same Passphrase-based Key based account.
but encrypted field is not getting decrypted .
Attaching pipeline for reference .
decFIle_2021_07_28.slp (10.8 KB)
Encrypt file_2021_07_28.slp (10.8 KB)
Regards,
Ajay
08-26-2021 01:27 AM
got it, it was the encapsulate output option!
08-26-2021 08:16 AM
I am using the encrypt decrypt pipeline above which works great, but when I try to pass a value to the decrypt via _data the decrypt fails with
The mapper looks like
The data in the _data field should be good as if I feed this to the decrypt snap via the JSON generator it works fine.
Failure: Invalid base64 value for ciphertext, Reason: Expecting a base64-encoded string, found STRING,
08-27-2021 04:31 AM
@peter Data type of any pipeline parameter is consider as String, even you keep encoding value it consider as String. So if you want encrypt decrypt data, encrypt it in mapper. It might resolve issue.
08-27-2021 04:51 AM
OK, how do I do that?
Peter
08-27-2021 05:00 AM
I have tried taking the parameter and encoding it as base64 and decoding it before passing to the decrypt and it still does not work.
Peter