This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import hmac | |
import base64 | |
import hashlib | |
# simplejson is available at: http://pypi.python.org/pypi/simplejson/ | |
import simplejson as json | |
class RequestSigner(object): | |
def verify_and_load_signed_request(self, signed_request, secret): | |
"""Verify the signature, and return decoded data from a signed_request value""" | |
try: |