Skip to content
Snippets Groups Projects
Commit 4f5654b6 authored by Bastian Köcher's avatar Bastian Köcher Committed by thiolliere
Browse files

Document `decl_storage!` hashers (#3170)

parent 2e700878
No related merge requests found
......@@ -83,6 +83,14 @@ use proc_macro::TokenStream;
/// If the second key is untrusted, a cryptographic `hasher` such as `blake2_256` must be used.
/// Otherwise, other items in storage with the same first key can be compromised.
///
/// Supported hashers (ordered from least to best security):
///
/// * `twox_64_concat` - TwoX with 64bit + key concatenated.
/// * `twox_128` - TwoX with 128bit.
/// * `twox_256` - TwoX with with 256bit.
/// * `blake2_128` - Blake2 with 128bit.
/// * `blake2_256` - Blake2 with 256bit.
///
/// Basic storage can be extended as such:
///
/// `#vis #name get(#getter) config(#field_name) build(#closure): #type = #default;`
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment