All Projects → substrate-developer-hub → substrate-proof-of-existence

substrate-developer-hub / substrate-proof-of-existence

Licence: other
Proof of Existence Blockchain built on Parity's Substrate

Programming Languages

javascript
184084 projects - #8 most used programming language
rust
11053 projects
shell
77523 projects

Note: This repository is archived and no longer maintained. Refer to this tutorial to learn how to build a proof of existence dApp.

Substrate Proof of Existence Module

This is a simple Substrate runtime module to store online distributed proof of existence for any file.

Purpose

This module enables users submit a proof of existence for a file. This proof of existence may also be used as a soft measure of ownership.

Files are not directly uploaded to the blockchain. Instead, a file digest is generated, and the resulting digest is stored on chain with the time of upload and the user who made the claim.

Anyone who has the source file can also generate the same digest and check the proof of existence on-chain.

Dependencies

Traits

This module depends on an implementation of the Currency trait. This can be done by the SRML Balances module.

Modules

This module depends on the SRML Timestamp module.

Installation

Runtime Cargo.toml

To add this module to your runtime, simply include the following to your runtime's Cargo.toml file:

[dependencies.poe]
default_features = false
package = 'proof-of-existence'
git = 'https://github.com/substrate-developer-hub/substrate-proof-of-existence.git'

and update your runtime's std feature to include this module:

std = [
    ...
    'poe/std',
]

Runtime lib.rs

You should implement it's trait like so:

impl poe::Trait for Runtime {
	type Currency = Balances;
	type Event = Event;
}

and include it in your construct_runtime! macro:

POE: poe::{Module, Call, Storage, Event<T>},

Genesis Configuration

This template module does not have any genesis configuration.

Reference Docs

You can view the reference docs for this module by running:

cargo doc --open
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].