forked from p34709852/monkey
Merge pull request #890 from guardicore/custom_pba_bugfix
Fixed custom post breach action path bug.
This commit is contained in:
commit
99d73be0d8
|
@ -1,7 +1,7 @@
|
|||
import flask_restful
|
||||
from flask import send_from_directory
|
||||
|
||||
from monkey_island.cc.services.post_breach_files import UPLOADS_DIR
|
||||
from monkey_island.cc.services.post_breach_files import UPLOADS_DIR_NAME
|
||||
|
||||
__author__ = 'VakarisZ'
|
||||
|
||||
|
@ -13,4 +13,4 @@ class PBAFileDownload(flask_restful.Resource):
|
|||
|
||||
# Used by monkey. can't secure.
|
||||
def get(self, path):
|
||||
return send_from_directory(UPLOADS_DIR, path)
|
||||
return send_from_directory(UPLOADS_DIR_NAME, path)
|
||||
|
|
|
@ -11,7 +11,8 @@ logger = logging.getLogger(__name__)
|
|||
# Where to find file names in config
|
||||
PBA_WINDOWS_FILENAME_PATH = ['monkey', 'post_breach', 'PBA_windows_filename']
|
||||
PBA_LINUX_FILENAME_PATH = ['monkey', 'post_breach', 'PBA_linux_filename']
|
||||
PBA_UPLOAD_PATH = ['monkey_island', 'cc', 'userUploads']
|
||||
UPLOADS_DIR_NAME = 'userUploads'
|
||||
PBA_UPLOAD_PATH = ['monkey_island', 'cc', UPLOADS_DIR_NAME]
|
||||
UPLOADS_DIR = Path(*PBA_UPLOAD_PATH)
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue