Expand my Community achievements bar.

SOLVED

aes cbc encryption not working?

Avatar

Level 2

Hello.

We currently need to encrypt/decrypt some data in ACS for privacy purpose between system.

We will need to send an email, with a link in it.

This link got the email encrypted in aes format with cbc.

ACS currently gor some functions that can encrypt data ( encryption_aescbcEncrypt )

We did use this function with all the required parameter, but the output cannot be decypher by anyone ( all tools used cannot get back the original value).

if i use this example :

     encryption_aescbcEncrypt('TEST',"\x656e6372797074546f6f6c7331323334","\x6f0561702db407a325634764f8030519")here's the result i got in ACS : 279432169de85d110dba9989df547b5f

if i use the decrypt tools from those websites ( AES Encryption – Easily encrypt or decrypt strings or files , CyberChef ) , this decrypt to something that is wrong :

K.½6¯dÒ.(.Ħò

/

If i use those website to encrypt, both answer are : 3e909d57ce667056636865781948c901

(HEX format for all).

ANyone ever step on that problem?

(on a side note the decryptfunction: encryption_aescbcDecrypt  seems to not work eitheir (blank result everytime).

thank you for the help

1 Accepted Solution

Avatar

Correct answer by
Employee Advisor

You should try

encryption_aescbcEncrypt('TEST','\\x656e6372797074546f6f6c7331323334','\\x6f0561702db407a325634764f8030519')

Then it should give you the same value as you stated from the websites

View solution in original post

4 Replies

Avatar

Correct answer by
Employee Advisor

You should try

encryption_aescbcEncrypt('TEST','\\x656e6372797074546f6f6c7331323334','\\x6f0561702db407a325634764f8030519')

Then it should give you the same value as you stated from the websites

Avatar

Level 4

How about decryption of the encrypted value?

Avatar

Level 2

I also had the same problem while encryption and decryption in Adobe campaign standard and followed the solution that is provided in this conversation and it worked .

To encrypt :

encryption_aescbcEncrypt('TEST','\\x656e6372797074546f6f6c7331323334','\\x6f0561702db407a325634764f8030519')

To De-crypt :

encryption_aescbcDecrypt('encryptedvalue','\\x656e6372797074546f6f6c7331323334','\\x6f0561702db407a325634764f8030519')

In the document it is written as to add x in prior to the encrypted value but I checked and found that there is no need to do this .

 

Thanks

Debanjana