Any suggestions on how to encrypt text, persist it to database and retrieve it l

Any suggestions on how to encrypt text, persist it to database and retrieve it later?
I'm currently looking on some conversion expression like dec2hex/hex2dec, oct2hex/hex2oct but to no success since decryption is not possible and giving me infinite symbol, i think it can't convert back the value because it's too big.
Right now, I'm using a!encryptedtextField and I can save the encryptedtext value to db but having issues retrieving it from the database. The query rule is giving this error: "String has invalid data (Could not cast from Encrypted Text to Text. Details: CastInvalid)" any suggestions how to deal with this?

OriginalPostID-171359

OriginalPostID-171359

  Discussion posts and replies are publicly visible

Parents
  • hi eduardo, was able to encrypt, but im having issues in decrypting :
    Expression evaluation error at function 'keydecrypt': Error evaluating function 'keydecrypt' : An error occurred: java.security.InvalidKeyException: requires PBE parameters. note that I'm using the same key and cipher transformation used in keyencrypt as indicated in the expression expression.
Reply
  • hi eduardo, was able to encrypt, but im having issues in decrypting :
    Expression evaluation error at function 'keydecrypt': Error evaluating function 'keydecrypt' : An error occurred: java.security.InvalidKeyException: requires PBE parameters. note that I'm using the same key and cipher transformation used in keyencrypt as indicated in the expression expression.
Children
No Data