From a7fda336fd92c4bd1d7122c654443c4e5ee19386 Mon Sep 17 00:00:00 2001 From: "wade@bindshell.net" Date: Fri, 30 Sep 2011 13:38:36 +0000 Subject: [PATCH] some functions prevented for security reasons git-svn-id: https://beef.googlecode.com/svn/trunk@1333 b87d56ec-f9c0-11de-8c8a-61c5e9addfc9 --- core/ruby/security.rb | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/core/ruby/security.rb b/core/ruby/security.rb index 7792048a9..111b927f3 100644 --- a/core/ruby/security.rb +++ b/core/ruby/security.rb @@ -15,7 +15,26 @@ # # @note Prevent eval from ever being used -def eval(args) - puts "For security reasons the eval method is not accepted in the Browser Exploitation Framework code base." +# def eval(args) +# puts "For security reasons the eval method is not accepted in the Browser Exploitation Framework code base." +# exit +# end + +# @note Prevent exec from ever being used +def exec(args) + puts "For security reasons the exec method is not accepted in the Browser Exploitation Framework code base." exit end + +# @note Prevent system from ever being used +def system(args) + puts "For security reasons the system method is not accepted in the Browser Exploitation Framework code base." + exit +end + +# @note Prevent Kernel.system from ever being used +def Kernel.system(args) + puts "For security reasons the Kernel.system method is not accepted in the Browser Exploitation Framework code base." + exit +end +