FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » problems with exec()
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: problems with exec() [message #177706 is a reply to message #177704] Sun, 15 April 2012 22:16 Go to previous messageGo to previous message
M. Strobel is currently offline  M. Strobel
Messages: 386
Registered: December 2011
Karma:
Senior Member
Am 15.04.2012 19:43, schrieb J.O. Aho:
> 7segment wrote:
>> Hi.
>>
>> I have an interesting problem and I cannot figure out what the problem
>> might be.
>>
>> This does not produce any output:
>>
>> $response = exec('ifconfig');
>> echo $response;
>>
>> Although when I try other commands, I get a response on the screen. So I
>> don't get what's so special about ifconfig.
>>
>> Could anyone help please?
>
> ifconfig usually residence in /sbin (some GNU/Linux distribution are in the migration
> path of moving it to /usr/sbin), this directory is never in a normal users or a
> daemon users $PATH, so you need to give the whole path to this binary to be able to
> run it.
>
> By default the file is executional by all users, but someone may have changed
> permissions or setup ACL rules with for example SELinux.
>

I can tell that on opensuse it it not executable by normal users.

/Str.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: $this->delimiter in php explode
Next Topic: We Need Speakers For MOSC2012
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Thu Nov 07 11:18:43 GMT 2024

Total time taken to generate the page: 0.05228 seconds