From 0a5a6dfd0b89aecb70dfa4d8cf26ad7f5c4edc35 Mon Sep 17 00:00:00 2001 From: Olivier Blin Date: Mon, 1 Nov 2010 22:47:39 +0000 Subject: check args in tar as well --- iurt_root_command | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'iurt_root_command') diff --git a/iurt_root_command b/iurt_root_command index de21741..b852be1 100755 --- a/iurt_root_command +++ b/iurt_root_command @@ -329,6 +329,10 @@ sub check_tar_authorized { sub tar { my ($_run, $_opt, $file, $dir) = @_; + if (!$file || !$dir) { + plog('FAIL', "tar: missing arguments"); + return; + } check_tar_authorized($file, $dir) or return; return !system('tar', 'caf', $file, '-C', $dir, '.'); } -- cgit v1.2.1