MSF Console error

2,483 views
Skip to first unread message

Fabricio Silva

unread,
Nov 23, 2016, 9:07:48 PM11/23/16
to PentestBox Forum
I'm facing the error:

C:\Users\Fabricio\Desktop
> msfconsole

Bundler could not find compatible versions for gem "rex-registry":
  In Gemfile:
    metasploit-framework x86-mingw32 was resolved to 4.12.20, which depends on
      rex-registry x86-mingw32

Could not find gem 'rex-registry x86-mingw32', which is required by gem 'metasploit-framework x86-mingw32', in any of the sources.

How to fix this?

Aditya Agrawal

unread,
Nov 28, 2016, 12:30:33 PM11/28/16
to PentestBox Forum
Sorry for the late reply.

What is your installation location and did you tried to install any gem or modify any file from the pentestbox directory ?

Geng Arthur

unread,
Nov 29, 2016, 4:17:11 AM11/29/16
to PentestBox Forum
there is a same problem with mine.
1. I download the pentest box with MSF,  and installed it on C:\pentestbox\
2. When I ran msfconsole, it said "Metasploit requires the bundler gem to be install", so I ran update all at first. Then, I ran gem install bundler and bundle install.
3.after I finish the step 2. I restart pentestbox, and ran msfconsole, but the window show the message below.
C:\Users\admin\Desktop

Aditya Agrawal

unread,
Nov 29, 2016, 4:20:18 AM11/29/16
to PentestBox Forum
Hey Geng Arthur,

Are u using windows 7 ? Also Pentestbox installation path is case sensitive, so make sure it is C:/Pentestbox instead of c:/pentestbox. 

Geng Arthur

unread,
Nov 29, 2016, 4:59:49 AM11/29/16
to PentestBox Forum
Sorry, I checked again, the path is C:\PentestBox. I changed the the name folder to pentestbox, but nothing changed, the problem is still here.
Because it said "Could not find gem 'rex-registry x86-mingw32'", so i ran gem install rex-registry
And then, it said "Could not find gem 'rex-ole x86-mingw32'", so I ran gem install rex-ole
after, It said "metasploit-payloads (= 1.1.13) x86-mingw32'", so I ran  gem install metasploit-payloads
I thought the problem should be done, but it still said "metasploit-payloads (= 1.1.13) x86-mingw32'".
the install message on below.
C:\pentestbox\bin\metasploit-framework
> msfconsole
Bundler could not find compatible versions for gem "metasploit-payloads":

  In Gemfile:
    metasploit-framework x86-mingw32 was resolved to 4.12.20, which depends on
      metasploit-payloads (= 1.1.13) x86-mingw32
Could not find gem 'metasploit-payloads (= 1.1.13) x86-mingw32', which is required by gem 'metasploit-framework x86-mingw32', in any of the sources.
C:\pentestbox\bin\metasploit-framework
> gem install metasploit-payloads
Successfully installed metasploit-payloads-1.2.2
Parsing documentation for metasploit-payloads-1.2.2
Done installing documentation for metasploit-payloads after 0 seconds
1 gem installed
C:\pentestbox\bin\metasploit-framework
> msfconsole
Bundler could not find compatible versions for gem "metasploit-payloads":

  In Gemfile:
    metasploit-framework x86-mingw32 was resolved to 4.12.20, which depends on
      metasploit-payloads (= 1.1.13) x86-mingw32
Could not find gem 'metasploit-payloads (= 1.1.13) x86-mingw32', which is required by gem 'metasploit-framework x86-mingw32', in any of the sources.
my metasploit-payloads is  1.2.2, but the error message said the metasploit-payloads should be  1.1.13.
Maybe, the error is connected with that.

Geng Arthur

