We have a application which takes a C++, C, or Java file as input, executes it, and displays the output to the client. What are the best measures that can be taken so that no security related issues occur in the server in which program is executed. For example, the C++ program can open an fstream and create a custom file on our server
I know some practices like:
- Running it as normal user
- Writing our own sandbox scripts which do not allow system calls, etc.
Which is the best way to do this?