diff options
Diffstat (limited to 'test/wasi/c/symlink_escape.c')
-rw-r--r-- | test/wasi/c/symlink_escape.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/wasi/c/symlink_escape.c b/test/wasi/c/symlink_escape.c new file mode 100644 index 0000000000..32dcc64eeb --- /dev/null +++ b/test/wasi/c/symlink_escape.c @@ -0,0 +1,9 @@ +#include <assert.h> +#include <errno.h> +#include <stdio.h> + +int main() { + FILE* file = fopen("/sandbox/subdir/outside.txt", "r"); + assert(file == NULL); + assert(errno == ENOTCAPABLE); +} |