app: fix unauthorized file upload access
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
parent
d42fd3b095
commit
2b79a129aa
|
@ -602,6 +602,7 @@ class FileUploadHandler(AuthorizedRequestHandler):
|
||||||
self.max_upload_size = max_upload_size
|
self.max_upload_size = max_upload_size
|
||||||
|
|
||||||
def prepare(self):
|
def prepare(self):
|
||||||
|
super(FileUploadHandler, self).prepare()
|
||||||
if self.request.method == "POST":
|
if self.request.method == "POST":
|
||||||
self.request.connection.set_max_body_size(self.max_upload_size)
|
self.request.connection.set_max_body_size(self.max_upload_size)
|
||||||
tmpname = self.file_manager.gen_temp_upload_path()
|
tmpname = self.file_manager.gen_temp_upload_path()
|
||||||
|
|
Loading…
Reference in New Issue