Wpscan: Unable to Run wpscan Ruby File

Created on 23 Mar 2016  Â·  20Comments  Â·  Source: wpscanteam/wpscan

Uploading Screenshot from 2016-03-23 17:15:30.png…
It is showing the following errors even if i installed the

sudo aptitude install libreadline5-dev libncurses5-dev

[ERROR] cannot load such file -- readline
[TIP] Try to run 'gem install readline' or 'gem install --user-install readline'. If you still get an error, Please see README file or https://github.com/wpscanteam/wpscan
pavanvadrevu@pavan-santu:~/wpscan$
please help me solve this issue thanks in advance

Most helpful comment

Thanks for the Things Finally Chased.....
Thank U @FireFart and @ethicalhack3r

All 20 comments

To enable us to help you please provide:

  1. Version of Ruby in use.
  2. Version of WPScan in use.
  3. Operating System in use.
  4. Steps taken to install WPScan.
  5. What have you already tried to fix the issue?
  6. Did you try the solution given in the 'TIP' which pasted in your comment? gem install readline

I am using Ruby ruby 2.3.0p0 (2015-12-25 revision 53290) [x86_64-linux]
Version of wpscan : installed by git seems 2.9
operating system :: Ubuntu 14.04
General steps
sudo apt-get install libcurl4-openssl-dev libxml2 libxml2-dev libxslt1-dev ruby-dev build-essential libgmp-dev
git clone https://github.com/wpscanteam/wpscan.git
cd wpscan
sudo gem install bundler && bundle install --without test

after that updated ruby to 2.3.0
yes tried to install the readline as
gem install readline'
and
'gem install --user-install readline'.

And what is the output when you try to install readline? Does it install correctly? Does it give an error?

when i tried to install with
'gem install --user-install readline'. and in other manner as gem install readline'
it is showing as
ERROR: Could not find a valid gem 'readline' (>= 0) in any repository
ERROR: Possible alternatives: deadline, redline, deadlinez, deadlink, headliner

Ah! Looks like it should be rb-readline.

Try gem install rb-readline and/or gem install --user-install rb-readline

that also i tried

And what was the output of that?

ERROR: While executing gem ... (Gem::FilePermissionError)
You don't have write permissions for the /usr/local/lib/ruby/gems/2.3.0 directory.

then i tried as the root user
now there is a path issue
WARNING: You don't have /home/pavanvadrevu/.gem/ruby/2.3.0/bin in your PATH,
gem executables will not run.

i solved that issue but setting up the path for the gem now i am again getting error with bundler
[ERROR] cannot load such file -- bundler/setup

sudo gem install bundler && bundle install --without test again i am installing bundler

Awesome! :) All working now?

Now it could not found the bundler to find that

screenshot from 2016-03-23 20 06 25

/usr/local/lib/ruby/2.3.0/rubygems/dependency.rb:319:in to_specs': Could not find 'bundler' (>= 0.a) among 5 total gem(s) (Gem::LoadError) Checked in 'GEM_PATH=/home/pavanvadrevu/.gem', executegem envfor more information from /usr/local/lib/ruby/2.3.0/rubygems/dependency.rb:328:into_spec'
from /usr/local/lib/ruby/2.3.0/rubygems/core_ext/kernel_gem.rb:65:in gem' from /usr/local/bin/bundle:22:in

'
pavanvadrevu@pavan-santu:~/wpscan$ gem env
RubyGems Environment:

  • RUBYGEMS VERSION: 2.5.1
  • RUBY VERSION: 2.3.0 (2015-12-25 patchlevel 0) [x86_64-linux]
  • INSTALLATION DIRECTORY: /home/pavanvadrevu/.gem
  • USER INSTALLATION DIRECTORY: /home/pavanvadrevu/.gem/ruby/2.3.0
  • RUBY EXECUTABLE: /usr/local/bin/ruby
  • EXECUTABLE DIRECTORY: /home/pavanvadrevu/.gem/bin
  • SPEC CACHE DIRECTORY: /home/pavanvadrevu/.gem/specs
  • SYSTEM CONFIGURATION DIRECTORY: /usr/local/etc
  • RUBYGEMS PLATFORMS:

    • ruby

    • x86_64-linux

  • GEM PATHS:

    • /home/pavanvadrevu/.gem

  • GEM CONFIGURATION:

    • :update_sources => true

    • :verbose => true

    • :backtrace => false

    • :bulk_threshold => 1000

  • REMOTE SOURCES:
  • SHELL PATH:

    • /usr/local/sbin

    • /usr/local/bin

    • /usr/sbin

    • /usr/bin

    • /sbin

    • /bin

    • /usr/games

    • /usr/local/games

    • /usr/local/bin

    • /path/to/add

trying to execute bundler it showing another errors
/usr/local/lib/ruby/2.3.0/rubygems/dependency.rb:319:in to_specs': Could not find 'bundler' (>= 0.a) among 5 total gem(s) (Gem::LoadError) Checked in 'GEM_PATH=/home/pavanvadrevu/.gem', executegem envfor more information from /usr/local/lib/ruby/2.3.0/rubygems/dependency.rb:328:into_spec'
from /usr/local/lib/ruby/2.3.0/rubygems/core_ext/kernel_gem.rb:65:in gem' from /usr/local/bin/bundle:22:in

'

@pavan4information i suggest you use the suggested RVM install method:
https://github.com/wpscanteam/wpscan#installing-with-rvm-recommended

Using this all should work without errors

When i am following the above guide lines i am getting the following error
screenshot from 2016-04-05 17 35 43
and if i am generally executing the ruby
i am getting the following error
screenshot from 2016-04-05 17 37 20

please resolve this issue as early possible bro ...
i am waiting from a long time and trying other things doesnt making to work

Run the suggested command in the output:

gpg --keyserver ....

This issue is an implementation issue not a WPScan issue. You need to learn how to debug problems by yourself, starting by reading error output.

Thanks for the Things Finally Chased.....
Thank U @FireFart and @ethicalhack3r

Was this page helpful?
0 / 5 - 0 ratings

Related issues

CoreISP picture CoreISP  Â·  7Comments

erwanlr picture erwanlr  Â·  6Comments

jamezlee picture jamezlee  Â·  11Comments

MLubinski picture MLubinski  Â·  10Comments

cryptodoom picture cryptodoom  Â·  10Comments