-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
overhaul public key and address generation code
- pubkey generation code has been rewritten and moved from addr.py to keygen.py - address generation code has been rewritten and moved from addr.py to addrgen.py - keygen/addrgen classes now present a consistent API across all pubkey and address types - key/address operations and related data objects now use bytes internally instead of hex strings - pubkey generator backends are now selected using the `--keygen-backend` option - for Monero pubkeys, the new `nacl` backend has replaced `ed25519ll_djbec` as the default - a minimal unit test has been added Examples: # Generate a random Monero keypair using the unoptimized 'ed25519' backend: $ mmgen-tool --coin=xmr --keygen-backend=3 randpair # Generate an LTC Bech32 address list from the default wallet using the # 'python-ecdsa' backend: $ mmgen-addrgen --coin=ltc --type=bech32 --keygen-backend=2 1-10 Testing: # Run the minimal unit test: $ test/unit_tests_py gen # Compare BTC Segwit addresses from default 'libsecp256k1' backend to # 'pycoin' library, with edge cases and 10,000 random rounds: $ test/gentest.py --type=segwit 1:pycoin 10000 # Test all configured Monero backends against 'moneropy', with edge cases # and 10 random rounds: $ test/gentest.py --coin=xmr all:moneropy 10 # Test the 'nacl' and 'ed25519ll_djbec' backends against each other, with # edge cases and 1000 random rounds: $ test/gentest.py --coin=xmr 1:2 1000 # Test the speed of the Monero 'nacl' backend using 10,000 rounds: $ test/gentest.py --coin=xmr 1 10000 # Same for Zcash: $ test/gentest.py --coin=zec --type=zcash_z 1 10000
- Loading branch information
Showing
31 changed files
with
735 additions
and
466 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.