From:             [EMAIL PROTECTED]
Operating system: Windows 2000
PHP version:      4.1.1
PHP Bug Type:     Program Execution
Bug description:  "unable to fork" - cause & solution (well, at least for me)

in 4.0.6, popen() would just call CreateProcess() with the specified
command.

this was ok.

in 4.1.0 popen() now prepends "cmd.exe /c " (or "command.com /c " on
win9x).

the problem with this, is that many web admins will disable access for the
web apps to access cmd.exe (eg, MS's IISLockDown does this), and hence even
though the web app may have access to c:\utils\myapp.exe, a command like
exec("c:\utils\myapp.exe") now fails on 4.1.0 but works on on 4.0.6.

also, the hardcoding of cmd.exe should not be done.  it should get it from
the enviroment.

summary:

have commands that prepend the result of an enviroment lookup on "%comspec%
/c " to the front of a command

AND

have commands that dont, so that I can call exec("c:\utils\myapp.exe"); 
without having to enable access to cmd.exe

OR

any interpretation of these issues, that allow for a sensible amount of
flexibilty.

Louis Solomon
www.SteelBytes.com


-- 
Edit bug report at: http://bugs.php.net/?id=14897&edit=1


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to