Re: Exec() denied read on Apache (fedora core 3)

From: Date: Fri, 24 Dec 2004 14:13:37 +0000
Subject: Re: Exec() denied read on Apache (fedora core 3)
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-205142@lists.php.net to get a copy of this message
On Fri, 24 Dec 2004 12:09:51 +0000, Zia Syed <zia.chacho@gmail.com> wrote: > I've been trying to execute some system commands and print back the > output on the webpage. I found the following code to do so, however, > it is not working. > <?php > echo exec('whoami'); > ?> > > However, i tried to switch on the Safe_Mode but that wasn't any good either. > Any idea how can i get it work? I assume you're hosting with someone and they have dsiabled that function via the php.ini, I dunno.. Anyway, you might get lucky and they are using a different php.ini for the php binary. Try this from command line: php -r 'system( "whoami" );' -- Greg Donald Zend Certified Engineer http://gdconsultants.com/ http://destiney.com/

« previous php.general (#205142) next »