Skip to main content
TokoTubeIC OS

Armada Protocol

A decentralized, censorship-resistant BitTorrent index built on the Internet Computer Protocol.

Armada Protocol

Armada Protocol

Decentralized BitTorrent Indexing for the Open Web

Armada Protocol is a censorship-resistant torrent indexing system built on the Internet Computer Protocol (ICP). It provides a decentralized index of BitTorrent content discovered from the DHT network, enabling permanent, verifiable access to publicly available content without relying on centralized trackers or search engines.

What is Armada Protocol?

Armada Protocol addresses a fundamental problem in the BitTorrent ecosystem: the reliance on centralized trackers and search engines that can be censored, shut down, or manipulated. By storing the torrent index on ICP canisters, Armada creates a permanent, tamper-resistant registry of available content.

The project uses naval terminology to describe its components:

Term Naval Meaning In Armada Protocol
Admiral Fleet commander Uploader/creator
Fleet Group of ships Swarm (all peers)
Ships Vessels carrying cargo Peers/seeders
Crew Personnel on ships Leechers
Cargo Goods being transported Files/torrents
Manifest Cargo inventory document Registry/index (on-chain)
Harbors Safe ports Tracker canisters
$FLEET - Protocol token

Key Features

Decentralized Indexing

  • DHT Crawling - Discovers torrents directly from the BitTorrent DHT network
  • On-chain Storage - Index stored permanently on ICP canisters
  • Deduplication - Bridge service prevents duplicate entries
  • Batch Ingestion - Efficiently processes and uploads discovered content

Swarm Statistics

  • Seeder Tracking - Monitors peers with complete copies of cargo
  • Leecher Monitoring - Tracks active downloaders
  • Completion Counts - Records total downloads per torrent
  • Multi-tracker Support - Scrapes multiple public BitTorrent trackers

Search & Discovery

  • Name-based Search - Query the on-chain index by content name
  • Pagination Support - Browse large result sets with offset/limit
  • Recent Entries - Quick access to newly discovered torrents
  • Existence Checks - Verify if specific content is indexed

Technical Architecture

Technical Architecture

  • dhtc — DHT Crawler discovers torrents from BitTorrent DHT network
  • Bridge Service — Polls dhtc, deduplicates, prepares entries for upload
  • Manifest Canister — ICP canister storing the searchable cargo index

Data Flow: dhtc → Bridge Service → Manifest Canister (ICP)

Components

  1. dhtc - DHT crawler that discovers torrents from the BitTorrent DHT network
  2. Bridge Service - Polls dhtc, deduplicates data, and prepares entries for upload
  3. Manifest Canister - ICP canister storing the searchable cargo index

Technical Stack

Backend

  • Language: Motoko
  • Canister: ManifestService for on-chain index storage
  • Storage: HashMap-based stable storage with preupgrade hooks
  • ICP SDK: dfx for canister deployment

Bridge Service

  • Language: TypeScript/Node.js
  • Database: SQLite for deduplication
  • Storage Format: NDJSON (Newline-delimited JSON)
  • Protocols: UDP and HTTP BitTorrent tracker scraping (BEP 48)

Infrastructure

  • Containerization: Docker & Docker Compose
  • Local Development: dfx local replica
  • Mainnet: ic0.app deployment target

Data Format

Cargo Entry

		{
  "ih": "abc123...",    // info_hash
  "n": "Ubuntu 22.04",  // name
  "s": 3221225472,      // size (bytes)
  "f": [                // files
    {"p": "ubuntu.iso", "z": 3221225472}
  ],
  "d": 1708700000,      // discovered_at (unix timestamp)
  "sw": {               // swarm info (optional)
    "s": 42,            // seeders
    "l": 13,            // leechers
    "c": 100,           // completed downloads
    "u": 1708700100     // updated_at (unix timestamp)
  }
}
	

Use Cases

For Content Archivists

  • Permanent, censorship-resistant storage of torrent indexes
  • Verify content integrity through on-chain provenance
  • Build distributed archives of public domain and open content

For Privacy Advocates

  • No central authority can remove the index
  • Fully transparent and verifiable content discovery
  • Support for anonymous BitTorrent participation

For Developers

  • Programmatic access to torrent index via ICP canister API
  • Integrate torrent discovery into decentralized applications
  • Build alternative discovery mechanisms on top of the index

For Researchers

  • Analyze BitTorrent network trends and content distribution
  • Study DHT crawling patterns and efficiency
  • Monitor swarm health and content availability

Canister API

The Manifest canister provides the following public methods:

		// Ingest cargo entries (batch)
ingestBatch(batch: [CargoEntry]) -> Nat
 
// Ingest single entry
ingest(entry: CargoEntry) -> Bool
 
// Search by name
search(query: Text, opts: ?SearchOpts) -> [CargoEntry]
 
// Get by info hash
get(infoHash: Text) -> ?CargoEntry
 
// Check existence
exists(infoHash: Text) -> Bool
 
// Get statistics
getStats() -> Stats
 
// Get recent entries
recent(limit: Nat) -> [CargoEntry]
 
// Get total count
count() -> Nat
	

Development Status

Armada Protocol is in Active Development

Completed

  • ✅ DHT crawler (dhtc) implementation
  • ✅ Bridge service with deduplication
  • ✅ Manifest canister with core functionality
  • ✅ Tracker scraping (UDP/HTTP)
  • ✅ Local development environment

In Development

  • 🚧 Index canister UI/frontend
  • 🚧 Search optimization
  • 🚧 Mainnet deployment
  • 🚧 Swarm statistics enrichment

Roadmap

Phase 1: Core Infrastructure

  • Complete DHT crawler optimization
  • Deploy MVP canister to mainnet
  • Build basic search interface

Phase 2: Scale & Index

  • Expand DHT crawling coverage
  • Implement incremental indexing
  • Add more swarm statistics sources

Phase 3: Decentralization

  • Multiple canister partitions
  • Community-governed indexing priorities
  • Tokenomics for $FLEET governance

Why Decentralized Torrent Indexing?

The BitTorrent network relies heavily on centralized components:

  • Trackers - Single points of failure that can be shut down
  • Search Engines - Subject to censorship and takedowns
  • Index Sites - Often blocked by ISPs or governments

Armada Protocol solves these issues by:

  1. No Single Point of Failure - The index lives on ICP, distributed across many nodes
  2. Censorship Resistance - Immutable on-chain storage can't be easily removed
  3. Transparency - Anyone can verify the index contents
  4. Permanence - Content indexed on-chain stays indexed

By combining BitTorrent's proven P2P file-sharing with ICP's decentralized infrastructure, Armada Protocol creates a truly resilient content distribution system for the open web.


This post documents the Armada Protocol project - a decentralized BitTorrent indexing system on the Internet Computer Protocol. For detailed technical documentation, visit the master documentation.