def validate(self, method, url, params):
    base_string = self.get_signature_base_string(method, url, params)
    local_hash = hashlib.sha1(base_string).digest()
    
    if not params.has_key("oauth_signature"):
      return False
      
    try:
      encoded_remote_signature = urllib.unquote(params["oauth_signature"])
      remote_signature = base64.decodestring(encoded_remote_signature)
      remote_hash = self.public_key.encrypt(remote_signature, '')[0][-20:]
    except:
      return False
      
    return local_hash == remote_hash
Get the value of a jobconf variable from the runtime environment.
dataset/ETHPy150Open jpic/playlistnow.fm/opensocial/validator.py/RsaSha1Validator.validate--crossover with--dataset/ETHPy150Open Yelp/mrjob/mrjob/compat.py/jobconf_from_env