0

I'm trying to run a Perl script using:

$var = null;
system(PATH_PERL . 'script.pl', $var);
var_dump($var);

However, I'm getting this error:

Warning: system() has been disabled for security reasons [...]

The complete list of disabled functions (with ini_get('disable_functions')):

system, system_exec, shell, shell_exec, exec, passthru, escapeshellarg, escapeshellcmd, proc_close, proc_open, ini_alter, popen, show_source, enable _dl, dl

Is there any way to execute a Perl script when these functions are disabled?

1 Answers1

1

There is no way to execute them by shell; all ways to execute shell commands in PHP are disabled. (execpt interpreting perl in PHP (what makes no sense I think...; then you also can directly translate perl to php))

bwoebi
  • 23,637
  • 5
  • 58
  • 79
  • @CamilStaps Which host do you use? – bwoebi Apr 12 '13 at 10:33
  • [Neostrada](http://neostrada.nl), but it's Dutch. They're pretty soon with support questions and don't care about installing pecl and such if you ask for it, so perhaps... –  Apr 12 '13 at 10:35
  • @CamilStaps I don't think they'll allow it, as it is the only way (without chrooting and having different apaches etc) to prevent users to see other users data on the same server ;) – bwoebi Apr 12 '13 at 10:38
  • Okay, well we'll see :) worth a try –  Apr 12 '13 at 10:40
  • For reference: fortunately, there was a PHP version of the script already. That's an option for one too thus (it's basically the same as translating of course, but without the work). –  Apr 12 '13 at 11:12