forked from p15670423/monkey
Deleted redundant const
This commit is contained in:
parent
832662602d
commit
844b2f1e2a
|
@ -1,6 +1,7 @@
|
|||
import flask_restful
|
||||
from flask import send_from_directory
|
||||
from monkey_island.cc.resources.pba_file_upload import GET_FILE_DIR
|
||||
|
||||
from monkey_island.cc.services.post_breach_files import UPLOADS_DIR
|
||||
|
||||
__author__ = 'VakarisZ'
|
||||
|
||||
|
@ -12,4 +13,4 @@ class PBAFileDownload(flask_restful.Resource):
|
|||
|
||||
# Used by monkey. can't secure.
|
||||
def get(self, path):
|
||||
return send_from_directory(GET_FILE_DIR, path)
|
||||
return send_from_directory(UPLOADS_DIR, path)
|
||||
|
|
|
@ -11,7 +11,6 @@ import copy
|
|||
__author__ = 'VakarisZ'
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
GET_FILE_DIR = "./userUploads"
|
||||
# Front end uses these strings to identify which files to work with (linux of windows)
|
||||
LINUX_PBA_TYPE = 'PBAlinux'
|
||||
WINDOWS_PBA_TYPE = 'PBAwindows'
|
||||
|
@ -37,7 +36,7 @@ class FileUpload(flask_restful.Resource):
|
|||
filename = ConfigService.get_config_value(copy.deepcopy(PBA_LINUX_FILENAME_PATH))
|
||||
else:
|
||||
filename = ConfigService.get_config_value(copy.deepcopy(PBA_WINDOWS_FILENAME_PATH))
|
||||
return send_from_directory(GET_FILE_DIR, filename)
|
||||
return send_from_directory(UPLOADS_DIR, filename)
|
||||
|
||||
@jwt_required()
|
||||
def post(self, file_type):
|
||||
|
|
Loading…
Reference in New Issue