Skip to content

Commit a69609f

Browse files
author
Brent Cook
committed
Land rapid7#4523: wchen-r7's #inspect->to_s conversions
Keep custom object display behavior the same between Ruby 1.9 and 2.1.
2 parents e73ff61 + 44dfa74 commit a69609f

File tree

11 files changed

+10
-11
lines changed

11 files changed

+10
-11
lines changed

modules/auxiliary/scanner/http/coldfusion_locale_traversal.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ def run_host(ip)
188188
end
189189
else
190190
next if (res.code == 500 or res.code == 404 or res.code == 302)
191-
print_error("#{ip} #{res.inspect}")
191+
print_error("#{ip} #{res.to_s}")
192192
end
193193
end
194194

modules/auxiliary/scanner/lotus/lotus_domino_hashes.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ def run_host(ip)
5959

6060
else
6161
print_error("http://#{vhost}:#{rport} - Lotus Domino - Unrecognized #{res.code} response")
62-
print_error(res.inspect)
62+
print_error(res.to_s)
6363
return :abort
6464

6565
end

modules/exploits/unix/webapp/oracle_vm_agent_utl.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ def go(command)
122122
end
123123

124124
print_error("Encountered unexpected #{res.code} response:")
125-
print_error(res.inspect)
125+
print_error(res.to_s)
126126

127127
return nil
128128
end

modules/exploits/windows/http/easyftp_list.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ def exploit
116116

117117
if (res)
118118
print_error("The server unexpectedly responded, this is not good.")
119-
print_status(res.inspect)
119+
print_status(res.to_s)
120120
end
121121

122122
handler

modules/exploits/windows/http/hp_nnm_ovbuildpath_textfile.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ def exploit
237237
print_error("Eek! We weren't expecting a response, but we got one")
238238
if datastore['DEBUG']
239239
print_line()
240-
print_error(res.inspect)
240+
print_error(res.to_s)
241241
end
242242
end
243243

modules/exploits/windows/http/hp_nnm_ovwebsnmpsrv_uro.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ def exploit
131131

132132
if res and res.code != 502
133133
print_error("Eek! We weren't expecting a response, but we got one")
134-
print_status(res.inspect) if datastore['NNM_DEBUG']
134+
print_status(res.to_s) if datastore['NNM_DEBUG']
135135
end
136136

137137
handler

modules/exploits/windows/http/hp_nnm_snmpviewer_actapp.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ def exploit
162162

163163
if res and res.code != 502
164164
print_error("Eek! We weren't expecting a response, but we got one")
165-
print_status(res.inspect) if datastore['NNM_DEBUG']
165+
print_status(res.to_s) if datastore['NNM_DEBUG']
166166
end
167167

168168
handler

modules/exploits/windows/http/hp_nnm_webappmon_execvp.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ def exploit
159159
print_error("Eek! We weren't expecting a response, but we got one")
160160
if datastore['DEBUG']
161161
print_error('')
162-
print_error(res.inspect)
162+
print_error(res.to_s)
163163
end
164164
end
165165

modules/exploits/windows/http/hp_nnm_webappmon_ovjavalocale.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ def exploit
159159
print_error("Eek! We weren't expecting a response, but we got one")
160160
if datastore['DEBUG']
161161
print_error('')
162-
print_error(res.inspect)
162+
print_error(res.to_s)
163163
end
164164
end
165165

modules/post/windows/gather/credentials/tortoisesvn.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,6 @@ def decrypt_password(data)
4848
addr = [mem].pack("V")
4949
len = [data.length].pack("V")
5050
ret = rg.crypt32.CryptUnprotectData("#{len}#{addr}", 16, nil, nil, nil, 0, 8)
51-
#print_status("#{ret.inspect}")
5251
len, addr = ret["pDataOut"].unpack("V2")
5352
else
5453
addr = [mem].pack("Q")

0 commit comments

Comments
 (0)