From 1386e3e1c31cf4593cb376dcfb49218e6b5e4716 Mon Sep 17 00:00:00 2001 From: Josh Date: Mon, 27 Apr 2020 20:51:29 -0700 Subject: [PATCH] change debug method --- .../handlers/browser_details_handler_spec.rb | 8 ++++---- .../websocket_hooked_browser_spec.rb | 19 ++++++++++--------- 2 files changed, 14 insertions(+), 13 deletions(-) diff --git a/spec/beef/core/main/handlers/browser_details_handler_spec.rb b/spec/beef/core/main/handlers/browser_details_handler_spec.rb index 187f83237..49731d7f1 100644 --- a/spec/beef/core/main/handlers/browser_details_handler_spec.rb +++ b/spec/beef/core/main/handlers/browser_details_handler_spec.rb @@ -12,13 +12,13 @@ require_relative '../../../../support/beef_test' RSpec.describe 'Browser Details Handler', :run_on_browserstack => true do before(:all) do @config = BeEF::Core::Configuration.instance - puts "This is the /n #@config " + p "This is the /n #@config " @config.set('beef.credentials.user', "beef") @config.set('beef.credentials.passwd', "beef") @username = @config.get('beef.credentials.user') - puts "This is the /n #@username " + p "This is the /n #@username " @password = @config.get('beef.credentials.passwd') - puts "This is the /n #@password " + p "This is the /n #@password " # Load BeEF extensions and modules # Always load Extensions, as previous changes to the config from other tests may affect # whether or not this test passes. @@ -30,8 +30,8 @@ RSpec.describe 'Browser Details Handler', :run_on_browserstack => true do if @config.get('beef.module').nil? print_info "Loading in BeEF::Modules" BeEF::Modules.load - sleep 2 + p BeEF::Modules.load else print_info "Modules already loaded" end diff --git a/spec/beef/extensions/websocket_hooked_browser_spec.rb b/spec/beef/extensions/websocket_hooked_browser_spec.rb index 93c0a5de0..e2438e8b0 100644 --- a/spec/beef/extensions/websocket_hooked_browser_spec.rb +++ b/spec/beef/extensions/websocket_hooked_browser_spec.rb @@ -15,16 +15,16 @@ require 'websocket-client-simple' RSpec.describe 'BeEF WebSockets: Browser Hooking', :run_on_browserstack => true do before(:all) do @config = BeEF::Core::Configuration.instance - puts "This is the /n #@config " + p "This is the /n #@config " @secure_port = @config.get('beef.http.websocket.secure_port') - puts "This is the /n #@secure_port" + p "This is the /n #@secure_port" @config.set('beef.http.websocket.secure', true) @config.set('beef.http.websocket.enable', true) #set config parameters @username = @config.get('beef.credentials.user') - puts "This is the /n #@username " + p "This is the /n #@username " @password = @config.get('beef.credentials.passwd') - puts "This is the /n #@password " + p "This is the /n #@password " # Load BeEF extensions and modules # Always load Extensions, as previous changes to the config from other tests may affect @@ -36,12 +36,13 @@ RSpec.describe 'BeEF WebSockets: Browser Hooking', :run_on_browserstack => true # Check if modules already loaded. No need to reload. if @config.get('beef.module').nil? print_info "Loading in BeEF::Modules" - BeEF::Modules.load + BeEF::Modules.load + sleep 2 + p BeEF::Modules.load - sleep 2 - else - print_info "Modules already loaded" - end + else + print_info "Modules already loaded" + end # Grab DB file and regenerate if requested print_info "Loading database"