Browse Source
Zcash address encoding We need to encode Zcash addresses so they aren't as large and unweildy. We're using Base58Check just like upstream does, and to ensure the first character is "z" in our addresses we must use two bytes for the version string. Two bytes gives us an extra character for free, so this PR targets the beginning of addresses to have "zc". ``` $ ./src/zcash-cli zcrawkeygen { "zcaddress" : "tnvaj4ZbZG83tj4RwZcFeLgJoSt8nw1ZvSCG8EMyowAsXTQgJPat77Y43BVdVCrwrbLy7GG9msJDYdn5hmreHmkXAkX17hb", "zcsecretkey" : "SKzkxCRWvscKnroSFyhCqhY332KcDMH4LLNdK2TsSvbmr3CGAB8B", "zcviewingkey" : "10aa74046f31cbe5eaa8965d1e104853234c3d6c6e45f9c497ca3a025d159755" } ``` This PR also encodes the spending keys with a prefix that targets "SK". The spec needs to be updated with these changes. Testnet addresses will start with "tn". Closes #572pull/145/head
zkbot
8 years ago
7 changed files with 151 additions and 45 deletions
Loading…
Reference in new issue