Hey,

I've noticed that we use php_Exec for the following php functions:
exec, system, passthru and a couple of functions in vpopmail.

But we bypass php_Exec for popen, shell_exec (backticks).

The difference between using php_Exec and not using it, apart
from the various modes of operation in php_Exec, is that php_Exec
does some additional sanity/security checks in safe_mode.

This difference only really affects the PHP popen() function.
Should it be doing the same checks as php_Exec?

The reason that I am looking at this stuff is that I am now toying
with the idea of a "process stream" that will effectively be the same
as a popen()ed FILE * but will allow both reading and writing to/from
the process.

It would be implemented by manually creating a pipe for stdin and
another for stdout and setting them up for the exec'd process.
Under windows it's a slightly different story but I do have some
code laying around that can be used for this purpose.

Comments anyone?

--Wez.





-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to