工单优化
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
from . import http
|
||||
from . import models
|
||||
from . import process_status
|
||||
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ class Http(models.AbstractModel):
|
||||
raise AuthenticationError('无效的token')
|
||||
timestamp_str = int(time.time())
|
||||
# 设置API接口请求时间,不能超过5秒
|
||||
deltime = datetime.timedelta(seconds=60)
|
||||
deltime = datetime.timedelta(seconds=5)
|
||||
if abs(int(datas['HTTP_TIMESTAMP'])-timestamp_str) > deltime.seconds:
|
||||
raise AuthenticationError('请求已过期')
|
||||
# 获得sha1_str加密字符串
|
||||
|
||||
Reference in New Issue
Block a user