Encrypt URL parameters | Community
Skip to main content
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by SatheeskannaK

Hi @ljane ,

 

You will have to follow two things in order to get query parameters encrypted for each profile, in such a way that it generates personalized preference center url when a user clicks. I see that you want to get email & country data for each of the profile to be encrypted.

 

1. First thing you will have to encrypt the email & country using the "encryption_aescbcEncrypt" function available by adding them as additional data on workflow query activity. Refer this page for list of functions: List of functions.

For example: encryption_aescbcEncrypt(@email, "\x4839dmjslekws482dks", "\xdfjskl30204dxms492")

 

2. Then create content block with the expression alias you see on the additional data.

    For email encryption could be something: <%= context.targetData.expr1 %> 

   Similarly you will have one for country encryption which is <%= context.targetData.expr2 %>

 

Final url will be like this: https://www.google.com?params=<%= context.targetData.expr1 %>&<%= context.targetData.expr2 %>  and whenever user clicks the preference center url it will have their email & country encrypted as query parameter.

 

Hope this helps.

 

Thanks!

SK

 

 

2 replies

April 28, 2020

Me too, I want the idea

SatheeskannaK
Community Advisor
SatheeskannaKCommunity AdvisorAccepted solution
Community Advisor
May 7, 2020

Hi @ljane ,

 

You will have to follow two things in order to get query parameters encrypted for each profile, in such a way that it generates personalized preference center url when a user clicks. I see that you want to get email & country data for each of the profile to be encrypted.

 

1. First thing you will have to encrypt the email & country using the "encryption_aescbcEncrypt" function available by adding them as additional data on workflow query activity. Refer this page for list of functions: List of functions.

For example: encryption_aescbcEncrypt(@email, "\x4839dmjslekws482dks", "\xdfjskl30204dxms492")

 

2. Then create content block with the expression alias you see on the additional data.

    For email encryption could be something: <%= context.targetData.expr1 %> 

   Similarly you will have one for country encryption which is <%= context.targetData.expr2 %>

 

Final url will be like this: https://www.google.com?params=<%= context.targetData.expr1 %>&<%= context.targetData.expr2 %>  and whenever user clicks the preference center url it will have their email & country encrypted as query parameter.

 

Hope this helps.

 

Thanks!

SK

 

 

Thanks, Sathees