diff --git a/app/invokers/webhook_invoker.py b/app/invokers/webhook_invoker.py index 54fe137..26cc480 100644 --- a/app/invokers/webhook_invoker.py +++ b/app/invokers/webhook_invoker.py @@ -297,9 +297,8 @@ def validate_incoming_signature(self, msg: dict) -> bool: # Remove the headers to avoid them being used in the signature verification del msg["headers"]["X-Port-Signature"] del msg["headers"]["X-Port-Timestamp"] - expected_sig = sign_sha_256( - json.dumps(msg, separators=(",", ":")), + json.dumps(msg, separators=(",", ":"), ensure_ascii=False), settings.PORT_CLIENT_SECRET, port_timestamp, )