Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Fix usage of validateHMAC #679

Merged
merged 2 commits into from
Jul 29, 2024

Conversation

cjobeilicampings
Copy link
Contributor

Description
Hi,

We are currently working on an Adyen integration and struggled with the validateHMAC method. It looks like there were some problems:

The hmacSign sent in the webhook request is never in hexadecimal, so ctype_xdigit is always false. We must validate the HMAC key $hmacKey and use it in the pack function.

Finally, we need to compare the expectedSign with the hmacSign passed in the parameters.

Is this correct for you?

Thank you,

Tested scenarios

Fixed issue:

@cjobeilicampings cjobeilicampings requested a review from a team as a code owner July 19, 2024 16:27
@DjoykeAbyah
Copy link
Contributor

Hi @cjobeilicampings!

Thanks for contributing a fix to this issue! We're merging this to implement your changes.

Kind Regards,
Djoyke
Adyen

Copy link

sonarcloud bot commented Jul 29, 2024

@DjoykeAbyah DjoykeAbyah merged commit 883a33e into Adyen:main Jul 29, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants