Closed thegreatdayne closed 2 years ago
Link goes nowhere and you posted no logs either, I'll close this but feel free to edit the issue with more information and reopen.
I don't understand why the link goes nowhere but I'll re-add it. I also am not sure what you mean about there being no logs... Did the screenshots not show?
Here is copy and pasted direct from the error report (everything that was in the screenshots);
-
Errno::EACCES: Permission denied @ rb_sysopen - /var/lib/gems/3.0.0/cache/fiber-local-1.0.0.gem
/usr/local/lib/site_ruby/3.0.0/rubygems/package/file_source.rb:29:in `initialize'
/usr/local/lib/site_ruby/3.0.0/rubygems/package/file_source.rb:29:in `open'
/usr/local/lib/site_ruby/3.0.0/rubygems/package/file_source.rb:29:in `with_read_io'
/usr/local/lib/site_ruby/3.0.0/rubygems/package.rb:593:in `verify'
/usr/local/lib/site_ruby/3.0.0/rubygems/package.rb:574:in `spec'
/usr/share/rubygems-integration/all/gems/bundler-2.3.5/lib/bundler/rubygems_integration.rb:221:in `spec_from_gem'
/usr/share/rubygems-integration/all/gems/bundler-2.3.5/lib/bundler/source/rubygems.rb:167:in `install'
/usr/share/rubygems-integration/all/gems/bundler-2.3.5/lib/bundler/installer/gem_installer.rb:54:in `install'
/usr/share/rubygems-integration/all/gems/bundler-2.3.5/lib/bundler/installer/gem_installer.rb:16:in `install_from_spec'
/usr/share/rubygems-integration/all/gems/bundler-2.3.5/lib/bundler/installer/parallel_installer.rb:186:in `do_install'
/usr/share/rubygems-integration/all/gems/bundler-2.3.5/lib/bundler/installer/parallel_installer.rb:177:in `block in worker_pool'
/usr/share/rubygems-integration/all/gems/bundler-2.3.5/lib/bundler/worker.rb:62:in `apply_func'
/usr/share/rubygems-integration/all/gems/bundler-2.3.5/lib/bundler/worker.rb:57:in `block in process_queue'
/usr/share/rubygems-integration/all/gems/bundler-2.3.5/lib/bundler/worker.rb:54:in `loop'
/usr/share/rubygems-integration/all/gems/bundler-2.3.5/lib/bundler/worker.rb:54:in `process_queue'
/usr/share/rubygems-integration/all/gems/bundler-2.3.5/lib/bundler/worker.rb:91:in `block (2 levels) in create_threads'
Bundler 2.3.5
Platforms ruby, aarch64-linux
Ruby 3.0.3p157 (2021-11-24 revision 3fb7d2cadc18472ec107b14234933b017a33c14d) [aarch64-linux-gnu]
Full Path /usr/bin/ruby3.0
Config Dir /etc
RubyGems 3.4.0.dev
Gem Home /var/lib/gems/3.0.0
Gem Path /home/kali/.gem/ruby/3.0.0:/var/lib/gems/3.0.0:/usr/local/lib/ruby/gems/3.0.0:/usr/lib/ruby/gems/3.0.0:/usr/lib/aarch64-linux-gnu/ruby/gems/3.0.0:/usr/share/rubygems-integration/3.0.0:/usr/share/rubygems-integration/all:/usr/lib/aarch64-linux-gnu/rubygems-integration/3.0.0
User Home /home/kali
User Path /home/kali/.gem/ruby/3.0.0
Bin Dir /usr/local/bin
OpenSSL
Compiled OpenSSL 1.1.1m 14 Dec 2021
Loaded OpenSSL 1.1.1n 15 Mar 2022
Cert File /usr/lib/ssl/cert.pem
Cert Dir /usr/lib/ssl/certs
Tools
Git 2.35.1
RVM rvm 1.29.12-next (master) by Michal Papis, Piotr Kuczynski, Wayne E. Seguin [https://rvm.io]
rbenv rbenv 1.1.2
chruby not installed
Built At 2022-04-10
Git SHA unknown
Released Version false
without
Set for your local app (/home/kali/Desktop/beef/.bundle/config): [:development, :test]
# BeEF's Gemfile
#
# Copyright (c) 2006-2022 Wade Alcorn - wade@bindshell.net
# Browser Exploitation Framework (BeEF) - http://beefproject.com
# See the file 'doc/COPYING' for copying permission
#
#gem 'simplecov', require: false, group: :test
gem 'eventmachine'
gem 'thin'
gem 'sinatra', '>= 2.0.2'
gem 'rack', '>= 2.2.3'
gem 'rack-protection', '>= 2.0.0'
gem 'em-websocket' # WebSocket support
gem 'uglifier', '>= 2.7.2'
gem 'mime-types'
gem 'execjs'
gem 'ansi'
gem 'term-ansicolor', :require => 'term/ansicolor'
gem 'json'
gem 'rubyzip', '>= 1.2.2'
gem 'espeak-ruby', '>= 1.0.4' # Text-to-Voice
gem 'rake', '>= 12.3.3'
gem 'otr-activerecord', '>= 1.4.2'
gem 'sqlite3'
gem 'rubocop', '~> 1.26.0', require: false
# Geolocation support
group :geoip do
gem 'maxmind-db'
end
gem 'parseconfig'
gem 'erubis'
# Metasploit Integration extension
group :ext_msf do
gem 'msfrpc-client'
gem 'xmlrpc'
end
# Notifications extension
group :ext_notifications do
# Pushover
gem 'rushover'
# Slack
gem 'slack-notifier'
# Twitter
gem 'twitter', '>= 5.0.0'
end
# DNS extension
group :ext_dns do
gem 'async-dns'
end
# QRcode extension
group :ext_qrcode do
gem 'qr4r'
end
# For running unit tests
group :test do
gem 'test-unit'
gem 'test-unit-full'
gem 'rspec'
gem 'rdoc'
# curb gem requires curl libraries
# sudo apt-get install libcurl4-openssl-dev
gem 'curb'
# selenium-webdriver 3.x is incompatible with Firefox version 48 and prior
# gem 'selenium' # Requires old version of selenium which is no longer available
gem 'geckodriver-helper'
gem 'selenium-webdriver'
# nokogirl is needed by capybara which may require one of the below commands
# sudo apt-get install libxslt-dev libxml2-dev
# sudo port install libxml2 libxslt
gem 'capybara'
# RESTful API tests/generic command module tests
gem 'rest-client', '>= 2.0.1'
gem 'irb'
gem 'pry-byebug'
gem "websocket-client-simple", "~> 0.5.1"
gem "browserstack-local", "~> 1.3"
end
source 'https://rubygems.org'
GEM
remote: https://rubygems.org/
specs:
activemodel (7.0.2.2)
activesupport (= 7.0.2.2)
activerecord (7.0.2.2)
activemodel (= 7.0.2.2)
activesupport (= 7.0.2.2)
activesupport (7.0.2.2)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 1.6, < 2)
minitest (>= 5.1)
tzinfo (~> 2.0)
addressable (2.8.0)
public_suffix (>= 2.0.2, < 5.0)
ansi (1.5.0)
archive-zip (0.12.0)
io-like (~> 0.3.0)
ast (2.4.2)
async (1.30.1)
console (~> 1.10)
nio4r (~> 2.3)
timers (~> 4.1)
async-dns (1.3.0)
async-io (~> 1.15)
async-io (1.32.2)
async
browserstack-local (1.3.0)
buftok (0.2.0)
byebug (11.1.3)
capybara (3.36.0)
addressable
matrix
mini_mime (>= 0.1.3)
nokogiri (~> 1.8)
rack (>= 1.6.0)
rack-test (>= 0.6.3)
regexp_parser (>= 1.5, < 3.0)
xpath (~> 3.2)
childprocess (4.1.0)
coderay (1.1.3)
concurrent-ruby (1.1.9)
console (1.13.1)
fiber-local
curb (1.0.0)
daemons (1.4.1)
diff-lcs (1.5.0)
domain_name (0.5.20190701)
unf (>= 0.0.5, < 1.0.0)
em-websocket (0.5.3)
eventmachine (>= 0.12.9)
http_parser.rb (~> 0)
equalizer (0.0.11)
erubis (2.7.0)
espeak-ruby (1.0.5)
event_emitter (0.2.6)
eventmachine (1.2.7)
execjs (2.8.1)
ffi (1.15.4)
ffi-compiler (1.0.1)
ffi (>= 1.0.0)
rake
fiber-local (1.0.0)
geckodriver-helper (0.24.0)
archive-zip (~> 0.7)
hashie (5.0.0)
hashie-forbidden_attributes (0.1.1)
hashie (>= 3.0)
http (4.4.1)
addressable (~> 2.3)
http-cookie (~> 1.0)
http-form_data (~> 2.2)
http-parser (~> 1.2.0)
http-accept (1.7.0)
http-cookie (1.0.4)
domain_name (~> 0.5)
http-form_data (2.3.0)
http-parser (1.2.3)
ffi-compiler (>= 1.0, < 2.0)
http_parser.rb (0.6.0)
i18n (1.10.0)
concurrent-ruby (~> 1.0)
io-console (0.5.9)
io-like (0.3.1)
irb (1.4.1)
reline (>= 0.3.0)
json (2.6.1)
matrix (0.4.2)
maxmind-db (1.1.1)
memoizable (0.4.2)
thread_safe (~> 0.3, >= 0.3.1)
method_source (1.0.0)
mime-types (3.4.1)
mime-types-data (~> 3.2015)
mime-types-data (3.2021.1115)
mini_mime (1.1.2)
mini_portile2 (2.8.0)
minitest (5.15.0)
mojo_magick (0.6.6)
msfrpc-client (1.1.2)
msgpack (~> 1)
msgpack (1.4.2)
multipart-post (2.1.1)
mustermann (1.1.1)
ruby2_keywords (~> 0.0.1)
naught (1.1.0)
netrc (0.11.0)
nio4r (2.5.8)
nokogiri (1.13.3)
mini_portile2 (~> 2.8.0)
racc (~> 1.4)
otr-activerecord (2.1.1)
activerecord (>= 4.0, < 7.1)
hashie-forbidden_attributes (~> 0.1)
parallel (1.21.0)
parseconfig (1.1.2)
parser (3.1.1.0)
ast (~> 2.4.1)
power_assert (2.0.1)
pry (0.13.1)
coderay (~> 1.1)
method_source (~> 1.0)
pry-byebug (3.9.0)
byebug (~> 11.0)
pry (~> 0.13.0)
psych (4.0.3)
stringio
public_suffix (4.0.6)
qr4r (0.6.1)
mojo_magick (~> 0.6.5)
rqrcode_core (~> 0.1)
racc (1.6.0)
rack (2.2.3)
rack-protection (2.2.0)
rack
rack-test (1.1.0)
rack (>= 1.0, < 3)
rainbow (3.1.1)
rake (13.0.6)
rdoc (6.4.0)
psych (>= 4.0.0)
regexp_parser (2.2.1)
reline (0.3.0)
io-console (~> 0.5)
rest-client (2.1.0)
http-accept (>= 1.7.0, < 2.0)
http-cookie (>= 1.0.2, < 2.0)
mime-types (>= 1.16, < 4.0)
netrc (~> 0.8)
rexml (3.2.5)
rqrcode_core (0.2.0)
rr (3.0.7)
rspec (3.11.0)
rspec-core (~> 3.11.0)
rspec-expectations (~> 3.11.0)
rspec-mocks (~> 3.11.0)
rspec-core (3.11.0)
rspec-support (~> 3.11.0)
rspec-expectations (3.11.0)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.11.0)
rspec-mocks (3.11.0)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.11.0)
rspec-support (3.11.0)
rubocop (1.26.0)
parallel (~> 1.10)
parser (>= 3.1.0.0)
rainbow (>= 2.2.2, < 4.0)
regexp_parser (>= 1.8, < 3.0)
rexml
rubocop-ast (>= 1.16.0, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 1.4.0, < 3.0)
rubocop-ast (1.16.0)
parser (>= 3.1.1.0)
ruby-progressbar (1.11.0)
ruby2_keywords (0.0.5)
rubyzip (2.3.2)
rushover (0.3.0)
json
rest-client
selenium-webdriver (4.1.0)
childprocess (>= 0.5, < 5.0)
rexml (~> 3.2, >= 3.2.5)
rubyzip (>= 1.2.2)
simple_oauth (0.3.1)
sinatra (2.2.0)
mustermann (~> 1.0)
rack (~> 2.2)
rack-protection (= 2.2.0)
tilt (~> 2.0)
slack-notifier (2.4.0)
sqlite3 (1.4.2)
stringio (3.0.1)
sync (0.5.0)
term-ansicolor (1.7.1)
tins (~> 1.0)
test-unit (3.5.3)
power_assert
test-unit-context (0.5.1)
test-unit (>= 2.4.0)
test-unit-full (0.0.5)
test-unit
test-unit-context
test-unit-notify
test-unit-rr
test-unit-runner-tap
test-unit-notify (1.0.4)
test-unit (>= 2.4.9)
test-unit-rr (1.0.5)
rr (>= 1.1.1)
test-unit (>= 2.5.2)
test-unit-runner-tap (1.1.2)
test-unit
thin (1.8.1)
daemons (~> 1.0, >= 1.0.9)
eventmachine (~> 1.0, >= 1.0.4)
rack (>= 1, < 3)
thread_safe (0.3.6)
tilt (2.0.10)
timers (4.3.3)
tins (1.29.1)
sync
twitter (7.0.0)
addressable (~> 2.3)
buftok (~> 0.2.0)
equalizer (~> 0.0.11)
http (~> 4.0)
http-form_data (~> 2.0)
http_parser.rb (~> 0.6.0)
memoizable (~> 0.4.0)
multipart-post (~> 2.0)
naught (~> 1.0)
simple_oauth (~> 0.3.0)
tzinfo (2.0.4)
concurrent-ruby (~> 1.0)
uglifier (4.2.0)
execjs (>= 0.3.0, < 3)
unf (0.1.4)
unf_ext
unf_ext (0.0.7.7)
unicode-display_width (2.1.0)
webrick (1.7.0)
websocket (1.2.9)
websocket-client-simple (0.5.1)
event_emitter
websocket
xmlrpc (0.3.2)
webrick
xpath (3.2.0)
nokogiri (~> 1.8)
PLATFORMS
ruby
DEPENDENCIES
ansi
async-dns
browserstack-local (~> 1.3)
capybara
curb
em-websocket
erubis
espeak-ruby (>= 1.0.4)
eventmachine
execjs
geckodriver-helper
irb
json
maxmind-db
mime-types
msfrpc-client
otr-activerecord (>= 1.4.2)
parseconfig
pry-byebug
qr4r
rack (>= 2.2.3)
rack-protection (>= 2.0.0)
rake (>= 12.3.3)
rdoc
rest-client (>= 2.0.1)
rspec
rubocop (~> 1.26.0)
rubyzip (>= 1.2.2)
rushover
selenium-webdriver
sinatra (>= 2.0.2)
slack-notifier
sqlite3
term-ansicolor
test-unit
test-unit-full
thin
twitter (>= 5.0.0)
uglifier (>= 2.7.2)
websocket-client-simple (~> 0.5.1)
xmlrpc
BUNDLED WITH
2.1.4
--- TEMPLATE END ----------------------------------------------------------------
Unfortunately, an unexpected error occurred, and Bundler cannot continue.
First, try this link to see if there are any existing issue reports for this error: https://github.com/rubygems/rubygems/search?q=Permission+denied+%40+rb_sysopen+-+%2Fvar%2Flib%2Fgems%2F3.0.0%2Fcache%2Ffiber-local-1.0.0.gem&type=Issues
If there aren't any reports for this error yet, please fill in the new issue form located at https://github.com/rubygems/rubygems/issues/new?labels=Bundler&template=bundler-related-issue.md, and copy and paste the report template above in there.
Ok, what do I need to run on my computer to reproduce the error?
It seems it you're trying to install gems to system directory (probably because of using Ruby installed by the system). You need to run bundle install
using sudo or specify custom path for gems. For example bundle install --path vendor/bundle
to install gems to vendor/bundle
directory.
@simi
The bundle install --path vendor/bundle
command worked for doing the gems install. It ran without error, thank you.
Unfortunately I still have the same problem as was in the linked thread https://github.com/beefproject/beef/issues/2377
I'll re-post the output here so no one has to go back and forth (everything that happens to be in the above link).
This is the output from using ./install
after making sure the gems are up to date;
-- [ BeEF Installer ] --
[WARNING] This script will install BeEF and its required dependencies (including operating system packages).
Are you sure you wish to continue (Y/n)? y
[INFO] Detecting OS...
[INFO] Operating System: Linux
[INFO] Launching Linux install...
[INFO] Detecting Linux OS distribution...
[INFO] OS Distribution: Debian
[INFO] Installing Debian prerequisite packages...
Hit:1 http://kali.download/kali kali-rolling InRelease
Hit:2 http://http.re4son-kernel.com/re4son kali-pi InRelease
Reading package lists... Done
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Note, selecting 'libreadline-dev' instead of 'libreadline6-dev'
autoconf is already the newest version (2.71-2).
automake is already the newest version (1:1.16.5-1.3).
bison is already the newest version (2:3.8.2+dfsg-1).
build-essential is already the newest version (12.9).
curl is already the newest version (7.82.0-2).
git is already the newest version (1:2.35.1-1).
libc6-dev is already the newest version (2.33-6).
libcurl4-openssl-dev is already the newest version (7.82.0-2).
libncurses5-dev is already the newest version (6.3-2).
libreadline-dev is already the newest version (8.1.2-1).
libsqlite3-0 is already the newest version (3.38.2-1).
libsqlite3-dev is already the newest version (3.38.2-1).
libssl-dev is already the newest version (1.1.1n-1).
libtool is already the newest version (2.4.6-15).
libxml2-dev is already the newest version (2.9.13+dfsg-1).
libxslt1-dev is already the newest version (1.1.34-4).
libyaml-dev is already the newest version (0.2.2-1).
nodejs is already the newest version (12.22.10~dfsg-2).
openssl is already the newest version (1.1.1n-1).
sqlite3 is already the newest version (3.38.2-1).
zlib1g is already the newest version (1:1.2.11.dfsg-2).
zlib1g-dev is already the newest version (1:1.2.11.dfsg-2).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
[INFO] Ruby package Manager exists - Ruby install skipped
[INFO] Detecting Ruby environment...
[INFO] Ruby version 2.7.4@beef is installed
./install: line 173: RUBY_VERSION: command not found
[INFO] Updating rubygems...
ERROR: Your RubyGems was installed trough APT, and upgrading it through RubyGems
itself is unsupported. If you really need the latest version of RubyGems (tip:
you usually don't), then you need to install RubyGems (and Ruby) manually,
maybe using tools like ruby-install, rvm, etc.
It seems that it does not see that I have RubyGems installed. To make it known, I think I need to change the code in the installer due to the machine being a Raspberry Pi 4b but I'm not sure what to change for it to recognize that RubyGems is in fact installed. I can get into the installer script using VIM. Any idea which portion of and what to change in the script?
@thegreatdayne I think you can skip that updated. Install script seems to be part of https://github.com/beefproject/beef/blob/1c395a315305e9e83a2826ece5625a5f11073703/install#L195. Feel free to open an issue in there. It is problem not related to RubyGems. I think we can close this issue since your original problem was solved.
Alright, thank you for your help in fixing the issue which was relevant here. I'll start another thread in the link you provided. Thanks again and I hope you have a great day!
I was having the same issue as this thread https://github.com/beefproject/beef/issues/2377 . The output looked exactly the same. I tried the remedy of commands listed but received a generated error report after executing the final
bundle install
command. I will attach screenshots of the generated report but I warn you there are 14 of them as they includebundle env
output.![Uploading bundle_install _error.png…]()
I tried upgrading rubygems & bundler.
I have tried with both Ruby v2.7 and Ruby v3, cloned and curled from beefproject on github.