From 732121dd8ea09e240e24e4fc9e2e6cd0d428b758 Mon Sep 17 00:00:00 2001 From: suryagh Date: Mon, 16 May 2016 19:55:44 -0400 Subject: [PATCH] encodeURIComponent is redundant `proof` is `hex` encoded, and is URI safe. Remove redundant URI encoding attempt. --- lib/strategy.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/strategy.js b/lib/strategy.js index dd4921b..f7881b1 100644 --- a/lib/strategy.js +++ b/lib/strategy.js @@ -143,7 +143,7 @@ Strategy.prototype.userProfile = function(accessToken, done) { // For further details, refer to: // https://developers.facebook.com/docs/reference/api/securing-graph-api/ var proof = crypto.createHmac('sha256', this._clientSecret).update(accessToken).digest('hex'); - url.search = (url.search ? url.search + '&' : '') + 'appsecret_proof=' + encodeURIComponent(proof); + url.search = (url.search ? url.search + '&' : '') + 'appsecret_proof=' + proof; } if (this._profileFields) { var fields = this._convertProfileFields(this._profileFields);