TinyBrain
Security-focused LLM memory storage with intelligence gathering, reverse engineering, and MITRE ATT&CK integration.
TinyBrain is a Model Context Protocol (MCP) server designed for security professionals, penetration testers, and AI assistants working on offensive security tasks. It provides intelligent memory management, pattern recognition, and comprehensive intelligence gathering capabilities.
๐ Quick Start
# Clone the repository
git clone https://github.com/rainmana/tinybrain.git
cd tinybrain
# Build and run
make build
make run
# Or use Docker
docker build -t tinybrain .
docker run -p 8080:8080 tinybrain
โจ Key Features
- ๐ง Intelligence Gathering: OSINT, HUMINT, SIGINT, GEOINT, MASINT, TECHINT, FININT, CYBINT
- ๐ Reverse Engineering: Malware analysis, binary analysis, vulnerability research, protocol analysis
- ๐ฏ MITRE ATT&CK: Complete framework integration with tactics, techniques, and procedures
- ๐ก๏ธ Security Patterns: CWE, OWASP, and multi-language vulnerability patterns
- ๐ Memory Management: 30+ memory categories for comprehensive security data organization
- ๐ MCP Protocol: Seamless integration with AI assistants and LLMs
- ๐ Pattern Recognition: Advanced insight mapping and correlation analysis
- ๐ฏ Threat Intelligence: Threat actor profiling, attack campaign tracking, IOC management
๐ Documentation
๐ Complete Documentation - Comprehensive documentation index
Quick Access:
- Getting Started - Installation and basic usage
- Core Features - Memory management, sessions, and search
- Advanced Features - Advanced memory management and pattern recognition
- Intelligence & Reconnaissance - OSINT, HUMINT, SIGINT, and more
- Reverse Engineering - Malware analysis and vulnerability research
- Security Patterns - CWE, OWASP, and multi-language patterns
- AI Integration - AI assistant integration and development setup
- Authorization - Access control and authorization patterns
- Integration - General integration capabilities and tools
- API Reference - Complete API documentation
๐ ๏ธ Installation
From Source
go install github.com/rainmana/tinybrain/cmd/server@latest
Docker
docker pull rainmana/tinybrain:latest
Pre-built Binaries
Download from Releases
๐ก Usage
Basic Example
// Create a new intelligence session
session := &Session{
Name: "OSINT Intelligence Gathering",
TaskType: "intelligence_analysis",
IntelligenceType: "osint",
Classification: "unclassified",
ThreatLevel: "medium",
}
// Store intelligence findings
finding := &IntelligenceFinding{
Title: "Social Media Intelligence",
IntelligenceType: "osint",
ThreatLevel: "medium",
MITRETactic: "TA0001",
MITRETechnique: "T1591",
KillChainPhase: "reconnaissance",
}
MCP Integration
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "mcp_tinybrain-mcp-server_create_session",
"arguments": {
"name": "Security Assessment",
"task_type": "penetration_test",
"intelligence_type": "osint"
}
}
}
๐๏ธ Architecture
TinyBrain is built with:
- Go - High-performance backend
- SQLite - Fast, reliable local storage
- FTS5 - Full-text search capabilities
- MCP Protocol - LLM integration standard
- MITRE ATT&CK - Security framework integration
๐งช Testing
# Run all tests
make test
# Run with coverage
make test-coverage
# Run specific test suite
go test -v ./internal/repository
๐ Performance
- Memory Operations: ~1000 entries/second
- Search Operations: ~100 searches/second
- Intelligence Analysis: ~100 analyses/second
- Database Size: ~1MB per 10,000 memory entries
๐ค Contributing
We welcome contributions! Please see our Contributing Guide for details.
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests
- Submit a pull request
๐ License
MIT License - see LICENSE file for details.
๐ Acknowledgments
- MITRE ATT&CK for the security framework
- Model Context Protocol for LLM integration
- OWASP for security patterns
- CWE for vulnerability classification
๐ Support
- ๐ Documentation
- ๐ Issue Tracker
- ๐ฌ Discussions
TinyBrain - Empowering security professionals with intelligent memory management and comprehensive intelligence gathering capabilities.