Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

How to decrypt one field in a JSON and return original JSON with that field decrypted

Highlighted

How to decrypt one field in a JSON and return original JSON with that field decrypted

New Contributor

Hi!

I'm a Nifi Newbie and I'd like some guidance to solve this problem.

I have a use case where I receive a JSON with one field encrypted. What I'd like to do is to process this JSON with NiFi and return the original JSON but with the field decrypted. I'd like to use the processor EncryptContent if that's possible.
I know the name of the encrypted field in advance.

For example if a Receive the following json

{"id":"1","name":"paul","password":"encryptedPassword"}

I'd like to return (or have an some point of the flow)

{"id":"1","name":"paul","password":"decryptedPassword"}

What would be the best strategy to achieve this without developing a custom processor?

Thanks a lot for any advice
JP