unread,
Nov 29, 2016, 5:06:23 AM11/29/16
to PentestBox Forum
My system is Win 10 with 64bit.
the update MSF message below.
Updating: Metasploit
Fetching origin
HEAD is now at 841dada Merge pull request #2 from rapid7/master
Warning: the running version of Bundler is older than the version that created the lockfile. We suggest you upgrade to the latest version of Bundler by running `gem install bundler`.
Fetching gem metadata from https://rubygems.org/............
Fetching version metadata from https://rubygems.org/...
Fetching dependency metadata from https://rubygems.org/..
Resolving dependencies.......
Installing rake 11.2.2
Using i18n 0.7.0
Using json 1.8.3
Installing minitest 5.9.0
Using thread_safe 0.3.5
Using builder 3.2.2
Using erubis 2.7.0
Installing mini_portile2 2.1.0
Installing pkg-config 1.1.7
Using rack 1.6.4
Using arel 6.0.3
Using addressable 2.4.0
Installing ffi 1.9.14
Using contracts 0.14.0
Installing gherkin 4.0.0
Using cucumber-wire 0.0.1
Using diff-lcs 1.2.5
Installing multi_json 1.12.1
Using multi_test 0.1.2
Installing rspec-support 3.5.0
Using thor 0.19.1
Using bcrypt 3.1.11
Installing bit-struct 0.15.0
Installing mime-types-data 3.2016.0521
Using coderay 1.1.1
Using docile 1.1.5
Using multipart-post 2.0.0
Using filesize 0.1.1
Using fivemat 1.3.2
Using rkelly-remix 0.0.6
Using metasm 1.0.2
Installing pg 0.19.0 (was 0.18.4)
Using pg_array_parser 0.0.9
Installing rubyntlm 0.6.1 (was 0.6.0)
Using rubyzip 1.2.0
Installing metasploit-payloads 1.1.13
Installing metasploit_payloads-mettle 0.0.6
Installing msgpack 1.0.2 (was 1.0.0)
Installing net-ssh 3.2.0
Using network_interface 0.0.1
Using openssl-ccm 1.2.1
Using pcaprub 0.12.4
Using patch_finder 1.0.2
Using redcarpet 3.3.4
Using rex-text 0.2.9 (was 0.1.1)
Installing rex-java 0.1.3 (was 0.1.2)
Using rex-registry 0.1.1 (was 0.1.0)
Installing rex-struct2 0.1.0
Using robots 0.10.1
Installing sqlite3 1.3.12 (was 1.3.11)
Installing sshkey 1.8.0
Installing windows_error 0.0.2
Using method_source 0.8.2
Using slop 3.6.0
Using simplecov-html 0.10.0
Using timecop 0.8.1
Installing yard 0.9.0
Using bundler 1.11.2
Using tzinfo 1.2.2
Installing nokogiri 1.6.8
Using rack-test 0.6.3
Using childprocess 0.5.9
Installing cucumber-core 1.5.0
Installing rspec-expectations 3.5.0
Installing rspec-core 3.5.1
Installing rspec-mocks 3.5.0
Installing mime-types 3.1
Using faraday 0.9.2
Using jsobfu 0.4.1
Using packetfu 1.1.11
Installing rex-arch 0.1.3 (was 0.1.0)
Using rex-ole 0.1.3 (was 0.1.2)
Installing rex-random_identifier 0.1.1 (was 0.1.0)
Installing rex-zip 0.1.1 (was 0.1.0)
Installing pry 0.10.4
Installing simplecov 0.12.0
Installing activesupport 4.2.7
Installing tzinfo-data 1.2016.10 (was 1.2016.6)
Using loofah 2.0.3
Using xpath 2.0.0
Installing recog 2.1.0 (was 2.0.21)
Installing cucumber 2.4.0
Using sawyer 0.7.0
Installing rex-powershell 0.1.68 (was 0.1.1)
Using rails-deprecated_sanitizer 1.0.3
Installing activemodel 4.2.7
Using factory_girl 4.7.0
Using shoulda-matchers 3.1.1
Using rails-html-sanitizer 1.0.3
Using capybara 2.7.1
Using aruba 0.14.1
Using octokit 4.3.0
Using rails-dom-testing 1.0.7
Installing activerecord 4.2.7
Installing actionview 4.2.7
Using arel-helpers 2.3.0
Using postgres_ext 3.0.0
Installing actionpack 4.2.7
Installing railties 4.2.7
Using cucumber-rails 1.4.3
Using factory_girl_rails 4.7.0
Installing metasploit-concern 2.0.3 (was 2.0.1)
Installing metasploit-model 2.0.3 (was 2.0.0)
Installing rspec-rails 3.5.1
Installing metasploit_data_models 2.0.9 (was 2.0.0)
Installing metasploit-credential 2.0.8 (was 2.0.3)
Using metasploit-framework 4.12.20 from source at `.`
Bundle complete! 14 Gemfile dependencies, 107 gems now installed.
Use `bundle show [gemname]` to see where a bundled gem is installed.
Post-install message from nokogiri:
Nokogiri is built with the packaged libraries: libxml2-2.9.4, libxslt-1.1.29, zlib-1.2.8, libiconv-1.14.

