Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wpscan --update renders error after upgrade from Ubuntu 20.04 to Ubuntu 22.04. /usr/bin/ruby2.7: bad interpreter: No such file or directory #1835

Open
Danrancan opened this issue Mar 20, 2024 · 1 comment

Comments

@Danrancan
Copy link

Danrancan commented Mar 20, 2024

Subject of the issue

I just upgraded from Ubuntu Server 20.04 to Ubuntu Server 22.04.
After the upgrade I tried updating my wpscan version with wpscan --update but it gives me the following errors:

wpscan --update
bash: /usr/local/bin/wpscan: /usr/bin/ruby2.7: bad interpreter: No such file or directory

wpscan -v does the same thing:

wpscan -v
bash: /usr/local/bin/wpscan: /usr/bin/ruby2.7: bad interpreter: No such file or directory

Your environment

  • Version of WPScan: Latest version from Ubuntu 20.04, otherwise unkown because wpscan -v doesn't work.
  • Version of Ruby: ruby 3.0.2p107 (2021-07-07 revision 0db68f0233) [aarch64-linux-gnu]
  • Operating System (OS): Ubuntu Server 22.04.4 LTS (Jammy Jellyfish)

Steps to reproduce

Just upgrade from Ubuntu 20.04 to Ubuntu 22.04. Then run wpscan --update or wpscan -v.

Expected behavior

if wpscan --update, then wpscan should update itself properly, or if running wpscan -v, it should show it's version.

Actual behavior

wpscan -v
bash: /usr/local/bin/wpscan: /usr/bin/ruby2.7: bad interpreter: No such file or directory
wpscan --update
bash: /usr/local/bin/wpscan: /usr/bin/ruby2.7: bad interpreter: No such file or directory

What have you already tried

I havent tried anything. I just wanted to report the issue right away so that I didn't make any mistakes fixing it by myself. Hopefully I get some fixes from this post.

  • Update WPScan to the latest version [ Can't do that]
  • Update Ruby to the latest version [YES: ruby/jammy,now 1:3.0~exp1, ruby 3.0.2p107 (2021-07-07 revision 0db68f0233) [aarch64-linux-gnu]]
  • Ensure you can reach the target site using cURL [ Dont know what this means]
  • Proxied WPScan through a HTTP proxy to view the raw traffic [ No, Don't know how to do this]
  • Ensure you are using a supported Operating System (Linux and macOS) [Fairly certain Ubuntu 22.04 is supported ]

What can I do to fix this?

Answers needed....

@Danrancan
Copy link
Author

Now it's working. I'm not positive becuse I for document the solution to this issue, but if my memory is correct, I just downloaded Ruby again. Now I have ruby 2.0.2p107, and things are working. I think during my Ubuntu 20 upgrade to Ubuntu 2204, The upgrade removed th ruby 2.7 packages as I think it's deprecated with Ubuntu 22.04. So basically, If I remember correctly, I just installed a modern version of Ruby in Ubuntu 22.04, and this error went away. Everything seems to be working correctly again. Maybe this post will help others.

Thanks.
Dan

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant