bootbot icon indicating copy to clipboard operation
bootbot copied to clipboard

Support appsecret_proof

Open Charca opened this issue 8 years ago • 0 comments

Facebook provides the option to secure Graph API requests with an appsecret_proof hash. More info here: https://developers.facebook.com/docs/graph-api/securing-requests/

This hash is generated with sha256 using the access_token and app_secret, which we already require in the BootBot constructor.

Implementing this should be as simple as adding a useAppSecretProof boolean option to the BootBot constructor, which will be false by default, but if set to true, we should generate the hash using the crypto library and add it to the request to Graph API in sendMessage.

Charca avatar Dec 04 '17 15:12 Charca