3

我使用 fedora 的这个指南在我的 Fedora 19 上安装了 metasploit 。完成所有步骤后,我运行msfconsole并收到以下错误:

/usr/local/share/ruby/site_ruby/rubygems/specification.rb:1888:in 'method_missing': undefined local variable or method 'ext_dir' for #<Gem::Specification:0xecbd78 json-1.8.0> (NameError) from /usr/share/gems/gems/bundler-1.3.1/lib/bundler/rubygems_ext.rb:42:in 'load_paths' from /usr/share/gems/gems/bundler-1.3.1/lib/bundler/runtime.rb:37:in 'block in setup' from /usr/share/gems/gems/bundler-1.3.1/lib/bundler/runtime.rb:19:in .setup' from /usr/share/gems/gems/bundler-1.3.1/lib/bundler.rb:120:in 'setup' from /usr/share/gems/gems/bundler-1.3.1/lib/bundler/setup.rb:7:in ''top (required)>' from /usr/local/share/ruby/site_ruby/rubygems/core_ext/kernel_require.rb:135:in 'require' from /usr/local/share/ruby/site_ruby/rubygems/core_ext/kernel_require.rb:135:in 'rescue in require' from /usr/local/share/ruby/site_ruby/rubygems/core_ext/kernel_require.rb:144:in 'require' from /opt/metasploit/msf/lib/fastlib.rb:374:in 'require' from /opt/metasploit/msf/lib/msfenv.rb:7:in '<top (required)>' from /usr/local/share/ruby/site_ruby/rubygems/core_ext/kernel_require.rb:55:in 'require' from /usr/local/share/ruby/site_ruby/rubygems/core_ext/kernel_require.rb:55:in 'require' from /opt/metasploit/msf/lib/fastlib.rb:374:in 'require' from /usr/local/bin/msfconsole:21:in '<main>'

任何想法如何解决这一问题?它说 method_missing: undefined local variable or method "ext_dir" 所以这看起来像是某种 Ruby 依赖问题。

更新: msfupdate运行成功。

4

1 回答 1

0

你运行的是 64 位版本的 fedora 吗?如果是这样,我建议您从 rapid7 网站下载软件包。它更可靠,安装后任何依赖问题都将得到解决。使用 64bt linux,您还可以将 metasploit 与 Nexpose 他们的免费扫描仪结合使用。这两个工具齐头并进。您看到的问题看起来像是版本问题。如果您不介意运行 VM,我建议您下载 Kali linux 以满足您的安全测试需求,它可以开箱即用 + 为您提供更多工具。

于 2013-10-17T18:05:59.673 回答