Webhook payload signature check

Good morning,

we’re having some problems verifying the signature when a property contains quotes inside the value.
Here is an example:

{
...
 "occurredAt": 1697190591669,
 "subscriptionType": "company.propertyChange",
 "attemptNumber": 9,
 "propertyName": "city",
 "propertyValue": "Asd \"asd asd\"",
...
 "changeSource": "HUBSPOT_INTERNAL"
}

The signature does not match, we tried these cases:

leaving as it is:

base64: ez6AzsWqQPTN9M+Uj5ja0cOg/a0IK0JB8CQfAnOJMY0=
signature: oKn+yyNkDKVjTHx/NbimDH2J7nc6y2YH+vfS0lQCJp4=
substituting \" in "

base64: dx+LIdEVCJ0AJp24v1HeNYYpgDGSq1vg+zRECoDuDIs=
signature: oKn+yyNkDKVjTHx/NbimDH2J7nc6y2YH+vfS0lQCJp4=
Removing \"

base64: kqEsX4cgp1fs6a8q+Snre6IcE3dMlMTcGiKeUhX0y2I=
signature: oKn+yyNkDKVjTHx/NbimDH2J7nc6y2YH+vfS0lQCJp4=

This problem only occurs when the value contains internal quotes, and in all the other webhook calls the verify process works correctly.
Do you have any hints on how to manage these specific cases?
Thank you in advance

Hi @mmaddiona,
Thank you for asking the Community!
Just to understand, are you using webhooks in workflows to verifiy that requests come from HubSpot, right?
I’d like to ask some of our Community Members who were using similar webhooks: Hi @MichaelJC91, @SathyaG and @reneconnhealth are you experiencing the same when the value contains quotes? If yes, how did you solve this, please?

I also wanted to invite a couple of subject matter experts to this conversation @ConnorSlivensky, @CateDuarte and @ChristinaKay do you have tips to help @mmaddiona, please?
If anybody else has anything to add and/or share, please feel free to join in the conversation :slightly_smiling_face:
Thank you in advance for your help and have a wonderful day!
Best,
Bérangère