wsj1995 commited on
Commit
2a16e88
·
verified ·
1 Parent(s): 3c225c6

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +1 -1
main.py CHANGED
@@ -19,7 +19,7 @@ async def verify_internal_token(request: Request):
19
  path = request.url.path
20
  if timestamp > int(timestampStr):
21
  raise HTTPException(status_code=403, detail="Forbidden")
22
- md5hash = hashlib.md5(f"{path}-{timestampStr}-{rand}-{uid}-{os.env.get('AUTH_KEY')}".encode())
23
  md5 = md5hash.hexdigest()
24
  if md5 != hashStr:
25
  raise HTTPException(status_code=403, detail="Forbidden")
 
19
  path = request.url.path
20
  if timestamp > int(timestampStr):
21
  raise HTTPException(status_code=403, detail="Forbidden")
22
+ md5hash = hashlib.md5(f"{path}-{timestampStr}-{rand}-{uid}-{os.environ.get('AUTH_KEY')}".encode())
23
  md5 = md5hash.hexdigest()
24
  if md5 != hashStr:
25
  raise HTTPException(status_code=403, detail="Forbidden")