Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,8 @@ def test_user_input_is_longer_than_file_path():

def test_absolute_linux_path():
assert detect_path_traversal("/etc/passwd", "/etc/passwd") is True
assert detect_path_traversal("/home/binaries/test", "/home/binaries") is True
assert detect_path_traversal("/app/.env", "/app/.env") is True


def test_linux_user_directory():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@
"/tmp/",
"/usr/",
"/var/",
# More common in docker apps :
"/app/",
"/code/",
]

# List of dangerous path starts, including Windows paths
Expand Down