mirror of
https://github.com/akuker/RASCSI.git
synced 2024-11-26 13:49:21 +00:00
Secure file names also for generic image file creation
This commit is contained in:
parent
9a7989437d
commit
c77e1b18ce
@ -510,6 +510,9 @@ def create_file():
|
||||
size = (int(request.form.get("size")) * 1024 * 1024)
|
||||
file_type = request.form.get("type")
|
||||
|
||||
from werkzeug.utils import secure_filename
|
||||
file_name = secure_filename(file_name)
|
||||
|
||||
process = create_new_image(file_name, file_type, size)
|
||||
if process["status"] == True:
|
||||
flash(f"Drive image created as {file_name}.{file_type}")
|
||||
|
Loading…
Reference in New Issue
Block a user