Microsandbox: Secure, Self-Hosted Sandboxes for AI Agents and Untrusted Code

This repository profile is provided by osrepos.com, an open source repository discovery platform.

Microsandbox: Secure, Self-Hosted Sandboxes for AI Agents and Untrusted Code

Summary

Microsandbox is an open-source project providing self-hosted, hardware-isolated sandboxes designed for securely executing untrusted user and AI code. It offers a unique balance of strong isolation, instant startup times, and OCI compatibility, addressing the challenges of traditional container and VM solutions. Built in Rust, Microsandbox is ideal for developers building agentic AI applications requiring robust and flexible execution environments.

Repository Information

Analyzed by OSRepos on January 28, 2026

Topics

Click on any tag to explore related repositories

Use at your own risk

OSRepos shares public repositories for knowledge and discovery only. Any installation, execution, configuration, or use of code from these repositories is the user's own responsibility. Always review the repository, source code, dependencies, licenses, and security implications before running or installing anything. OSRepos is not responsible for issues, damages, or losses resulting from third-party repositories.

Introdução

Microsandbox é um projeto open-source inovador desenvolvido pela zerocore-ai, que oferece sandboxes auto-hospedadas e isoladas por hardware para a execução segura de código de usuário e IA não confiável. Construído em Rust, ele visa superar as limitações de soluções tradicionais como contêineres e máquinas virtuais, fornecendo uma combinação de forte isolamento, tempos de inicialização instantâneos e compatibilidade OCI. Isso o torna uma espinha dorsal ideal para a web agêntica, permitindo ambientes de execução rápidos, seguros e flexíveis para agentes de IA e outras cargas de trabalho exigentes. Com 4498 estrelas e 208 forks, está ganhando uma tração significativa na comunidade de desenvolvedores.

Instalação

Para começar com o Microsandbox, siga estes passos simples:

  1. Baixe microsandbox:

    curl -sSL https://get.microsandbox.dev | sh
    
  2. Inicie o servidor:

    msb server start --dev
    
  3. Puxe uma imagem de ambiente (Opcional):

    msb pull microsandbox/python
    

Exemplos

Microsandbox oferece maneiras flexíveis de gerenciar e acessar sandboxes, incluindo utilitários de linha de comando e SDKs para várias linguagens.

Exemplos de Linha de Comando:

  • Sandbox Temporário: Para tarefas únicas, crie um ambiente limpo que não deixa rastros na saída.

    msx python # ou `msb exe --image python`
    
  • Sandboxes em todo o Sistema: Execute sandboxes de longa duração configuradas automaticamente como executáveis em todo o sistema.

    msi python py-data # ou `msb install --image alpine py-data`
    py-data # De qualquer diretório, execute a sandbox
    

Exemplos de SDK (BETA):

