關(guān)于多鏈錢包系統(tǒng)開發(fā)技術(shù)邏輯及規(guī)則(開發(fā)源碼)
It can be divided into single-currency wallet,multi-currency wallet and all-currency wallet Single currency wallet:As the name implies,it is a blockchain wallet that only serves a single blockchain digital asset.Because it usually only supports a single blockchain main chain platform,it is also called the main chain wallet,which is generally developed by the project party or community. Multi-currency wallet:a wallet that supports multiple blockchain digital assets.Multiple blockchain digital assets can be a blockchain main chain and tokens set around the main chain protocol,or different digital assets on multiple blockchain main chains. All-currency wallet:a blockchain wallet that supports all types of blockchain main chain digital assets and token assets. public DeterministicSeed(byte[]entropy,String passphrase,long creationTimeSeconds){需求及功能I35系統(tǒng)7O98源碼o7I8 ... this.seed=MnemonicCode.toSeed(mnemonicCode,passphrase); ... } public static byte[]toSeed(List<String>words,String passphrase){流程及源碼:mrsfu123 checkNotNull(passphrase,"A null passphrase is not allowed."); //To create binary seed from mnemonic,we use PBKDF2 function //with mnemonic sentence(in UTF-8)used as a password and //string"mnemonic"+passphrase(again in UTF-8)used as a //salt.Iteration count is set to 4096 and HMAC-SHA512 is //used as a pseudo-random function.Desired length of the //derived key is 512 bits(=64 bytes). //將助記詞連接起來,以空格作為分隔符。pass格式:"aa bb cc dd..." String pass=Utils.SPACE_JOINER.join(words); String salt="mnemonic"+passphrase; final Stopwatch watch=Stopwatch.createStarted(); //使用PBKDF2SHA512生成64位的種子 byte[]seed=PBKDF2SHA512.derive(pass,salt,PBKDF2_ROUNDS,64); watch.stop(); log.info("PBKDF2 took{}",watch); return seed; }