문제

I'll preface this by saying I am quite new to PyPy, though fairly experienced with Python.

I'm looking to run a web app where I run untrusted Python code. The PyPy sandboxing features look ideal for what I'm doing.

The PyPy docs on sandboxing indicate that you can call a PyPy sandbox from either Python or PyPy. This seems to imply that there's some separate program or executable that is the sandbox.

I'm wondering, is it possible to call a PyPy sandbox from a non-Python language? I'm looking at Haskell in particular, but it's also very possible that I could use C or C++ as an intermediate.

도움이 되었습니까?

해결책

Yes, that's possible. The PyPy sandbox is a separate process communicating only via stdin/stdout. If you want to rewrite the "external" part, you can; it's not using anything that should be too heavily Python-related.

다른 팁

Note that the sandboxing feature of PyPy is not being maintained any more, see http://www.pypy.org/features.html#sandboxing

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top