mirror of
https://git.0x0.st/mia/0x0.git
synced 2026-01-09 20:11:46 +03:00
File: Fix 404 case with secret URLs
This commit is contained in:
5
fhost.py
5
fhost.py
@@ -439,10 +439,11 @@ def get(path, secret=None):
|
|||||||
|
|
||||||
if sufs:
|
if sufs:
|
||||||
f = File.query.get(id)
|
f = File.query.get(id)
|
||||||
if f.secret != secret:
|
|
||||||
abort(404)
|
|
||||||
|
|
||||||
if f and f.ext == sufs:
|
if f and f.ext == sufs:
|
||||||
|
if f.secret != secret:
|
||||||
|
abort(404)
|
||||||
|
|
||||||
if f.removed:
|
if f.removed:
|
||||||
abort(451)
|
abort(451)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user