wpscan icon indicating copy to clipboard operation
wpscan copied to clipboard

cannot load such file -- json

Open PabloMartinMoreno opened this issue 2 years ago • 5 comments

I can't run wpscan; I'm getting the following error:

/opt/wpscan/vendor/bundle/ruby/3.0.0/gems/activesupport-6.1.7.6/lib/active_support/core_ext/object/json.rb:4:inrequire': cannot load such file -- json (LoadError) from /opt/wpscan/vendor/bundle/ruby/3.0.0/gems/activesupport-6.1.7.6/lib/active_support/core_ext/object/json.rb:4:in <top (required)>' from /opt/wpscan/vendor/bundle/ruby/3.0.0/gems/activesupport-6.1.7.6/lib/active_support/core_ext/object.rb:13:in require' from /opt/wpscan/vendor/bundle/ruby/3.0.0/gems/activesupport-6.1.7.6/lib/active_support/core_ext/object.rb:13:in <top (required)>' from /opt/wpscan/vendor/bundle/ruby/3.0.0/gems/activesupport-6.1.7.6/lib/active_support/core_ext.rb:4:in require' from /opt/wpscan/vendor/bundle/ruby/3.0.0/gems/activesupport-6.1.7.6/lib/active_support/core_ext.rb:4:in block in <top (required)>' from /opt/wpscan/vendor/bundle/ruby/3.0.0/gems/activesupport-6.1.7.6/lib/active_support/core_ext.rb:3:in each' from /opt/wpscan/vendor/bundle/ruby/3.0.0/gems/activesupport-6.1.7.6/lib/active_support/core_ext.rb:3:in <top (required)>' from /opt/wpscan/vendor/bundle/ruby/3.0.0/gems/activesupport-6.1.7.6/lib/active_support/all.rb:5:in require' from /opt/wpscan/vendor/bundle/ruby/3.0.0/gems/activesupport-6.1.7.6/lib/active_support/all.rb:5:in <top (required)>' from /opt/wpscan/lib/wpscan.rb:7:in require' from /opt/wpscan/lib/wpscan.rb:7:in <top (required)>' from /opt/wpscan/bin/wpscan:4:in require' from /opt/wpscan/bin/wpscan:4:in <main>'

I'm using the latest version of wpscan and ruby-json 2.7.1-1, which seems to be causing the error. I'm using Arch Linux.

PabloMartinMoreno avatar Apr 12 '24 16:04 PabloMartinMoreno

same issue in arch linux. Works on debian

0xRahim avatar Apr 15 '24 16:04 0xRahim

Yeah Same for me in Arch, tried wpsan-git as well but same error again. Also tried installation of all gems mentioned in error but no luck.

uhtred-X avatar Apr 17 '24 15:04 uhtred-X

I'm also attempting this on Arch for the first time. I tried running gem install wpscan and noticed an error about the following folder needing to be part of my PATH or gem executables will not run: /home/grey0ut/.local/share/gem/ruby/3.0.0/bin
After appending that to my PATH variable I am now able to run wpscan without the above error. Edit to add: from the Arch wiki on Ruby https://wiki.archlinux.org/title/Ruby#Configuration

grey0ut avatar May 07 '24 18:05 grey0ut

I face the same issue on Arch. Works fine once installed with gem install

Grelo4ka avatar May 14 '24 14:05 Grelo4ka

Yeah with 'gem install wpscan' things are working good now.

uhtred-X avatar May 20 '24 17:05 uhtred-X

The problem is still there when installing wpscan from Arch Linux repos

Grelo4ka avatar Jan 30 '25 12:01 Grelo4ka

That's something you will have to check with Arch linux by opening an issue on their side

erwanlr avatar Jan 30 '25 12:01 erwanlr