I am executing a PHP script as a cgi-script on Windows XP, web server is Apache 2.2 which is encrypted using phtmlenc(). This is opening a blank DOS prompt (cmd.exe window) during execution.
This the test script test.php I have placed my script inside cgi-bin directory:
#! C:/PHP/bin
exec(WHOAMI);
When I launch the script through Internet Explorer by typing localhost/cgi-bin/test.php
I can see a DOS window popup.
phtmldec() and hence I cannot change the actual exec() callYou cannot hide the window because that is under the control of the operating system, not PHP or Apache. And since whoami is a console application it creates a console when run.
By the way, 'WHOAMI' should be in quotes.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With