Commit 89a3b434 authored by RobertDing's avatar RobertDing

FIX - del 冗余

parent c9b8b110
......@@ -22,8 +22,6 @@ import settings
class Request(object):
URL = settings.BASE_URL
def __init__(self, subject):
self.subject = subject
yingtz_key = base64.b64decode(open(settings.YINGTZ_KEY_TEST).read())
......@@ -76,10 +74,6 @@ class Request(object):
return content
def check_sign(self, content, sign):
if isinstance(content, str):
content = base64.b16decode(content.upper)
cal_sign = hashlib.md5(content+settings.MD5KEY).hexdigest()
if sign == cal_sign:
return
raise Exception('check sign error')
if sign != cal_sign:
raise ValueError('check sign error')
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment