How to execute system calls in php via browser?

view story

http://www.linuxquestions.org – I have a C program that makes a system call (centOS 6.0) to encrypt a file, my code is: #include <stdlib.h> int main () { system ("gpg -c --batch --passphrase mypass file.txt"); return 0; } The executable object is called encrypt_file When I run ./encrypt_file directly through CLI it runs perfectly I obtain my file.txt.gpg, but when I try to execute it via browser when I get no response. Code in php: shell_exec("./encrypt_file"); I already changed permissions to apache user by issuing the following: chown apache.apache /var/www/html/ And added the next line in /e (HowTos)