diff --git a/scripts/meterpreter/get_local_subnets.rb b/scripts/meterpreter/get_local_subnets.rb index 30d63cd388..8ad12f447a 100644 --- a/scripts/meterpreter/get_local_subnets.rb +++ b/scripts/meterpreter/get_local_subnets.rb @@ -1,20 +1,23 @@ # $Id:$ -## Meterpreter script that display local subnets -## Provided by Nicob -## Ripped from http://blog.metasploit.com/2006/10/meterpreter-scripts-and-msrt.html +# Meterpreter script that display local subnets +# Provided by Nicob +# Ripped from http://blog.metasploit.com/2006/10/meterpreter-scripts-and-msrt.html @@exec_opts = Rex::Parser::Arguments.new( - "-h" => [ false,"Help menu." ] + "-h" => [ false, "Help menu." ] ) +def usage + print_line("Get a list of local subnets based on the host's routes") + print_line("USAGE: run get_local_subnets") + print_line(@@exec_opts.usage) + raise Rex::Script::Completed +end @@exec_opts.parse(args) { |opt, idx, val| case opt when "-h" - print_line("Get a list of local subnets based on the host's routes") - print_line("USAGE: run get_local_subnets") - print_line(@@exec_opts.usage) - raise Rex::Script::Completed + usage end }