I am using the sample2.py listed here https://github.com/openjudge/sandbox as a wrapper to call the sandbox libraries (aka. libsandbox && pysandbox).
Following is my C++ Code
#include <stdio.h>
int main(){
return 0;
}
The result when i run the sample2.py is
result: RF
cpu: 2ms
mem: 288kB
Can anyone tell me what are the changes i have to do to the wrapper to make this work ?
The
RFresult code was most likely due to unexpected syscalls for file operations (i.e.SYS_open(),SYS_close(),SYS_stat(), ...). It so happens when (1) the target program actually does file operations, and (or) when (2) it was dynamically linked and needs to load.solibraries in runtime. Since your target program does not invoke file operations, it belongs to the latter case.Then, to resolve the
RFoutcome, either,SYSCALL/SYSRETevents;DISCLAIMER: I am the author of
libsandbox.