python-wasi
python-sandbox-wasm | python-wasi | |
---|---|---|
3 | 1 | |
20 | 91 | |
- | - | |
4.0 | 0.0 | |
3 months ago | about 1 year ago | |
Python | C | |
MIT License | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
python-sandbox-wasm
-
WebAssembly: Adding Python Support to WASM Language Runtimes
I've not yet figured out the incantations I need to actually do this - in particular the limits on CPU and memory time.
I posed this question on Mastodon recently and Jim Kring put together this demo, which gets most of the way there (albeit using an old Python 3.6 build): https://github.com/jimkring/python-sandbox-wasm
It doesn't feel like this should be as hard to figure out as it is!
- New Project: Call Untrusted Python Code from Python inside a Web Assembly “Sandbox”
python-wasi
-
WebAssembly: Adding Python Support to WASM Language Runtimes
I have been following and playing with this repository: https://github.com/singlestore-labs/python-wasi/
It builds a single Python WASM module with all dependencies included (they use VFS) and a Dockerfile to make the process easy (and actually worked first go). It does produce large files though: wasi-python3.11.wasm 110MB
What are some alternatives?
nsjail - A lightweight process isolation tool that utilizes Linux namespaces, cgroups, rlimits and seccomp-bpf syscall filters, leveraging the Kafel BPF language for enhanced security.
wasmtime-py - Python WebAssembly runtime powered by Wasmtime
wit-bindgen - A language binding generator for WebAssembly interface types
pywasm3 - Python bindings for Wasm3, a fast WebAssembly interpreter and the most universal WASM runtime
wasmer-python - 🐍🕸 WebAssembly runtime for Python
extism - The framework for building with WebAssembly (wasm). Easily load wasm modules, move data, call functions, and build extensible apps.