SHA-256 an email address Link in Velocity

Highlighted
Level 2

Re: SHA-256 an email address Link in Velocity

Thanks Jay!

Will try this, hopefully it will do the job for me.

Quick one, the endpoint.php in your screen grab is that the file with the php code you provided me?

Thanks again!

Highlighted
Level 10 - Community Moderator

Re: SHA-256 an email address Link in Velocity

Quick one, the endpoint.php in your screen grab is that the file with the php code you provided me?

Yep, the idea is you have uploaded that file to a separate server.

Of course you should also add authentication, unless you're going to rely on an de facto "unguessable" URL (such as a GUID).

Highlighted
Level 2

Re: SHA-256 an email address Link in Velocity

Sorry, will the link still be: https://mydomain.com/dtm_email_hash={{lead.Email Address}},

Plus why do we need the Data Value Changes in smart flow? Not sure how I would test it as this makes it triggered and cannot Run Once

Highlighted
Level 10 - Community Moderator

Re: SHA-256 an email address Link in Velocity

will the link still be: https://mydomain.com/dtm_email_hash={{lead.Email Address}},

It would be {{lead.Hashed Email Address}} as of course you're writing the hash to a different field.

Plus why do we need the Data Value Changes in smart flow?

It's in the trigger (Smart List), not the flow (you probably meant that).

You need to update the hash value when (a) the lead is created and (b) the email address changes. You also need a third trigger, (c) Campaign is requested, for backfill and for testing.

It's still causing me pain to imagine you maintaining a separate server for this job. I might just have to write the SHA-256 code for you so I stop groaning... when are you trying to deliver this by?

Highlighted
Level 2

Re: SHA-256 an email address Link in Velocity

The leads are existing Leads we send these emails to, so email address will never change and no new is being created.

Sanford that would be great help if you could create the SHA-256 code  I am sure it will come in handy for a lot of of others using Marketo. Trying to have this up and running within 5 to 7 days, is that duable?

Thanks for all your help. 

Highlighted
Level 10 - Community Moderator

Re: SHA-256 an email address Link in Velocity

The leads are existing Leads we send these emails to, so email address will never change and no new is being created.

I find that very hard to believe. What kind of database has email addresses that are immutable?

Highlighted
Level 2

Re: SHA-256 an email address Link in Velocity

Sorry, we are targeting existing LEADS within Marketo and was told these email addresses will not change for now.

Highlighted
Level 10 - Community Moderator

Re: SHA-256 an email address Link in Velocity

I honestly doubt it'll be used by anybody else. But that's not why I do what I do.

If next week is as slow (US holiday) as projected, I should be able to get it done by next Saturday.

One last check, though, before I get into coding: if this is a one-time load from a single source, can we do the hashes offline? It's easy to gen using a Google Sheet, for example.

Highlighted
Level 2

Re: SHA-256 an email address Link in Velocity

Hi Sanford, it will not be one time load - all customers in our database will be affected at some point.

Basically we are working with Conversant(part of Commission Junction), they have provided those parameters which will allow them to track our customer behaviour but we need the email address encrypted.

We add the following to our email head:

Email Tag Code:

<img src="http://login.dotomi.com/ucm/UCMController?dtm_com=2&dtm_cid=61538&dtm_cmagic=a0ad3c&dtm_fid=<Form ID..." width="1" height="1" border="0"> <!-- End Conversant Tag -->

and links will have the following parameter:

dtm_email_hash parameter (dtm_email_hash={{lead.Email Address}}) should be encrypted using SHA256 hashing as that is personal information...which will look something as follows: https://www.domain.com?dtm_email_hash={{hashed_lead.Email}}

If you can help with the coding, would be gratefully appreciated  - as you said using base64 now.

Thanks for all your help! 

Highlighted
Level 10 - Community Moderator

Re: SHA-256 an email address Link in Velocity

Why specifically are they asking for SHA256, as opposed to any nonreversable code that you can link back to the Marketo lead? Are you preloading their database with all the emails as well, so their reports will show plaintext email addresses? Or are they just going to show hashes back to you?