This is a simple Tetcore runtime module to store online distributed proof of existence for any file.
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.
This module depends on an implementation of the Currency
trait. This can be done by the SRML Balances module.
This module depends on the SRML Timestamp module.
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',
]
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>},
This template module does not have any genesis configuration.
You can view the reference docs for this module by running:
cargo doc --open