Hi, I'm having trouble matching the signature Shopify generates for a shop with the character "®" in it's shop name.
Please see the full request params below, ignore the slashes this is because I've stringified the json request body.
"{\"utf8\":\"✓\",\"authenticity_token\":\"Ya5BYUm9is1JyEAjVT5ZxfAzPKxjGw0t4ft0oH1NrNBME9qwmqYF98BaGvt68236Gmd8GK1xR0RwYyoa5RvJsg==\",\"x_reference\":\"10881755009\",\"x_account_id\":\"gofreepants\",\"x_amount\":\"98.00\",\"x_currency\":\"USD\",\"x_url_callback\":\"https://checkout.shopify.com/services/ping/notify_integration/payzing/2261955\",\"x_url_complete\":\"https://checkout.shopify.com/2261955/checkouts/5cb8e76546df8d244f8a6cd01815664d/offsite_gateway_callback\",\"x_shop_country\":\"US\",\"x_shop_name\":\"Go Free® Pants\",\"x_test\":\"false\",\"x_customer_first_name\":\"Daniel\",\"x_customer_last_name\":\"Webb\",\"x_customer_email\":\"[email protected]\",\"x_customer_phone\":\"+441271344265\",\"x_customer_billing_country\":\"GB\",\"x_customer_billing_city\":\"Barnstaple\",\"x_customer_billing_company\":\"Mr.\",\"x_customer_billing_address1\":\"weirside way\",\"x_customer_billing_zip\":\"EX327RB\",\"x_customer_billing_phone\":\"+441271344265\",\"x_customer_shipping_country\":\"GB\",\"x_customer_shipping_first_name\":\"Daniel\",\"x_customer_shipping_last_name\":\"Webb\",\"x_customer_shipping_city\":\"Barnstaple\",\"x_customer_shipping_company\":\"Mr.\",\"x_customer_shipping_address1\":\"weirside way\",\"x_customer_shipping_zip\":\"EX327RB\",\"x_customer_shipping_phone\":\"+441271344265\",\"x_invoice\":\"#10881755009\",\"x_description\":\"Go Free® Pants - #10881755009\",\"x_url_cancel\":\"http://gofreepants.myshopify.com/cart\",\"x_signature\":\"7b61044affc253f0485f08c44f071a37c9535f3aedf4362bd5197725f0b39ddc\"}"
var message = Object.keys(params).sort().map(function(key) {
if(key!=='x_signature' && ~key.indexOf('x_')) return key+params[key];
}).join('');
var hmac = crypto.createHmac('SHA256', String(secret));
hmac.setEncoding('hex');
hmac.write(message);
hmac.end();
return hmac.read();