4 #######################################################
6 # run any (allowed) progam in the root context
8 #######################################################
10 my @allowed = ("/bin/df"); # allowed commands
20 if ($cmdline =~ /\s*(.+)\s+/) {
26 # run the program if it's executable and allowed to run
28 foreach $p (@allowed) {
34 print "fatal: '$cmdline' is not allowed to run\n";
36 print "fatal: $path either does not exist or is not executable\n";