Skip to content

Commit 199a7cc

Browse files
committed
Check for subdirectories and relative paths
1 parent 09d931e commit 199a7cc

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/msf/core/exploit/file_dropper.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,8 @@ def file_dropper_check_cwd?(path)
269269
session.shell_command_token('pwd').strip
270270
end
271271

272-
return true if path == pwd
272+
# Check for subdirectories and relative paths
273+
return true if pwd.include?(path)
273274
end
274275

275276
false

0 commit comments

Comments
 (0)