|
|
|
@ -9,11 +9,6 @@ auth = HTTPTokenAuth()
|
|
|
|
|
def verify_token(token):
|
|
|
|
|
try:
|
|
|
|
|
data = s.loads(token)
|
|
|
|
|
#except BadSignature:
|
|
|
|
|
#raise AuthFailed(msg='token不正确')
|
|
|
|
|
except SignatureExpired:
|
|
|
|
|
raise AuthFailed(msg='token过期')
|
|
|
|
|
return {"code": 40000, "data": "登录过期,请重新登录!"}
|
|
|
|
|
except:
|
|
|
|
|
return False
|
|
|
|
|
return True
|
|
|
|
|