Merge "executor: block stat get_mime on localhost"

This commit is contained in:
Zuul 2018-01-24 00:38:28 +00:00 committed by Gerrit Code Review
commit 527e03ca94
1 changed files with 2 additions and 0 deletions

View File

@ -63,6 +63,8 @@ class ActionModule(normal.ActionModule):
Block any access of files outside the zuul work dir.
'''
if self._task.args.get('get_mime') is not None:
raise AnsibleError("get_mime on localhost is forbidden")
paths._fail_if_unsafe(self._task.args['path'])
def handle_file(self):