diff --git a/nodejsscan/app.py b/nodejsscan/app.py index e4b21175..25e29dde 100644 --- a/nodejsscan/app.py +++ b/nodejsscan/app.py @@ -11,7 +11,7 @@ import nodejsscan.utils as utils from web.upload import handle_upload -from web.git import clone +from web.git_utils import clone from web.dashboard import ( home, issue_hide, diff --git a/nodejsscan/settings.py b/nodejsscan/settings.py index efddc97a..ce00d40d 100644 --- a/nodejsscan/settings.py +++ b/nodejsscan/settings.py @@ -4,7 +4,7 @@ from pathlib import Path # GENERAL -VERSION = '4.4' +VERSION = '4.5' UPLOAD_FOLDER = Path('~/.nodejsscan/').expanduser().as_posix() Path(UPLOAD_FOLDER).mkdir(parents=True, exist_ok=True) UPLD_MIME = [ diff --git a/web/dashboard.py b/web/dashboard.py index ab8b8c1d..f51d69d2 100644 --- a/web/dashboard.py +++ b/web/dashboard.py @@ -186,7 +186,7 @@ def view_file(request): 'status': 'failed', 'contents': 'Path Traversal Detected!'} else: - if req_path.is_file(): + if req_path.is_file(): # lgtm [py/path-injection] contents = utils.read_file(req_path.as_posix()) context = {'contents': contents} return jsonify(**context) diff --git a/web/git.py b/web/git_utils.py similarity index 100% rename from web/git.py rename to web/git_utils.py