Crates.io | keyphrase |
lib.rs | keyphrase |
version | 0.1.4 |
source | src |
created_at | 2019-12-02 00:41:41.297958 |
updated_at | 2019-12-03 04:22:08.534427 |
description | KeyPhrase generation for the EARTH Network |
homepage | https://www.earth.engineering |
repository | https://github.com/EarthEngineering/keyphrase |
max_upload_size | |
id | 185821 |
size | 242,499 |
KeyPhrase generator for the EARTH Network. KeyPhrases are human readable backup phrases which contain most of the information needed to recreate your EARTH addresses.
For more info check out the KeyPhrase Specification
println!("English:");
let keyphrase = KeyPhrase::new(KeyPhraseType::Words12, Language::English);
let phrase: &str = keyphrase.phrase();
println!("KeyPhrase: {}", phrase);
// get the HD wallet seed
let seed = Seed::new(&keyphrase, "");
println!("Root Seed: {:X}", seed);
println!("----------");
// English:
// KeyPhrase: habit treat fringe blouse jump tomato hello become more planet list rhythm
// Root Seed: 1CD312DB19E0644921616B0E44B4051F2FB5D19567D4866B7AF6C7676746F94FE0E49355397BBF53659882FB928C4DF3AABD32327E88AD732770CE21ECC20
// ----------
println!("Korean:");
let keyphrase = KeyPhrase::new(KeyPhraseType::Words12, Language::Korean);
let phrase: &str = keyphrase.phrase();
println!("KeyPhrase: {}", phrase);
println!("----------");
// Korean:
// KeyPhrase: 안부 모니터 장애인 대출 지원 본격적 서적 다행 관점 부족 유치원 갈비
// ----------
println!("Italian:");
let keyphrase = KeyPhrase::new(KeyPhraseType::Words12, Language::Italian);
let phrase: &str = keyphrase.phrase();
println!("KeyPhrase: {}", phrase);
println!("----------");
// Italian:
// KeyPhrase: meno elevare diploma tralcio montato servire gittata certo garbo ombelico sfumare sguardo
// ----------
println!("Chinese Traditional:");
let keyphrase = KeyPhrase::new(KeyPhraseType::Words24, Language::ChineseTraditional);
let phrase: &str = keyphrase.phrase();
println!("KeyPhrase: {}", phrase);
println!("----------");
// Chinese Traditional:
// KeyPhrase: 廟 牙 錢 療 健 董 疆 胸 冊 弱 幾 凍 改 喬 叔 冷 山 慘 溝 呵 長 趨 鋪 跳
Variable length KeyPhrases are supported from 12 to 24 words and 128 bits to 256 bits respectively. Defaults is 12 words/128 bits.
KeyPhrase supports 8 languages and defaults to English.
Full docs are available via
cargo doc --no-deps --open
This project was originally forked from bip39-rs. Thanks to that team for an amazing project! 🎩