hypercore 0.3.1

Secure, distributed, append-only log
Documentation

hypercore

crates.io version build status downloads docs.rs docs

WIP. Secure, distributed, append-only log structure. Adapted from mafintosh/hypercore.

Usage

extern crate hypercore;

use hypercore::Feed;
use std::path::PathBuf;

let path = PathBuf::from("./my-first-dataset");
let mut feed = Feed::new(path).unwrap();

feed.append(b"hello").unwrap();
feed.append(b"world").unwrap();

println!("{:?}", feed.get(0)); // prints "hello"
println!("{:?}", feed.get(1)); // prints "world"

Data Structures

  • feed: The main data structure in Hypercore. Append-only log that uses multiple data structures and algorithms to safely store data.
  • data: Data that's written to the feed by users.
  • keypair: An Ed25519 key pair used to encrypt data with.
  • signature: A cryptorgraphic certificate of authenticity for a given piece of code.
  • tree: A binary tree mapped as a flat-tree to keep an index of the current data.
  • bitfield: ???

Installation

$ cargo add hypercore

License

MIT OR Apache-2.0