Somehow, one of our sites continues to be compromised. Is there a way that I can log every command that PHP runs, either via system(), exec(), etc?

link|improve this question

feedback

1 Answer

up vote 3 down vote accepted

You can use override-function, and rename_function rewrite the system and exec commands, do a stack trace from there and log it to a file.

link|improve this answer
Is there a way to do this across an entire site, or just for a single page? – gms8994 Jun 11 '10 at 14:31
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.