A system for automated detection of organizational exposure in ransomware campaigns
- Overview
- Architecture
- Quick Start
- Installation
- Usage
- Features
- Collector Types
- Security Considerations
- Development
- Troubleshooting
- Roadmap
- License
- Contributing
Ransom-Monitor is a specialized OSINT framework designed to track ransomware leak sites and alert organizations when they or their subsidiaries are mentioned. The system integrates both regular web APIs and dark web Tor-based sources to provide comprehensive coverage of ransomware actor activities.
Key features include:
- Flexible collector architecture supporting diverse intelligence sources
- Effective domain matching system with caching mechanisms for performance
- Secure Tor integration approach for accessing .onion sites
- Alert generation for matching network identifiers
- Watchlist management for organizations and their identifiers
The system consists of six primary components:
- Collection Framework - Retrieves data from intelligence sources, including both regular web APIs and Tor-hosted sites
- Storage Layer - Manages persistent storage of intelligence data, watchlist identifiers, and alert history
- Matching Engine - Identifies potential matches between collected intelligence and watchlist identifiers
- Alert System - Generates and delivers notifications about matches
- Tor Proxy - Provides secure, isolated access to dark web intelligence sources
- User Interface - Command-line interface with dashboard visualizations and management capabilities
For those who want to get up and running quickly:
# Clone and install
git clone https://github.com/birb97/RansomMonitor
cd RansomMonitor
python -m venv venv && source venv/bin/activate
# Initialize and run
python -c "from database import DatabaseService; DatabaseService().initialize()"
python main.py- Python 3.9 or higher
- Docker and Docker Compose (for Tor-based collection)
- Git (for obtaining the source code)
- Basic command-line familiarity
- Access to the internet, including Tor access if using dark web collection
# Clone the repository
git clone https://github.com/birb97/RansomMonitor.git
cd RansomMonitor
# Create and activate a virtual environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Initialize the database
python -c "from database import DatabaseService; DatabaseService().initialize()"The Tor collection components require Docker for secure isolation:
# Navigate to the droplet directory
cd droplet
# Build and start the containers
docker-compose build
docker-compose up -d
# Verify that the containers are running
docker ps | grep "tor-proxy\|collection-agent"
# Test the collection agent
curl http://localhost:5000/healthExample configuration:
# Edit the configuration file with your preferred settings
[General]
interval = 300
database_path = sqlite:///ransomware_intel.db
[Logging]
level = INFO
file = ransomware_intel.log
[Droplet]
endpoint = http://localhost:5000
api_secret = your-secret-key# Start in foreground mode
python main.py
# Start in background mode
python main.py start-background
# Check status of background process
python main.py status
# Stop background process
python main.py stop-background- Start/Stop collection - Control the collection process
- Manage watchlist - Add, edit, or remove organizations and their identifiers
- Settings - Configure system parameters
- Domain Matching Explorer - Test and explore domain matching behavior
- Database Inspector - Examine collected intelligence and alerts
- Check Existing Claims - Scan historical data against the current watchlist
- Comprehensive Coverage: Monitors diverse ransomware intelligence sources
- Accurate Identification: Effectively matches organizational identifiers across different formats
- Security Considerations: Implements security measures when accessing potentially malicious content
- Operational Efficiency: Minimizes resource requirements and maintenance overhead
- Usability: Provides an intuitive interface for security teams
- Extensibility: Offers a modular architecture that can be easily extended
The system supports multiple collection methods:
- API Collectors: Interact with structured API endpoints (e.g., Ransomlook)
- Aggregator Collectors: Retrieve data from web services that aggregate multiple sources (e.g., Ransomwatch, Ransomware.live)
- Tor-Based Collectors: Retrieve data from Tor-hosted leak sites through a secure, containerized approach
The system implements several security measures:
- Container Isolation: Docker containers create logical separation between the Tor processes and the main application
- Network Namespace Isolation: Custom internal network with no direct external access
- Port Binding Controls: Localhost-only binding prevents external API access
- HMAC Authentication: Time-limited tokens provide strong API authentication
- Least Privilege Configuration: Non-root user execution limits impact of potential compromise
To extend the system with new collectors or features:
-
Adding a new collector:
from collectors.base import BaseCollector class NewSourceCollector(BaseCollector): def __init__(self): super().__init__("NewSource", "https://api.newsource.com") def collect(self): # Implementation details # ... return processed_data
-
Running tests:
# Run all tests python -m test_framework # Run specific test modules python -m test_framework tests.test_collectors tests.test_domain_utils
Common issues and solutions:
-
Tor connection problems:
- Verify Docker containers are running:
docker ps - Check Tor container logs:
docker logs tor-proxy - Ensure your network allows Tor connections
- Verify Docker containers are running:
-
Database errors:
- Verify database path in configuration
- Check file permissions for SQLite database
- Run database repair:
python -c "from database import DatabaseService; DatabaseService().repair()"
-
Collection failures:
- Check network connectivity
- Verify API endpoints are accessible
- Ensure correct configuration for collection sources
Future development plans:
- Enhanced Collection Capabilities: Discovery mechanisms for new ransomware groups and leak sites
- Advanced Matching Algorithms: Machine learning approaches for improved accuracy
- Alert Prioritization System: Confidence scoring and context-based prioritization
- Web-Based Dashboard: Graphical visualization of alerts, trends, and system status
- Streamlined Installation: Packaging options for easier deployment
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
For major changes, please open an issue first to discuss what you would like to change.
RansomMonitor stands on the shoulders of several excellent open-source projects and services. I'd like to express my gratitude to the following:
- SQLAlchemy - The SQL toolkit and Object-Relational Mapper that provides the data layer for the application
- Requests - The elegant HTTP library that powers the web API interactions
- Flask - The lightweight WSGI web application framework used for the collection agent
- Ransomlook - For providing structured API access to ransomware intelligence
- Ransomware.live - For their comprehensive listing of active ransomware groups
- Ransomwatch - For their open-source ransomware monitoring project which inspired many others
- Tor Project - For creating the onion routing network that enables secure access to dark web sources
- Docker - For container technology that enables secure isolation of Tor components
- PySocks - For providing Python SOCKS client module for Tor communication
- pytest - For the testing framework that ensures the code quality
- Gunicorn - For the WSGI HTTP server that runs the collection agent
Special thanks to the cybersecurity research community for their work on ransomware tracking and intelligence gathering, which has influenced the project and its methodologies.
I also acknowledge all contributors who have invested time and effort in building and improving this tool.