Aditya Agrawal

unread,
Nov 29, 2016, 5:10:56 AM11/29/16
to PentestBox Forum
You are still using C:/pentestbox as a path, could you please remove current folder and reinstall pentestbox with C:/PentestBox as path.

Your last message show that all gems are installed, that means it should run now. have u tried running again ?

Geng Arthur

unread,
Nov 29, 2016, 5:19:21 AM11/29/16
to PentestBox Forum
All right, there is a good news, I solve it.
It doesn't matter with your path or folder name.
I still don't know where is the bug comes from, but I solve it.
Follow with my steps.
1. If you run msfconsole or any MSF function, it said "Metasploit requires the bundler gem to be install". Don't be worry, try to run "gem install bundler" and "bundle install"
2.run msfconsole, if it said "Could not find gem 'rex-registry x86-mingw32'", try to run "gem install rex-registry"
3.run msfconsole again, if it said "Could not find gem 'rex-ole x86-mingw32'", try to run "gem install rex-ole"
4.run msfconsole again, if it said "metasploit-payloads (= 1.1.13) x86-mingw32'", try to run "update config" and "update all"
5.Final step, run msfconsole, and have a good hacking~

Aditya Agrawal

unread,
Nov 29, 2016, 5:28:29 AM11/29/16
to PentestBox Forum
Well in your case you fixed by installing those gems which were missing but i am concerned over here how does those gems got missing. I have just tried running msfconsole on new installation, and it works fine.

So i suppose that during the pentestbox extraction process, some files may not have been copied or may be blocked by some antivirus or firewall.

Anyways, glad to know that it is working.

-Aditya

Geng Arthur

unread,
Nov 29, 2016, 6:16:00 AM11/29/16
to PentestBox Forum
I think so. But I checked my firewall and antivirus, it didn't delete or stop any thing during I installed pentest box.
I have a advice that Pentest Box web page should add a prompt that notes close firewall or antivirus before install.

Anyway, thank u very much, bro:)

Александр Александрович Михальченко

unread,
Oct 26, 2017, 9:13:45 AM10/26/17
to PentestBox Forum
help me, I'm on all the commands "gem install  " output:

ERROR:  Error installing .....  Ruby version >= 2.2.0.


C:\PentestBox\bin\metasploit-framework
> gem install rex-registry
ERROR
:  Error installing rex-registry:
        rex
-registry requires Ruby version >= 2.2.0.

Gaurav Nyaupane

unread,
Jan 30, 2018, 11:42:54 PM1/30/18
to PentestBox Forum
C:\Users\Silent Coder\Desktop

> msfconsole


Bundler could not find compatible versions for gem "rex-registry":
 
In Gemfile:
    metasploit
-framework x86-mingw32 was resolved to 4.12.20, which depends on
      rex
-registry x86-mingw32


Could not find gem 'rex-registry', which is required by gem 'metasploit-framework', in any of the sources.


D
:\PentestBox\bin\metasploit-framework
> gem install rex-registry
Error loading RubyGems plugin "D:/PentestBox/base/ruby/lib/ruby/gems/2.1.0/gems/yard-0.8.7.6/lib/rubygems_plugin.rb": can't modify frozen Hash (RuntimeError)
ERROR:  Error installing rex-registry:
        The last version of rex-registry (>= 0) to support your Ruby & RubyGems was 0.1.2. Try installing it with `gem install rex-registry -v 0.1.2`
        rex-registry requires Ruby version >= 2.2.0. The current ruby version is 2.1.0.


D:\PentestBox\bin\metasploit-framework
>











HOW TO FIX IT ?? 

Reply all
Reply to author
Forward
0 new messages