Metasploit msfconsole method_missing on Fedora 19

て烟熏妆下的殇ゞ 提交于 2019-12-10 20:44:23

问题


I installed metasploit on my Fedora 19 using this guide from fedora. After finishing all the steps I run msfconsole and get the following error:

/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>'

Any ideas how to fix this? It says method_missing: undefined local variable or method "ext_dir" so this looks like some kind of Ruby dependency issue.

Update: msfupdate runs successfully.


回答1:


Are you running a 64bit version of fedora? If so I would suggest you download the packages from rapid7 website. Its more dependable, and when installed any dependency issues will be resolved. With 64bt linux you can also couple metasploit with Nexpose their free scanner. These two tools work hand in hand. The issue you are seeing looks like a version problem. If you don't mind running a VM I would suggest you download Kali linux for your security testing needs which will work out of the box + give you a ton more tools.



来源:https://stackoverflow.com/questions/19433888/metasploit-msfconsole-method-missing-on-fedora-19

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!