From 264c203a7e7e4b0d07a6871fc6dbeddfba20e9e2 Mon Sep 17 00:00:00 2001 From: Brendan Coles Date: Sun, 20 Mar 2016 16:33:57 +0000 Subject: [PATCH] Change BeEF::Filters::is_valid_yes_no to be case insensitive --- core/filters/base.rb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/core/filters/base.rb b/core/filters/base.rb index df3e6ab80..2230c3a63 100644 --- a/core/filters/base.rb +++ b/core/filters/base.rb @@ -192,11 +192,9 @@ module Filters # Verify the yes and no is valid # @param [String] str String for testing # @return [Boolean] If the string is either 'yes' or 'no' - # @todo Confirm this is case insensitive def self.is_valid_yes_no?(str) return false if has_non_printable_char?(str) - return false if str !~ /^(Yes|No)$/ - return false if str.length > 200 + return false if str !~ /\A(Yes|No)\z/i true end