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

Write permission error on gem directory #1938

Closed
DeezyE opened this issue Jun 4, 2020 · 4 comments
Closed

Write permission error on gem directory #1938

DeezyE opened this issue Jun 4, 2020 · 4 comments
Assignees
Labels
Defect Good First Issue Install Kali This is for issues related to Kali beef

Comments

@DeezyE
Copy link
Contributor

DeezyE commented Jun 4, 2020

Environment

What version/revision of BeEF are you using?
0.5.0.0
On what version of Ruby?
2.7
On what browser?
n/a
On what operating system?
Kali 2020.1

Configuration

Are you using a non-default configuration?
no
Have you enabled or disabled any BeEF extensions?
no

Summary

During install I get a permissions error on the gem folder
You don't have write permissions for the /var/lib/gems/2.7.0 directory.
I suspect it's due to the Kali 2020 switch from defaulting to root user

Expected Behaviour

install script runs correctly

Actual Behaviour

...
[INFO]  Detecting Ruby environment...
[INFO]  Ruby version 2.7.1 is installed
[INFO]  Updating rubygems...
Updating rubygems-update
Fetching rubygems-update-3.1.4.gem
ERROR:  While executing gem ... (Gem::FilePermissionError)
    You don't have write permissions for the /var/lib/gems/2.7.0 directory.

Steps to Reproduce

New install of Kali 2020.1
run install script

@DeezyE DeezyE added Defect Install Good First Issue Kali This is for issues related to Kali beef labels Jun 4, 2020
@bcoles
Copy link
Collaborator

bcoles commented Jun 4, 2020

You need to root privileges to install gems (unless you're using a Ruby version management tool such as rvm or rbenv). You can gain root privileges with su or sudo.

The installer should probably be updated to use sudo.

@DeezyE
Copy link
Contributor Author

DeezyE commented Jun 8, 2020

sudo in the install script is a good idea. Will do!

@sanjeevsihag

This comment has been minimized.

@jackdwalker
Copy link
Contributor

@jcrew99 I believe this was solved in #1940. Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Defect Good First Issue Install Kali This is for issues related to Kali beef
Projects
None yet
Development

No branches or pull requests

4 participants