Microsandbox fornece SDKs para integrar capacidades de sandboxing diretamente em suas aplicações.

  • Python:

    import asyncio
    from microsandbox import PythonSandbox
    
    async def main():
        async with PythonSandbox.create(name="test") as sb:
            exec = await sb.run("name = 'Python'")
            exec = await sb.run("print(f'Hello {name}!')")
    
        print(await exec.output()) # prints Hello Python!
    
    asyncio.run(main())
    
  • JavaScript:

    import { NodeSandbox } from "microsandbox";
    
    async function main() {
      const sb = await NodeSandbox.create({ name: "test" });
    
      try {
        let exec = await sb.run("var name = 'JavaScript'");
        exec = await sb.run("console.log(`Hello ${name}!`)");
    
        console.log(await exec.output()); // prints Hello JavaScript!
      } finally {
        await sb.stop();
      }
    }
    
    main().catch(console.error);
    
  • Rust:

    use microsandbox::{SandboxOptions, PythonSandbox};
    
    #[tokio::main]
    async fn main() -> Result<(), Box> {
        let options = SandboxOptions::builder().name("test").build();
        let mut sb = PythonSandbox::create(options).await?;
    
        let exec = sb.run(r#"name = "Rust""#).await?;
        let exec = sb.run(r#"print(f"Hello {name}!")"#).await?;
    
        println!("{}", exec.output().await?); // prints Hello Rust!
    
        sb.stop().await?;
    
        Ok(())
    }
    

Porquê usar Microsandbox

Microsandbox se destaca por oferecer uma combinação atraente de recursos que abordam necessidades críticas no desenvolvimento de software moderno, especialmente para aplicações de IA e agênticas:

  • Forte Isolamento: Atinge isolamento de VM em nível de hardware usando microVMs, garantindo que o código não confiável seja executado em um ambiente altamente seguro.

  • Inicialização Instantânea: Com tempos de inicialização abaixo de 200 ms, o Microsandbox fornece ambientes de execução quase instantâneos, cruciais para aplicações dinâmicas e responsivas.

  • Compatível com OCI: Pode executar imagens de contêiner padrão, permitindo que os desenvolvedores aproveitem os ecossistemas existentes de Docker e OCI.

  • Auto-Hospedado: Implante o Microsandbox dentro de sua própria infraestrutura, dando-lhe total autonomia e controle sobre seus ambientes de execução.

  • Pronto para IA: Integra-se perfeitamente com fluxos de trabalho de agentes e IA via MCP, tornando-o uma ferramenta poderosa para construir sistemas de IA seguros e escaláveis.

Seu design como a espinha dorsal de execução da web agêntica destaca seu foco em velocidade, segurança e flexibilidade para a próxima geração de aplicações impulsionadas por IA.

Links

Related repositories

Similar repositories that may be relevant next.

ai-memory: Long-Term Memory Solution for AI Coding Agents

ai-memory: Long-Term Memory Solution for AI Coding Agents

September 10, 2026

ai-memory is a robust solution providing long-term memory for AI coding agents, enabling seamless handoffs between different agent vendors and machines. It ensures that project knowledge, failed approaches, and open questions persist, facilitating collaborative development and continuous progress across various tools and teams. Built in Rust, this open-source project offers a reliable and transparent way to manage agent memory.

RustAIAgent Memory
Worktrunk: Streamlining Git Worktree Management for AI Agent Workflows

Worktrunk: Streamlining Git Worktree Management for AI Agent Workflows

September 9, 2026

Worktrunk is a powerful CLI tool built in Rust, designed to simplify Git worktree management. It's particularly optimized for parallel AI agent workflows, making it easy to handle multiple development branches simultaneously. By abstracting away the complexities of native Git worktrees, Worktrunk enhances developer productivity with intuitive commands and automation features.

RustGitWorktrees
vibe-kanban-local: A Self-Contained Kanban for AI Coding Agents

vibe-kanban-local: A Self-Contained Kanban for AI Coding Agents

September 8, 2026

vibe-kanban-local is a robust, local-only fork of the original BloopAI/vibe-kanban project, maintained after its upstream sunset. It provides a self-contained, single-user kanban board, allowing developers to integrate over ten different AI coding agents directly into their workflow without any cloud dependencies or logins. This tool is ideal for enhancing productivity with AI assistance in a private, offline environment.

RustKanbanProductivity
Ralph Orchestrator, An Advanced Framework for Autonomous AI Agent Orchestration

Ralph Orchestrator, An Advanced Framework for Autonomous AI Agent Orchestration

September 6, 2026

Ralph Orchestrator is a robust, Rust-based framework designed for autonomous AI agent orchestration. It implements the innovative "Ralph Wiggum technique," a methodology focused on continuous iteration to ensure AI agents complete complex tasks effectively. This powerful tool supports multiple AI backends and offers features like a "hat system" for specialized personas and human-in-the-loop interaction via Telegram.

AIAI AgentsOrchestration

Source repository

Open the original repository on GitHub.

16 counted GitHub visits

View on GitHub
OS
OSRepos

Analysis and discovery of open source repositories. Find interesting projects and follow their updates.

Monitor your website with YourWebsiteScore

OSRepos shares public repositories for knowledge and discovery only. Any installation, execution, configuration, or use of third-party repository code is at your own risk. Always review source code, dependencies, licenses, and security implications before running anything.

© 2025 OSRepos. Built with Nuxt 3 and lots of ❤️