Pregunta

Im using Fedora 14 and tried to execute a C program inside a php script using the backtick operator.

It said permission denied, but it works for other bash commands, e.g. test.sh; it only contains ls -lrt .

Both test.sh and a.out have the permissions and both belongs to the apache users.

Note: It runs fine on the command line and I get permission denied when accessing from a browser.

¿Fue útil?

Solución 2

Thanks for the answers. I fixed it by disabling SELinux.

Otros consejos

You'll need to create a new file context for your executable as well as a transition that allows httpd to execute files marked with this context.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top