Add support for compound functions in client_acl_blacklist

This commit is contained in:
Thomas Jackson 2013-08-27 15:05:37 -07:00
parent 0bc4d423bf
commit 6e764f5ce5

View File

@ -1989,9 +1989,16 @@ class ClearFuncs(object):
# check if the cmd is blacklisted
for module_re in self.opts['client_acl_blacklist'].get('modules', []):
if re.match(module_re, clear_load['fun']):
good = False
break
# if this is a regular command, its a single function
if type(clear_load['fun']) == str:
funs_to_check = [ clear_load['fun'] ]
# if this a compound function
else:
funs_to_check = clear_load['fun']
for func in funs_to_check:
if re.match(module_re, fun):
good = False
break
if good is False:
log.error(