lib/msf/core/module_manager.rb
#
# Enumerates the modules in the supplied array with possible limiting
# factors.
#
Enumerates the modules in the supplied array with possible limiting
factors.
Enumerates the modules in the supplied array with possible limiting factors .
def each_module_list(ary, opts, &block)
		ary.each { |entry|
			name, mod = entry
			next if (mod == SymbolicModule)
			if (opts['Arch'])
				if (!mod_arch_hash[mod])
					mod_arch_hash[mod] = mod.new.arch
				end
				next if ((mod_arch_hash[mod] & opts['Arch']).empty? == true)
			end
			if (opts['Platform'])
				if (!mod_platform_hash[mod])
					mod_platform_hash[mod] = mod.new.platform
				end
				next if ((mod_platform_hash[mod] & opts['Platform']).empty? == true)
			end
			next if (each_module_filter(opts, name, entry) == true)
			block.call(name, mod)
		}
	end
def each_module_list ( ary , opts , & block ) ary . each { | entry | name , mod = entry next if ( mod == SymbolicModule ) if ( opts [ 'Arch' ] ) if ( ! mod_arch_hash [ mod ] ) mod_arch_hash [ mod ] = mod . new . arch end next if ( ( mod_arch_hash [ mod ] & opts [ 'Arch' ] ) . empty? == true ) end if ( opts [ 'Platform' ] ) if ( ! mod_platform_hash [ mod ] ) mod_platform_hash [ mod ] = mod . new . platform end next if ( ( mod_platform_hash [ mod ] & opts [ 'Platform' ] ) . empty? == true ) end next if ( each_module_filter ( opts , name , entry ) == true ) block . call ( name , mod ) } end
Enumerates the modules in the supplied array with possible limiting
factors.
Enumerates the modules in the supplied array with possible limiting factors .
# Skip any lingering symbolic modules. # Filter out incompatible architectures # Filter out incompatible platforms # Custom filtering
ary
<not_specific>
opts
<not_specific>
block
<not_specific>