Updating filters (and associated tests) to allow #40 to work on *nix hosts with extra chars in the plugins string
git-svn-id: https://beef.googlecode.com/svn/trunk@591 b87d56ec-f9c0-11de-8c8a-61c5e9addfc9
This commit is contained in:
@@ -32,7 +32,6 @@ module BeEF
|
||||
|
||||
# check if valid command module datastore value
|
||||
def self.is_valid_commmamd_module_datastore_param?(str)
|
||||
return false if not BeEF::Filter.is_non_empty_string?(str)
|
||||
return false if BeEF::Filter.has_null?(str)
|
||||
return false if BeEF::Filter.has_non_printable_char?(str)
|
||||
true
|
||||
@@ -41,7 +40,7 @@ module BeEF
|
||||
# check for word and some punc chars
|
||||
def self.has_valid_key_chars?(str)
|
||||
return false if not BeEF::Filter.is_non_empty_string?(str)
|
||||
(str =~ /[^\w_-]/).nil?
|
||||
(str =~ /[^\w\d\s()-.,;_\302\256]/).nil?
|
||||
end
|
||||
|
||||
# check for word and underscore chars
|
||||
|
||||
Reference in New Issue
Block a user