Skip to content

NeaByteLab/Sandbox-Guide

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Architecture Preview

Repo Size Total Files License

Secure Sandbox Guide

Guide for building secure sandbox environments with gVisor, 9P, and JWT-based controls.

Security Layers

Layer Component Protects Against
Runtime gVisor (user-space kernel) Kernel exploits, container escapes
Filesystem 9P Protocol (isolated mounts) Unauthorized file access, symlink attacks
Network Egress Proxy (JWT-controlled) Data exfiltration, C2 callbacks
Resources cgroups (limits) DoS, resource exhaustion
Process Linux Namespaces (isolation) Privilege escalation, lateral movement
Identity JWT Authentication (ES256) Unauthorized access, replay attacks

Quick Start

# Clone the repository
git clone https://github.com/NeaByteLab/Sandbox-Guide.git
cd Sandbox-Guide

# Install gVisor
chmod +x scripts/install-gvisor.sh
sudo ./scripts/install-gvisor.sh

# Run security tests
chmod +x scripts/security-tests.sh
./scripts/security-tests.sh

macOS Users (Multipass)

gVisor requires Linux. Use Multipass to create an Ubuntu VM:

# Create and setup VM
multipass launch --name sandbox-test --cpus 2 --memory 4G --disk 20G
multipass mount $(pwd) sandbox-test:/home/ubuntu/sandbox-guide
multipass shell sandbox-test

# Inside VM - run the quick start
cd /home/ubuntu/sandbox-guide
bash scripts/quick-start.sh

Documentation

For the full guide, see docs/README.md.

Scripts

Quick access to automation scripts in scripts/:

Script Purpose
quick-start.sh Full setup automation
install-gvisor.sh Install gVisor runtime
security-tests.sh Run security validation suite
envoy.yaml Egress proxy configuration
auth-service.py JWT token generation service
container-manager.py Container lifecycle management

Reference

License

Licensed under the Apache License, Version 2.0. See LICENSE for details.

Contributors