运行wpscan报错Could not find 'nokogiri' (~> 1.8.0)

运行wpscan报错

/usr/local/lib/site_ruby/2.7.0/rubygems/dependency.rb:313:in `to_specs': Could not find 'nokogiri' (~> 1.8.0) - did find: [nokogiri-1.10.9] (Gem::MissingSpecVersionError)
Checked in 'GEM_PATH=/root/.local/share/gem/ruby/2.7.0:/var/lib/gems/2.7.0:/usr/lib/x86_64-linux-gnu/rubygems-integration/2.7.0:/usr/share/rubygems-integration/2.7.0:/usr/share/rubygems-integration/all' , execute `gem env` for more information
    12: from /usr/bin/wpscan:23:in `<main>'
    11: from /usr/local/lib/site_ruby/2.7.0/rubygems.rb:298:in `activate_bin_path'
    10: from /usr/local/lib/site_ruby/2.7.0/rubygems.rb:298:in `synchronize'
     9: from /usr/local/lib/site_ruby/2.7.0/rubygems.rb:299:in `block in activate_bin_path'
     8: from /usr/local/lib/site_ruby/2.7.0/rubygems/specification.rb:1367:in `activate'
     7: from /usr/local/lib/site_ruby/2.7.0/rubygems/specification.rb:1385:in `activate_dependencies'
     6: from /usr/local/lib/site_ruby/2.7.0/rubygems/specification.rb:1385:in `each'
     5: from /usr/local/lib/site_ruby/2.7.0/rubygems/specification.rb:1403:in `block in activate_dependencies'
     4: from /usr/local/lib/site_ruby/2.7.0/rubygems/specification.rb:1367:in `activate'
     3: from /usr/local/lib/site_ruby/2.7.0/rubygems/specification.rb:1385:in `activate_dependencies'
     2: from /usr/local/lib/site_ruby/2.7.0/rubygems/specification.rb:1385:in `each'
     1: from /usr/local/lib/site_ruby/2.7.0/rubygems/specification.rb:1396:in `block in activate_dependencies'
/usr/local/lib/site_ruby/2.7.0/rubygems/specification.rb:1399:in `rescue in block in activate_dependencies': Could not find 'nokogiri' (~> 1.8.0) among 255 total gem(s) (Gem::MissingSpecError)
Checked in 'GEM_PATH=/root/.local/share/gem/ruby/2.7.0:/var/lib/gems/2.7.0:/usr/lib/x86_64-linux-gnu/rubygems-integration/2.7.0:/usr/share/rubygems-integration/2.7.0:/usr/share/rubygems-integration/all' at: /usr/share/rubygems-integration/all/specifications/cms_scanner-0.0.41.3.gemspec, execute `gem env` for more information

尝试过

gem install pkg-config
apt-get install libxml2-dev libxslt-dev zlib1g-dev -y
gem install nokogiri -- --use-system-libraries

但也没用,只能先卸载,再以gem方式来重装wpscan

pcat尝试过以apt方式来安装wpscan,但总会出现public_suffix的依赖冲突。

apt remove wpscan -y
apt-get autoremove -y
apt-get autoclean
hash -r
apt install ruby-dev -y
gem install wpscan

 

posted @ 2020-05-03 03:23  pcat  阅读(505)  评论(0编辑  收藏