Skip to content

Commit 0582e7e

Browse files
committed
Return nil instead of "null"
A scenario is when FF disables Flash, BES returns "null", and when modules try to use Gem::Version, the "null" is considered a malformed data and it won't be able to continue.
1 parent c327073 commit 0582e7e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/msf/core/exploit/remote/browser_exploit_server.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -303,7 +303,7 @@ def process_browser_info(source, cli, request)
303303
parsed_body = CGI::parse(Rex::Text.decode_base64(request.body) || '')
304304
vprint_status("Received sniffed browser data over POST:")
305305
vprint_line("#{parsed_body}.")
306-
parsed_body.each { |k, v| profile[k.to_sym] = v.first }
306+
parsed_body.each { |k, v| profile[k.to_sym] = (v.first == 'null' ? nil : v.first) }
307307
found_ua_name = parsed_body['ua_name']
308308
found_ua_ver = parsed_body['ua_ver']
309309

0 commit comments

Comments
 (0)