1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-22 15:38:11 +00:00

common: add coin.divisibility attribute

legacy: remove has_address_type/has_address_type_p2sh
This commit is contained in:
Pavol Rusnak 2019-12-05 04:30:51 +01:00
parent 6ca0288092
commit 5301c03607
No known key found for this signature in database
GPG Key ID: 91F3B339B9A02A3D
81 changed files with 219 additions and 85 deletions

View File

@ -6,6 +6,7 @@
"github": "https://github.com/Actinium-project/Actinium", "github": "https://github.com/Actinium-project/Actinium",
"maintainer": "Harris Brakmic <brakmic@actinium.org>", "maintainer": "Harris Brakmic <brakmic@actinium.org>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 53, "address_type": 53,
"address_type_p2sh": 55, "address_type_p2sh": 55,
"maxfee_kb": 40000000, "maxfee_kb": 40000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/axerunners/axe", "github": "https://github.com/axerunners/axe",
"maintainer": "Kirill Orlov <kirill@axerunners.com>", "maintainer": "Kirill Orlov <kirill@axerunners.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 55, "address_type": 55,
"address_type_p2sh": 16, "address_type_p2sh": 16,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/Bitcoin-ABC/bitcoin-abc", "github": "https://github.com/Bitcoin-ABC/bitcoin-abc",
"maintainer": "Jochen Hoenicke <hoenicke@gmail.com>", "maintainer": "Jochen Hoenicke <hoenicke@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 0, "address_type": 0,
"address_type_p2sh": 5, "address_type_p2sh": 5,
"maxfee_kb": 500000, "maxfee_kb": 500000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/Bitcoin-ABC/bitcoin-abc", "github": "https://github.com/Bitcoin-ABC/bitcoin-abc",
"maintainer": "Jochen Hoenicke <hoenicke@gmail.com>", "maintainer": "Jochen Hoenicke <hoenicke@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 111, "address_type": 111,
"address_type_p2sh": 196, "address_type_p2sh": 196,
"maxfee_kb": 10000000, "maxfee_kb": 10000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/bellcoin-org/bellcoin", "github": "https://github.com/bellcoin-org/bellcoin",
"maintainer": "ilmango-doge <ilmango.doge@gmail.com>", "maintainer": "ilmango-doge <ilmango.doge@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 25, "address_type": 25,
"address_type_p2sh": 85, "address_type_p2sh": 85,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/BTCGPU/BTCGPU", "github": "https://github.com/BTCGPU/BTCGPU",
"maintainer": "Saleem Rashid <trezor@saleemrashid.com>", "maintainer": "Saleem Rashid <trezor@saleemrashid.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 38, "address_type": 38,
"address_type_p2sh": 23, "address_type_p2sh": 23,
"maxfee_kb": 500000, "maxfee_kb": 500000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/BTCGPU/BTCGPU", "github": "https://github.com/BTCGPU/BTCGPU",
"maintainer": "The Bitcoin Gold Developers <support@bitcoingold.org>", "maintainer": "The Bitcoin Gold Developers <support@bitcoingold.org>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 111, "address_type": 111,
"address_type_p2sh": 196, "address_type_p2sh": 196,
"maxfee_kb": 500000, "maxfee_kb": 500000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/bitcoin/bitcoin", "github": "https://github.com/bitcoin/bitcoin",
"maintainer": "Pavol Rusnak <stick@satoshilabs.com>", "maintainer": "Pavol Rusnak <stick@satoshilabs.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 0, "address_type": 0,
"address_type_p2sh": 5, "address_type_p2sh": 5,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/bitcoin/bitcoin", "github": "https://github.com/bitcoin/bitcoin",
"maintainer": "Thomas Kerin <me@thomaskerin.io>", "maintainer": "Thomas Kerin <me@thomaskerin.io>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 111, "address_type": 111,
"address_type_p2sh": 196, "address_type_p2sh": 196,
"maxfee_kb": 10000000, "maxfee_kb": 10000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/bitcoin/bitcoin", "github": "https://github.com/bitcoin/bitcoin",
"maintainer": "Pavol Rusnak <stick@satoshilabs.com>", "maintainer": "Pavol Rusnak <stick@satoshilabs.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 111, "address_type": 111,
"address_type_p2sh": 196, "address_type_p2sh": 196,
"maxfee_kb": 10000000, "maxfee_kb": 10000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/LIMXTEC/BitCore", "github": "https://github.com/LIMXTEC/BitCore",
"maintainer": "limxdev <limxdev@bitcore.cc>", "maintainer": "limxdev <limxdev@bitcore.cc>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 3, "address_type": 3,
"address_type_p2sh": 125, "address_type_p2sh": 125,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/bitgreen/bitgreen", "github": "https://github.com/bitgreen/bitgreen",
"maintainer": "Dennis R <xezzor@gmail.com>", "maintainer": "Dennis R <xezzor@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 38, "address_type": 38,
"address_type_p2sh": 6, "address_type_p2sh": 6,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/BitzenyCoreDevelopers/bitzeny", "github": "https://github.com/BitzenyCoreDevelopers/bitzeny",
"maintainer": "y-chan <yuto_tetuota@yahoo.co.jp>", "maintainer": "y-chan <yuto_tetuota@yahoo.co.jp>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 81, "address_type": 81,
"address_type_p2sh": 5, "address_type_p2sh": 5,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/BlockStamp/bst", "github": "https://github.com/BlockStamp/bst",
"maintainer": "Krzysztof Kuchta <k.kuchta@blockstamp.info>", "maintainer": "Krzysztof Kuchta <k.kuchta@blockstamp.info>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 26, "address_type": 26,
"address_type_p2sh": 5, "address_type_p2sh": 5,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/BTCPrivate/BitcoinPrivate", "github": "https://github.com/BTCPrivate/BitcoinPrivate",
"maintainer": "Chris Sulmone <csulmone@gmail.com>", "maintainer": "Chris Sulmone <csulmone@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 4901, "address_type": 4901,
"address_type_p2sh": 5039, "address_type_p2sh": 5039,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://gitlab.com/bitcoinrh/BRhodiumNode", "github": "https://gitlab.com/bitcoinrh/BRhodiumNode",
"maintainer": "baff5b <dvbr3@protonmail.com>", "maintainer": "baff5b <dvbr3@protonmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 61, "address_type": 61,
"address_type_p2sh": 123, "address_type_p2sh": 123,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/Capricoinofficial/Capricoin", "github": "https://github.com/Capricoinofficial/Capricoin",
"maintainer": "Jozef Knaperek <jknaperek@gmail.com>", "maintainer": "Jozef Knaperek <jknaperek@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 28, "address_type": 28,
"address_type_p2sh": 35, "address_type_p2sh": 35,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/cpuchain/cpuchain", "github": "https://github.com/cpuchain/cpuchain",
"maintainer": "Min Khang Aung <info@cpuchain.org>", "maintainer": "Min Khang Aung <info@cpuchain.org>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 28, "address_type": 28,
"address_type_p2sh": 30, "address_type_p2sh": 30,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/Crowndev/crowncoin", "github": "https://github.com/Crowndev/crowncoin",
"maintainer": "Ashot <ashot@crownplatform.com>", "maintainer": "Ashot <ashot@crownplatform.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 95495, "address_type": 95495,
"address_type_p2sh": 95473, "address_type_p2sh": 95473,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/dashpay/dash", "github": "https://github.com/dashpay/dash",
"maintainer": "Karel Bilek <karel.bilek@satoshilabs.com>", "maintainer": "Karel Bilek <karel.bilek@satoshilabs.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 76, "address_type": 76,
"address_type_p2sh": 16, "address_type_p2sh": 16,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/dashpay/dash", "github": "https://github.com/dashpay/dash",
"maintainer": "Karel Bilek <karel.bilek@satoshilabs.com>", "maintainer": "Karel Bilek <karel.bilek@satoshilabs.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 140, "address_type": 140,
"address_type_p2sh": 19, "address_type_p2sh": 19,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/decred/dcrd", "github": "https://github.com/decred/dcrd",
"maintainer": "Alex Yocom-Piatt <ay-p@decred.org>", "maintainer": "Alex Yocom-Piatt <ay-p@decred.org>",
"curve_name": "secp256k1_decred", "curve_name": "secp256k1_decred",
"divisibility": 8,
"address_type": 1855, "address_type": 1855,
"address_type_p2sh": 1818, "address_type_p2sh": 1818,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/decred/dcrd", "github": "https://github.com/decred/dcrd",
"maintainer": "Saleem Rashid <trezor@saleemrashid.com>", "maintainer": "Saleem Rashid <trezor@saleemrashid.com>",
"curve_name": "secp256k1_decred", "curve_name": "secp256k1_decred",
"divisibility": 8,
"address_type": 3873, "address_type": 3873,
"address_type_p2sh": 3836, "address_type_p2sh": 3836,
"maxfee_kb": 10000000, "maxfee_kb": 10000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/digibyte/digibyte", "github": "https://github.com/digibyte/digibyte",
"maintainer": "DigiByte <dev@digibyte.co>", "maintainer": "DigiByte <dev@digibyte.co>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 30, "address_type": 30,
"address_type_p2sh": 63, "address_type_p2sh": 63,
"maxfee_kb": 500000, "maxfee_kb": 500000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/dogecoin/dogecoin", "github": "https://github.com/dogecoin/dogecoin",
"maintainer": "Karel Bilek <karel.bilek@satoshilabs.com>", "maintainer": "Karel Bilek <karel.bilek@satoshilabs.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 30, "address_type": 30,
"address_type_p2sh": 22, "address_type_p2sh": 22,
"maxfee_kb": 1000000000, "maxfee_kb": 1000000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/ElementsProject/elements", "github": "https://github.com/ElementsProject/elements",
"maintainer": "Roman Zeyde <mail@romanzey.de>", "maintainer": "Roman Zeyde <mail@romanzey.de>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 235, "address_type": 235,
"address_type_p2sh": 75, "address_type_p2sh": 75,
"maxfee_kb": 10000000, "maxfee_kb": 10000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/mvs-org/metaverse", "github": "https://github.com/mvs-org/metaverse",
"maintainer": "Sven Mutzl <sven@mutzl.org>", "maintainer": "Sven Mutzl <sven@mutzl.org>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 50, "address_type": 50,
"address_type_p2sh": 5, "address_type_p2sh": 5,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/faircoin/faircoin", "github": "https://github.com/faircoin/faircoin",
"maintainer": "Santi Noreña <santi@criptomart.net>", "maintainer": "Santi Noreña <santi@criptomart.net>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 95, "address_type": 95,
"address_type_p2sh": 36, "address_type_p2sh": 36,
"maxfee_kb": 10000000, "maxfee_kb": 10000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/FeatherCoin/Feathercoin", "github": "https://github.com/FeatherCoin/Feathercoin",
"maintainer": "Lucas Betschart <lucas@feathercoin.foundation>", "maintainer": "Lucas Betschart <lucas@feathercoin.foundation>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 14, "address_type": 14,
"address_type_p2sh": 5, "address_type_p2sh": 5,
"maxfee_kb": 40000000, "maxfee_kb": 40000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/floblockchain/flo", "github": "https://github.com/floblockchain/flo",
"maintainer": "Robert English <ksaredfx@gmail.com>", "maintainer": "Robert English <ksaredfx@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 35, "address_type": 35,
"address_type_p2sh": 94, "address_type_p2sh": 94,
"maxfee_kb": 40000000, "maxfee_kb": 40000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/fujicoin/fujicoin", "github": "https://github.com/fujicoin/fujicoin",
"maintainer": "motty <admin@fujicoin.org>", "maintainer": "motty <admin@fujicoin.org>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 36, "address_type": 36,
"address_type_p2sh": 16, "address_type_p2sh": 16,
"maxfee_kb": 1000000000, "maxfee_kb": 1000000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/gamecredits-project/gamecredits", "github": "https://github.com/gamecredits-project/gamecredits",
"maintainer": "Samad Sajanlal <samad.sajanlal@gmail.com>", "maintainer": "Samad Sajanlal <samad.sajanlal@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 38, "address_type": 38,
"address_type_p2sh": 62, "address_type_p2sh": 62,
"maxfee_kb": 5000000, "maxfee_kb": 5000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/gincoin-dev/gincoin-core", "github": "https://github.com/gincoin-dev/gincoin-core",
"maintainer": "Dragos Badea <dragos.badea@gincoin.io>", "maintainer": "Dragos Badea <dragos.badea@gincoin.io>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 38, "address_type": 38,
"address_type_p2sh": 10, "address_type_p2sh": 10,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/Groestlcoin/groestlcoin", "github": "https://github.com/Groestlcoin/groestlcoin",
"maintainer": "Yura Pakhuchiy <pakhuchiy@gmail.com>", "maintainer": "Yura Pakhuchiy <pakhuchiy@gmail.com>",
"curve_name": "secp256k1_groestl", "curve_name": "secp256k1_groestl",
"divisibility": 8,
"address_type": 36, "address_type": 36,
"address_type_p2sh": 5, "address_type_p2sh": 5,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/Groestlcoin/groestlcoin", "github": "https://github.com/Groestlcoin/groestlcoin",
"maintainer": "Yura Pakhuchiy <pakhuchiy@gmail.com>", "maintainer": "Yura Pakhuchiy <pakhuchiy@gmail.com>",
"curve_name": "secp256k1_groestl", "curve_name": "secp256k1_groestl",
"divisibility": 8,
"address_type": 111, "address_type": 111,
"address_type_p2sh": 196, "address_type_p2sh": 196,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/hatchpay/hatch", "github": "https://github.com/hatchpay/hatch",
"maintainer": "Hatch Support <support@hatch.ga>", "maintainer": "Hatch Support <support@hatch.ga>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 76, "address_type": 76,
"address_type_p2sh": 16, "address_type_p2sh": 16,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/hatchpay/hatch", "github": "https://github.com/hatchpay/hatch",
"maintainer": "Hatch Support <support@hatch.ga>", "maintainer": "Hatch Support <support@hatch.ga>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 140, "address_type": 140,
"address_type_p2sh": 19, "address_type_p2sh": 19,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/ZencashOfficial/zen", "github": "https://github.com/ZencashOfficial/zen",
"maintainer": "Power_VANO <vano@horizen.global>", "maintainer": "Power_VANO <vano@horizen.global>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 8329, "address_type": 8329,
"address_type_p2sh": 8342, "address_type_p2sh": 8342,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/komodoplatform/komodo", "github": "https://github.com/komodoplatform/komodo",
"maintainer": "Kadan Stadelmann <ca333@komodoplatform.com>", "maintainer": "Kadan Stadelmann <ca333@komodoplatform.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 60, "address_type": 60,
"address_type_p2sh": 85, "address_type_p2sh": 85,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/KotoDevelopers/koto", "github": "https://github.com/KotoDevelopers/koto",
"maintainer": "WO <wo@ko-to.org>", "maintainer": "WO <wo@ko-to.org>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 6198, "address_type": 6198,
"address_type_p2sh": 6203, "address_type_p2sh": 6203,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/litecoin-project/litecoin", "github": "https://github.com/litecoin-project/litecoin",
"maintainer": "Pavol Rusnak <stick@satoshilabs.com>", "maintainer": "Pavol Rusnak <stick@satoshilabs.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 48, "address_type": 48,
"address_type_p2sh": 50, "address_type_p2sh": 50,
"maxfee_kb": 40000000, "maxfee_kb": 40000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/litecoin-project/litecoin", "github": "https://github.com/litecoin-project/litecoin",
"maintainer": "Pavol Rusnak <stick@satoshilabs.com>", "maintainer": "Pavol Rusnak <stick@satoshilabs.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 111, "address_type": 111,
"address_type_p2sh": 58, "address_type_p2sh": 58,
"maxfee_kb": 40000000, "maxfee_kb": 40000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/monacoinproject/monacoin", "github": "https://github.com/monacoinproject/monacoin",
"maintainer": "cryptcoin-junkey <cryptcoin.junkey@gmail.com>", "maintainer": "cryptcoin-junkey <cryptcoin.junkey@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 50, "address_type": 50,
"address_type_p2sh": 55, "address_type_p2sh": 55,
"maxfee_kb": 5000000, "maxfee_kb": 5000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/muecoin/MUE", "github": "https://github.com/muecoin/MUE",
"maintainer": "Sotiris Blad <swthrhs@protonmail.com>", "maintainer": "Sotiris Blad <swthrhs@protonmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 16, "address_type": 16,
"address_type_p2sh": 76, "address_type_p2sh": 76,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/namecoin/namecoin-core", "github": "https://github.com/namecoin/namecoin-core",
"maintainer": "Pavol Rusnak <stick@satoshilabs.com>", "maintainer": "Pavol Rusnak <stick@satoshilabs.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 52, "address_type": 52,
"address_type_p2sh": 5, "address_type_p2sh": 5,
"maxfee_kb": 10000000, "maxfee_kb": 10000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/nixplatform/nixcore", "github": "https://github.com/nixplatform/nixcore",
"maintainer": "mattt21 <matt@nixplatform.io>", "maintainer": "mattt21 <matt@nixplatform.io>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 38, "address_type": 38,
"address_type_p2sh": 53, "address_type_p2sh": 53,
"maxfee_kb": 40000000, "maxfee_kb": 40000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/particl/particl-core", "github": "https://github.com/particl/particl-core",
"maintainer": "Ryno <ryno@particl.io>", "maintainer": "Ryno <ryno@particl.io>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 56, "address_type": 56,
"address_type_p2sh": 60, "address_type_p2sh": 60,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/particl/particl-core", "github": "https://github.com/particl/particl-core",
"maintainer": "Ryno <ryno@particl.io>", "maintainer": "Ryno <ryno@particl.io>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 118, "address_type": 118,
"address_type_p2sh": 122, "address_type_p2sh": 122,
"maxfee_kb": 10000000, "maxfee_kb": 10000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/FundacionPesetacoin/PesetacoinCore", "github": "https://github.com/FundacionPesetacoin/PesetacoinCore",
"maintainer": "Rw <info@pesetacoin.info>", "maintainer": "Rw <info@pesetacoin.info>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 47, "address_type": 47,
"address_type_p2sh": 22, "address_type_p2sh": 22,
"maxfee_kb": 1000000000, "maxfee_kb": 1000000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/PIVX-Project/PIVX", "github": "https://github.com/PIVX-Project/PIVX",
"maintainer": "Random Zebra <random.zebra@protonmail.com>", "maintainer": "Random Zebra <random.zebra@protonmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 30, "address_type": 30,
"address_type_p2sh": 13, "address_type_p2sh": 13,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/PIVX-Project/PIVX", "github": "https://github.com/PIVX-Project/PIVX",
"maintainer": "Random Zebra <random.zebra@protonmail.com>", "maintainer": "Random Zebra <random.zebra@protonmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 139, "address_type": 139,
"address_type_p2sh": 19, "address_type_p2sh": 19,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/polispay/polis", "github": "https://github.com/polispay/polis",
"maintainer": "Cronos <eabz@polispay.org>", "maintainer": "Cronos <eabz@polispay.org>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 55, "address_type": 55,
"address_type_p2sh": 56, "address_type_p2sh": 56,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/primecoin/primecoin", "github": "https://github.com/primecoin/primecoin",
"maintainer": "James Skrowvedeht <james@thedevworks.io>", "maintainer": "James Skrowvedeht <james@thedevworks.io>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 23, "address_type": 23,
"address_type_p2sh": 83, "address_type_p2sh": 83,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/qtumproject/qtum", "github": "https://github.com/qtumproject/qtum",
"maintainer": "CodeFace <codeface@qtum.info>", "maintainer": "CodeFace <codeface@qtum.info>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 58, "address_type": 58,
"address_type_p2sh": 50, "address_type_p2sh": 50,
"maxfee_kb": 40000000, "maxfee_kb": 40000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/qtumproject/qtum", "github": "https://github.com/qtumproject/qtum",
"maintainer": "CodeFace <codeface@qtum.info>", "maintainer": "CodeFace <codeface@qtum.info>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 120, "address_type": 120,
"address_type_p2sh": 110, "address_type_p2sh": 110,
"maxfee_kb": 40000000, "maxfee_kb": 40000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/RavenProject/Ravencoin", "github": "https://github.com/RavenProject/Ravencoin",
"maintainer": "Scotty <scotty.rvn@gmail.com>", "maintainer": "Scotty <scotty.rvn@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 60, "address_type": 60,
"address_type_p2sh": 122, "address_type_p2sh": 122,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/RitoProject", "github": "https://github.com/RitoProject",
"maintainer": "Scotty <scotty.rvn@gmail.com>", "maintainer": "Scotty <scotty.rvn@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 25, "address_type": 25,
"address_type_p2sh": 105, "address_type_p2sh": 105,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/SmartCash/Core-Smart", "github": "https://github.com/SmartCash/Core-Smart",
"maintainer": "Leandro Reinaux <leoreinaux@gmail.com>", "maintainer": "Leandro Reinaux <leoreinaux@gmail.com>",
"curve_name": "secp256k1_smart", "curve_name": "secp256k1_smart",
"divisibility": 8,
"address_type": 63, "address_type": 63,
"address_type_p2sh": 18, "address_type_p2sh": 18,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/SmartCash/Core-Smart", "github": "https://github.com/SmartCash/Core-Smart",
"maintainer": "Leandro Reinaux <leoreinaux@gmail.com>", "maintainer": "Leandro Reinaux <leoreinaux@gmail.com>",
"curve_name": "secp256k1_smart", "curve_name": "secp256k1_smart",
"divisibility": 8,
"address_type": 65, "address_type": 65,
"address_type_p2sh": 21, "address_type_p2sh": 21,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/X9Developers/XSN", "github": "https://github.com/X9Developers/XSN",
"maintainer": "Alexis Hernandez <alexis@alexitc.com>", "maintainer": "Alexis Hernandez <alexis@alexitc.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 76, "address_type": 76,
"address_type_p2sh": 16, "address_type_p2sh": 16,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/syscoin/syscoin", "github": "https://github.com/syscoin/syscoin",
"maintainer": "Jagdeep Sidhu <jsidhu@blockchainfoundry.co>", "maintainer": "Jagdeep Sidhu <jsidhu@blockchainfoundry.co>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 63, "address_type": 63,
"address_type_p2sh": 5, "address_type_p2sh": 5,
"maxfee_kb": 10000000, "maxfee_kb": 10000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/terracoin/terracoin", "github": "https://github.com/terracoin/terracoin",
"maintainer": "The Terracoin Foundation <support@terracoin.io>", "maintainer": "The Terracoin Foundation <support@terracoin.io>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 0, "address_type": 0,
"address_type_p2sh": 5, "address_type_p2sh": 5,
"maxfee_kb": 100000, "maxfee_kb": 100000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/unobtanium-official/unobtanium", "github": "https://github.com/unobtanium-official/unobtanium",
"maintainer": "choicesz <choicesz@unobtanium.uno>", "maintainer": "choicesz <choicesz@unobtanium.uno>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 130, "address_type": 130,
"address_type_p2sh": 30, "address_type_p2sh": 30,
"maxfee_kb": 2000000, "maxfee_kb": 2000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/vertcoin-project/vertcoin-core", "github": "https://github.com/vertcoin-project/vertcoin-core",
"maintainer": "Jochen Hoenicke <hoenicke@gmail.com>", "maintainer": "Jochen Hoenicke <hoenicke@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 71, "address_type": 71,
"address_type_p2sh": 5, "address_type_p2sh": 5,
"maxfee_kb": 40000000, "maxfee_kb": 40000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/viacoin", "github": "https://github.com/viacoin",
"maintainer": "romanornr <romanornr@gmail.com>", "maintainer": "romanornr <romanornr@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 71, "address_type": 71,
"address_type_p2sh": 33, "address_type_p2sh": 33,
"maxfee_kb": 40000000, "maxfee_kb": 40000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/VIPSTARCOIN/VIPSTARCOIN", "github": "https://github.com/VIPSTARCOIN/VIPSTARCOIN",
"maintainer": "y-chan <yuto_tetuota@yahoo.co.jp>", "maintainer": "y-chan <yuto_tetuota@yahoo.co.jp>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 70, "address_type": 70,
"address_type_p2sh": 50, "address_type_p2sh": 50,
"maxfee_kb": 40000000, "maxfee_kb": 40000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/zcash/zcash", "github": "https://github.com/zcash/zcash",
"maintainer": "Pavol Rusnak <stick@satoshilabs.com>", "maintainer": "Pavol Rusnak <stick@satoshilabs.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 7352, "address_type": 7352,
"address_type_p2sh": 7357, "address_type_p2sh": 7357,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/zcash/zcash", "github": "https://github.com/zcash/zcash",
"maintainer": "Pavol Rusnak <stick@satoshilabs.com>", "maintainer": "Pavol Rusnak <stick@satoshilabs.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 7461, "address_type": 7461,
"address_type_p2sh": 7354, "address_type_p2sh": 7354,
"maxfee_kb": 10000000, "maxfee_kb": 10000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/zcoinofficial/zcoin", "github": "https://github.com/zcoinofficial/zcoin",
"maintainer": "Yura Pakhuchiy <pakhuchiy@gmail.com>", "maintainer": "Yura Pakhuchiy <pakhuchiy@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 82, "address_type": 82,
"address_type_p2sh": 7, "address_type_p2sh": 7,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/zcoinofficial/zcoin", "github": "https://github.com/zcoinofficial/zcoin",
"maintainer": "Yura Pakhuchiy <pakhuchiy@gmail.com>", "maintainer": "Yura Pakhuchiy <pakhuchiy@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 65, "address_type": 65,
"address_type_p2sh": 178, "address_type_p2sh": 178,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/zcore-coin/zcore-2.0", "github": "https://github.com/zcore-coin/zcore-2.0",
"maintainer": "Erick Costa <erick@zcore.cash>", "maintainer": "Erick Costa <erick@zcore.cash>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 142, "address_type": 142,
"address_type_p2sh": 145, "address_type_p2sh": 145,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -6,6 +6,7 @@
"github": "https://github.com/zelcash", "github": "https://github.com/zelcash",
"maintainer": "Cabecinha84 <valter.cabecinha@gmail.com>", "maintainer": "Cabecinha84 <valter.cabecinha@gmail.com>",
"curve_name": "secp256k1", "curve_name": "secp256k1",
"divisibility": 8,
"address_type": 7352, "address_type": 7352,
"address_type_p2sh": 7357, "address_type_p2sh": 7357,
"maxfee_kb": 1000000, "maxfee_kb": 1000000,

View File

@ -12,6 +12,7 @@ class CoinInfo:
self, self,
coin_name: str, coin_name: str,
coin_shortcut: str, coin_shortcut: str,
divisibility: int,
address_type: int, address_type: int,
address_type_p2sh: int, address_type_p2sh: int,
maxfee_kb: int, maxfee_kb: int,
@ -33,6 +34,7 @@ class CoinInfo:
): ):
self.coin_name = coin_name self.coin_name = coin_name
self.coin_shortcut = coin_shortcut self.coin_shortcut = coin_shortcut
self.divisibility = divisibility
self.address_type = address_type self.address_type = address_type
self.address_type_p2sh = address_type_p2sh self.address_type_p2sh = address_type_p2sh
self.maxfee_kb = maxfee_kb self.maxfee_kb = maxfee_kb
@ -82,6 +84,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="BTC", coin_shortcut="BTC",
divisibility=8,
address_type=0, address_type=0,
address_type_p2sh=5, address_type_p2sh=5,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -105,6 +108,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="REGTEST", coin_shortcut="REGTEST",
divisibility=8,
address_type=111, address_type=111,
address_type_p2sh=196, address_type_p2sh=196,
maxfee_kb=10000000, maxfee_kb=10000000,
@ -128,6 +132,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="TEST", coin_shortcut="TEST",
divisibility=8,
address_type=111, address_type=111,
address_type_p2sh=196, address_type_p2sh=196,
maxfee_kb=10000000, maxfee_kb=10000000,
@ -154,6 +159,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="ACM", coin_shortcut="ACM",
divisibility=8,
address_type=53, address_type=53,
address_type_p2sh=55, address_type_p2sh=55,
maxfee_kb=40000000, maxfee_kb=40000000,
@ -177,6 +183,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="AXE", coin_shortcut="AXE",
divisibility=8,
address_type=55, address_type=55,
address_type_p2sh=16, address_type_p2sh=16,
maxfee_kb=100000, maxfee_kb=100000,
@ -200,6 +207,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="BELL", coin_shortcut="BELL",
divisibility=8,
address_type=25, address_type=25,
address_type_p2sh=85, address_type_p2sh=85,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -223,6 +231,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="BITG", coin_shortcut="BITG",
divisibility=8,
address_type=38, address_type=38,
address_type_p2sh=6, address_type_p2sh=6,
maxfee_kb=100000, maxfee_kb=100000,
@ -246,6 +255,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="ZNY", coin_shortcut="ZNY",
divisibility=8,
address_type=81, address_type=81,
address_type_p2sh=5, address_type_p2sh=5,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -269,6 +279,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="BCH", coin_shortcut="BCH",
divisibility=8,
address_type=0, address_type=0,
address_type_p2sh=5, address_type_p2sh=5,
maxfee_kb=500000, maxfee_kb=500000,
@ -292,6 +303,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="TBCH", coin_shortcut="TBCH",
divisibility=8,
address_type=111, address_type=111,
address_type_p2sh=196, address_type_p2sh=196,
maxfee_kb=10000000, maxfee_kb=10000000,
@ -315,6 +327,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="BTG", coin_shortcut="BTG",
divisibility=8,
address_type=38, address_type=38,
address_type_p2sh=23, address_type_p2sh=23,
maxfee_kb=500000, maxfee_kb=500000,
@ -338,6 +351,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="TBTG", coin_shortcut="TBTG",
divisibility=8,
address_type=111, address_type=111,
address_type_p2sh=196, address_type_p2sh=196,
maxfee_kb=500000, maxfee_kb=500000,
@ -361,6 +375,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="BTCP", coin_shortcut="BTCP",
divisibility=8,
address_type=4901, address_type=4901,
address_type_p2sh=5039, address_type_p2sh=5039,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -384,6 +399,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="XRC", coin_shortcut="XRC",
divisibility=8,
address_type=61, address_type=61,
address_type_p2sh=123, address_type_p2sh=123,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -407,6 +423,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="BTX", coin_shortcut="BTX",
divisibility=8,
address_type=3, address_type=3,
address_type_p2sh=125, address_type_p2sh=125,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -430,6 +447,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="BST", coin_shortcut="BST",
divisibility=8,
address_type=26, address_type=26,
address_type_p2sh=5, address_type_p2sh=5,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -453,6 +471,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="CPU", coin_shortcut="CPU",
divisibility=8,
address_type=28, address_type=28,
address_type_p2sh=30, address_type_p2sh=30,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -476,6 +495,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="CPC", coin_shortcut="CPC",
divisibility=8,
address_type=28, address_type=28,
address_type_p2sh=35, address_type_p2sh=35,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -499,6 +519,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="CRW", coin_shortcut="CRW",
divisibility=8,
address_type=95495, address_type=95495,
address_type_p2sh=95473, address_type_p2sh=95473,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -522,6 +543,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="DASH", coin_shortcut="DASH",
divisibility=8,
address_type=76, address_type=76,
address_type_p2sh=16, address_type_p2sh=16,
maxfee_kb=100000, maxfee_kb=100000,
@ -545,6 +567,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="tDASH", coin_shortcut="tDASH",
divisibility=8,
address_type=140, address_type=140,
address_type_p2sh=19, address_type_p2sh=19,
maxfee_kb=100000, maxfee_kb=100000,
@ -568,6 +591,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="DCR", coin_shortcut="DCR",
divisibility=8,
address_type=1855, address_type=1855,
address_type_p2sh=1818, address_type_p2sh=1818,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -591,6 +615,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="TDCR", coin_shortcut="TDCR",
divisibility=8,
address_type=3873, address_type=3873,
address_type_p2sh=3836, address_type_p2sh=3836,
maxfee_kb=10000000, maxfee_kb=10000000,
@ -614,6 +639,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="DGB", coin_shortcut="DGB",
divisibility=8,
address_type=30, address_type=30,
address_type_p2sh=63, address_type_p2sh=63,
maxfee_kb=500000, maxfee_kb=500000,
@ -637,6 +663,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="DOGE", coin_shortcut="DOGE",
divisibility=8,
address_type=30, address_type=30,
address_type_p2sh=22, address_type_p2sh=22,
maxfee_kb=1000000000, maxfee_kb=1000000000,
@ -660,6 +687,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="ELEMENTS", coin_shortcut="ELEMENTS",
divisibility=8,
address_type=235, address_type=235,
address_type_p2sh=75, address_type_p2sh=75,
maxfee_kb=10000000, maxfee_kb=10000000,
@ -683,6 +711,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="FAIR", coin_shortcut="FAIR",
divisibility=8,
address_type=95, address_type=95,
address_type_p2sh=36, address_type_p2sh=36,
maxfee_kb=10000000, maxfee_kb=10000000,
@ -706,6 +735,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="FTC", coin_shortcut="FTC",
divisibility=8,
address_type=14, address_type=14,
address_type_p2sh=5, address_type_p2sh=5,
maxfee_kb=40000000, maxfee_kb=40000000,
@ -729,6 +759,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="FLO", coin_shortcut="FLO",
divisibility=8,
address_type=35, address_type=35,
address_type_p2sh=94, address_type_p2sh=94,
maxfee_kb=40000000, maxfee_kb=40000000,
@ -752,6 +783,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="FJC", coin_shortcut="FJC",
divisibility=8,
address_type=36, address_type=36,
address_type_p2sh=16, address_type_p2sh=16,
maxfee_kb=1000000000, maxfee_kb=1000000000,
@ -775,6 +807,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="GIN", coin_shortcut="GIN",
divisibility=8,
address_type=38, address_type=38,
address_type_p2sh=10, address_type_p2sh=10,
maxfee_kb=100000, maxfee_kb=100000,
@ -798,6 +831,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="GAME", coin_shortcut="GAME",
divisibility=8,
address_type=38, address_type=38,
address_type_p2sh=62, address_type_p2sh=62,
maxfee_kb=5000000, maxfee_kb=5000000,
@ -821,6 +855,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="GRS", coin_shortcut="GRS",
divisibility=8,
address_type=36, address_type=36,
address_type_p2sh=5, address_type_p2sh=5,
maxfee_kb=100000, maxfee_kb=100000,
@ -844,6 +879,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="tGRS", coin_shortcut="tGRS",
divisibility=8,
address_type=111, address_type=111,
address_type_p2sh=196, address_type_p2sh=196,
maxfee_kb=100000, maxfee_kb=100000,
@ -867,6 +903,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="HATCH", coin_shortcut="HATCH",
divisibility=8,
address_type=76, address_type=76,
address_type_p2sh=16, address_type_p2sh=16,
maxfee_kb=100000, maxfee_kb=100000,
@ -890,6 +927,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="tHATCH", coin_shortcut="tHATCH",
divisibility=8,
address_type=140, address_type=140,
address_type_p2sh=19, address_type_p2sh=19,
maxfee_kb=100000, maxfee_kb=100000,
@ -913,6 +951,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="ZEN", coin_shortcut="ZEN",
divisibility=8,
address_type=8329, address_type=8329,
address_type_p2sh=8342, address_type_p2sh=8342,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -936,6 +975,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="KMD", coin_shortcut="KMD",
divisibility=8,
address_type=60, address_type=60,
address_type_p2sh=85, address_type_p2sh=85,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -959,6 +999,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="KOTO", coin_shortcut="KOTO",
divisibility=8,
address_type=6198, address_type=6198,
address_type_p2sh=6203, address_type_p2sh=6203,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -982,6 +1023,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="LTC", coin_shortcut="LTC",
divisibility=8,
address_type=48, address_type=48,
address_type_p2sh=50, address_type_p2sh=50,
maxfee_kb=40000000, maxfee_kb=40000000,
@ -1005,6 +1047,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="tLTC", coin_shortcut="tLTC",
divisibility=8,
address_type=111, address_type=111,
address_type_p2sh=58, address_type_p2sh=58,
maxfee_kb=40000000, maxfee_kb=40000000,
@ -1028,6 +1071,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="ETP", coin_shortcut="ETP",
divisibility=8,
address_type=50, address_type=50,
address_type_p2sh=5, address_type_p2sh=5,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -1051,6 +1095,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="MONA", coin_shortcut="MONA",
divisibility=8,
address_type=50, address_type=50,
address_type_p2sh=55, address_type_p2sh=55,
maxfee_kb=5000000, maxfee_kb=5000000,
@ -1074,6 +1119,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="MUE", coin_shortcut="MUE",
divisibility=8,
address_type=16, address_type=16,
address_type_p2sh=76, address_type_p2sh=76,
maxfee_kb=100000, maxfee_kb=100000,
@ -1097,6 +1143,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="NIX", coin_shortcut="NIX",
divisibility=8,
address_type=38, address_type=38,
address_type_p2sh=53, address_type_p2sh=53,
maxfee_kb=40000000, maxfee_kb=40000000,
@ -1120,6 +1167,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="NMC", coin_shortcut="NMC",
divisibility=8,
address_type=52, address_type=52,
address_type_p2sh=5, address_type_p2sh=5,
maxfee_kb=10000000, maxfee_kb=10000000,
@ -1143,6 +1191,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="PIVX", coin_shortcut="PIVX",
divisibility=8,
address_type=30, address_type=30,
address_type_p2sh=13, address_type_p2sh=13,
maxfee_kb=100000, maxfee_kb=100000,
@ -1166,6 +1215,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="tPIVX", coin_shortcut="tPIVX",
divisibility=8,
address_type=139, address_type=139,
address_type_p2sh=19, address_type_p2sh=19,
maxfee_kb=100000, maxfee_kb=100000,
@ -1189,6 +1239,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="PART", coin_shortcut="PART",
divisibility=8,
address_type=56, address_type=56,
address_type_p2sh=60, address_type_p2sh=60,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -1212,6 +1263,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="tPART", coin_shortcut="tPART",
divisibility=8,
address_type=118, address_type=118,
address_type_p2sh=122, address_type_p2sh=122,
maxfee_kb=10000000, maxfee_kb=10000000,
@ -1235,6 +1287,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="PTC", coin_shortcut="PTC",
divisibility=8,
address_type=47, address_type=47,
address_type_p2sh=22, address_type_p2sh=22,
maxfee_kb=1000000000, maxfee_kb=1000000000,
@ -1258,6 +1311,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="POLIS", coin_shortcut="POLIS",
divisibility=8,
address_type=55, address_type=55,
address_type_p2sh=56, address_type_p2sh=56,
maxfee_kb=100000, maxfee_kb=100000,
@ -1281,6 +1335,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="XPM", coin_shortcut="XPM",
divisibility=8,
address_type=23, address_type=23,
address_type_p2sh=83, address_type_p2sh=83,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -1304,6 +1359,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="QTUM", coin_shortcut="QTUM",
divisibility=8,
address_type=58, address_type=58,
address_type_p2sh=50, address_type_p2sh=50,
maxfee_kb=40000000, maxfee_kb=40000000,
@ -1327,6 +1383,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="tQTUM", coin_shortcut="tQTUM",
divisibility=8,
address_type=120, address_type=120,
address_type_p2sh=110, address_type_p2sh=110,
maxfee_kb=40000000, maxfee_kb=40000000,
@ -1350,6 +1407,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="RVN", coin_shortcut="RVN",
divisibility=8,
address_type=60, address_type=60,
address_type_p2sh=122, address_type_p2sh=122,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -1373,6 +1431,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="RITO", coin_shortcut="RITO",
divisibility=8,
address_type=25, address_type=25,
address_type_p2sh=105, address_type_p2sh=105,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -1396,6 +1455,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="SMART", coin_shortcut="SMART",
divisibility=8,
address_type=63, address_type=63,
address_type_p2sh=18, address_type_p2sh=18,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -1419,6 +1479,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="tSMART", coin_shortcut="tSMART",
divisibility=8,
address_type=65, address_type=65,
address_type_p2sh=21, address_type_p2sh=21,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -1442,6 +1503,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="XSN", coin_shortcut="XSN",
divisibility=8,
address_type=76, address_type=76,
address_type_p2sh=16, address_type_p2sh=16,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -1465,6 +1527,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="SYS", coin_shortcut="SYS",
divisibility=8,
address_type=63, address_type=63,
address_type_p2sh=5, address_type_p2sh=5,
maxfee_kb=10000000, maxfee_kb=10000000,
@ -1488,6 +1551,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="UNO", coin_shortcut="UNO",
divisibility=8,
address_type=130, address_type=130,
address_type_p2sh=30, address_type_p2sh=30,
maxfee_kb=2000000, maxfee_kb=2000000,
@ -1511,6 +1575,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="VIPS", coin_shortcut="VIPS",
divisibility=8,
address_type=70, address_type=70,
address_type_p2sh=50, address_type_p2sh=50,
maxfee_kb=40000000, maxfee_kb=40000000,
@ -1534,6 +1599,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="VTC", coin_shortcut="VTC",
divisibility=8,
address_type=71, address_type=71,
address_type_p2sh=5, address_type_p2sh=5,
maxfee_kb=40000000, maxfee_kb=40000000,
@ -1557,6 +1623,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="VIA", coin_shortcut="VIA",
divisibility=8,
address_type=71, address_type=71,
address_type_p2sh=33, address_type_p2sh=33,
maxfee_kb=40000000, maxfee_kb=40000000,
@ -1580,6 +1647,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="ZCR", coin_shortcut="ZCR",
divisibility=8,
address_type=142, address_type=142,
address_type_p2sh=145, address_type_p2sh=145,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -1603,6 +1671,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="ZEC", coin_shortcut="ZEC",
divisibility=8,
address_type=7352, address_type=7352,
address_type_p2sh=7357, address_type_p2sh=7357,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -1626,6 +1695,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="TAZ", coin_shortcut="TAZ",
divisibility=8,
address_type=7461, address_type=7461,
address_type_p2sh=7354, address_type_p2sh=7354,
maxfee_kb=10000000, maxfee_kb=10000000,
@ -1649,6 +1719,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="XZC", coin_shortcut="XZC",
divisibility=8,
address_type=82, address_type=82,
address_type_p2sh=7, address_type_p2sh=7,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -1672,6 +1743,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="tXZC", coin_shortcut="tXZC",
divisibility=8,
address_type=65, address_type=65,
address_type_p2sh=178, address_type_p2sh=178,
maxfee_kb=1000000, maxfee_kb=1000000,
@ -1695,6 +1767,7 @@ def by_name(name: str) -> CoinInfo:
return CoinInfo( return CoinInfo(
coin_name=name, coin_name=name,
coin_shortcut="ZEL", coin_shortcut="ZEL",
divisibility=8,
address_type=7352, address_type=7352,
address_type_p2sh=7357, address_type_p2sh=7357,
maxfee_kb=1000000, maxfee_kb=1000000,

View File

@ -12,6 +12,7 @@ class CoinInfo:
self, self,
coin_name: str, coin_name: str,
coin_shortcut: str, coin_shortcut: str,
divisibility: int,
address_type: int, address_type: int,
address_type_p2sh: int, address_type_p2sh: int,
maxfee_kb: int, maxfee_kb: int,
@ -33,6 +34,7 @@ class CoinInfo:
): ):
self.coin_name = coin_name self.coin_name = coin_name
self.coin_shortcut = coin_shortcut self.coin_shortcut = coin_shortcut
self.divisibility = divisibility
self.address_type = address_type self.address_type = address_type
self.address_type_p2sh = address_type_p2sh self.address_type_p2sh = address_type_p2sh
self.maxfee_kb = maxfee_kb self.maxfee_kb = maxfee_kb
@ -90,6 +92,7 @@ def optional_dict(x):
ATTRIBUTES = ( ATTRIBUTES = (
("coin_name", lambda _: "name"), ("coin_name", lambda _: "name"),
("coin_shortcut", black_repr), ("coin_shortcut", black_repr),
("divisibility", int),
("address_type", int), ("address_type", int),
("address_type_p2sh", int), ("address_type_p2sh", int),
("maxfee_kb", int), ("maxfee_kb", int),

View File

@ -9,7 +9,7 @@ _LOCKTIME_TIMESTAMP_MIN_VALUE = const(500000000)
def format_coin_amount(amount, coin): def format_coin_amount(amount, coin):
return "%s %s" % (format_amount(amount, 8), coin.coin_shortcut) return "%s %s" % (format_amount(amount, coin.divisibility), coin.coin_shortcut)
def split_address(address): def split_address(address):

View File

@ -29,12 +29,11 @@ const CoinInfo coins[COINS_COUNT] = {
.coin_shortcut = ${c_str(" " + c.coin_shortcut)}, .coin_shortcut = ${c_str(" " + c.coin_shortcut)},
.maxfee_kb = ${c_int(c.maxfee_kb)}, .maxfee_kb = ${c_int(c.maxfee_kb)},
.signed_message_header = ${signed_message_header(c.signed_message_header)}, .signed_message_header = ${signed_message_header(c.signed_message_header)},
.has_address_type = ${defined(c.address_type)},
.has_address_type_p2sh = ${defined(c.address_type_p2sh)},
.has_segwit = ${c_bool(c.segwit)}, .has_segwit = ${c_bool(c.segwit)},
.has_fork_id = ${defined(c.fork_id)}, .has_fork_id = ${defined(c.fork_id)},
.force_bip143 = ${c_bool(c.force_bip143)}, .force_bip143 = ${c_bool(c.force_bip143)},
.decred = ${c_bool(c.decred)}, .decred = ${c_bool(c.decred)},
.divisibility = ${c.divisibility},
.address_type = ${c.address_type}, .address_type = ${c.address_type},
.address_type_p2sh = ${c.address_type_p2sh}, .address_type_p2sh = ${c.address_type_p2sh},
.xpub_magic = ${hex(c.xpub_magic)}, .xpub_magic = ${hex(c.xpub_magic)},

View File

@ -65,13 +65,11 @@ bool coinExtractAddressType(const CoinInfo *coin, const char *addr,
bool coinExtractAddressTypeRaw(const CoinInfo *coin, const uint8_t *addr_raw, bool coinExtractAddressTypeRaw(const CoinInfo *coin, const uint8_t *addr_raw,
uint32_t *address_type) { uint32_t *address_type) {
if (coin->has_address_type && if (address_check_prefix(addr_raw, coin->address_type)) {
address_check_prefix(addr_raw, coin->address_type)) {
*address_type = coin->address_type; *address_type = coin->address_type;
return true; return true;
} }
if (coin->has_address_type_p2sh && if (address_check_prefix(addr_raw, coin->address_type_p2sh)) {
address_check_prefix(addr_raw, coin->address_type_p2sh)) {
*address_type = coin->address_type_p2sh; *address_type = coin->address_type_p2sh;
return true; return true;
} }

View File

@ -31,8 +31,7 @@ typedef struct _CoinInfo {
const char *coin_shortcut; const char *coin_shortcut;
uint64_t maxfee_kb; uint64_t maxfee_kb;
const char *signed_message_header; const char *signed_message_header;
bool has_address_type; uint32_t divisibility;
bool has_address_type_p2sh;
bool has_segwit; bool has_segwit;
bool has_fork_id; bool has_fork_id;
bool force_bip143; bool force_bip143;

View File

@ -165,7 +165,6 @@ static bool path_mismatched(const CoinInfo *coin, const GetAddress *msg) {
if (msg->address_n[0] == (0x80000000 + 49)) { if (msg->address_n[0] == (0x80000000 + 49)) {
mismatch |= (msg->script_type != InputScriptType_SPENDP2SHWITNESS); mismatch |= (msg->script_type != InputScriptType_SPENDP2SHWITNESS);
mismatch |= !coin->has_segwit; mismatch |= !coin->has_segwit;
mismatch |= !coin->has_address_type_p2sh;
mismatch |= (msg->address_n_count != 5); mismatch |= (msg->address_n_count != 5);
mismatch |= (msg->address_n[1] != coin->coin_type); mismatch |= (msg->address_n[1] != coin->coin_type);
mismatch |= (msg->address_n[2] & 0x80000000) == 0; mismatch |= (msg->address_n[2] & 0x80000000) == 0;

View File

@ -35,8 +35,6 @@
#include "timer.h" #include "timer.h"
#include "util.h" #include "util.h"
#define BITCOIN_DIVISIBILITY (8)
#if !BITCOIN_ONLY #if !BITCOIN_ONLY
static const char *slip44_extras(uint32_t coin_type) { static const char *slip44_extras(uint32_t coin_type) {
@ -93,12 +91,12 @@ static const char *address_n_str(const uint32_t *address_n,
abbr = coin->coin_shortcut + 1; abbr = coin->coin_shortcut + 1;
} }
} else if (p2sh_segwit) { } else if (p2sh_segwit) {
if (coin && coin->has_segwit && coin->has_address_type_p2sh) { if (coin && coin->has_segwit) {
abbr = coin->coin_shortcut + 1; abbr = coin->coin_shortcut + 1;
} }
} else { } else {
if (coin) { if (coin) {
if (coin->has_segwit && coin->has_address_type_p2sh) { if (coin->has_segwit) {
legacy = true; legacy = true;
} }
abbr = coin->coin_shortcut + 1; abbr = coin->coin_shortcut + 1;
@ -346,7 +344,7 @@ static void render_address_dialog(const CoinInfo *coin, const char *address,
void layoutConfirmOutput(const CoinInfo *coin, const TxOutputType *out) { void layoutConfirmOutput(const CoinInfo *coin, const TxOutputType *out) {
char str_out[32 + 3] = {0}; char str_out[32 + 3] = {0};
bn_format_uint64(out->amount, NULL, coin->coin_shortcut, BITCOIN_DIVISIBILITY, bn_format_uint64(out->amount, NULL, coin->coin_shortcut, coin->divisibility,
0, false, str_out, sizeof(str_out) - 3); 0, false, str_out, sizeof(str_out) - 3);
strlcat(str_out, " to", sizeof(str_out)); strlcat(str_out, " to", sizeof(str_out));
const char *address = out->address; const char *address = out->address;
@ -389,8 +387,8 @@ void layoutConfirmOmni(const uint8_t *data, uint32_t size) {
uint64_t amount_be = 0, amount = 0; uint64_t amount_be = 0, amount = 0;
memcpy(&amount_be, data + 12, sizeof(uint64_t)); memcpy(&amount_be, data + 12, sizeof(uint64_t));
REVERSE64(amount_be, amount); REVERSE64(amount_be, amount);
bn_format_uint64(amount, NULL, suffix, divisible ? BITCOIN_DIVISIBILITY : 0, bn_format_uint64(amount, NULL, suffix, divisible ? 8 : 0, 0, false, str_out,
0, false, str_out, sizeof(str_out)); sizeof(str_out));
} else { } else {
desc = _("Unknown transaction"); desc = _("Unknown transaction");
str_out[0] = 0; str_out[0] = 0;
@ -424,10 +422,10 @@ void layoutConfirmOpReturn(const uint8_t *data, uint32_t size) {
void layoutConfirmTx(const CoinInfo *coin, uint64_t amount_out, void layoutConfirmTx(const CoinInfo *coin, uint64_t amount_out,
uint64_t amount_fee) { uint64_t amount_fee) {
char str_out[32] = {0}, str_fee[32] = {0}; char str_out[32] = {0}, str_fee[32] = {0};
bn_format_uint64(amount_out, NULL, coin->coin_shortcut, BITCOIN_DIVISIBILITY, bn_format_uint64(amount_out, NULL, coin->coin_shortcut, coin->divisibility, 0,
0, false, str_out, sizeof(str_out)); false, str_out, sizeof(str_out));
bn_format_uint64(amount_fee, NULL, coin->coin_shortcut, BITCOIN_DIVISIBILITY, bn_format_uint64(amount_fee, NULL, coin->coin_shortcut, coin->divisibility, 0,
0, false, str_fee, sizeof(str_fee)); false, str_fee, sizeof(str_fee));
layoutDialogSwipe(&bmp_icon_question, _("Cancel"), _("Confirm"), NULL, layoutDialogSwipe(&bmp_icon_question, _("Cancel"), _("Confirm"), NULL,
_("Really send"), str_out, _("from your wallet?"), _("Really send"), str_out, _("from your wallet?"),
_("Fee included:"), str_fee, NULL); _("Fee included:"), str_fee, NULL);
@ -435,8 +433,8 @@ void layoutConfirmTx(const CoinInfo *coin, uint64_t amount_out,
void layoutFeeOverThreshold(const CoinInfo *coin, uint64_t fee) { void layoutFeeOverThreshold(const CoinInfo *coin, uint64_t fee) {
char str_fee[32] = {0}; char str_fee[32] = {0};
bn_format_uint64(fee, NULL, coin->coin_shortcut, BITCOIN_DIVISIBILITY, 0, bn_format_uint64(fee, NULL, coin->coin_shortcut, coin->divisibility, 0, false,
false, str_fee, sizeof(str_fee)); str_fee, sizeof(str_fee));
layoutDialogSwipe(&bmp_icon_question, _("Cancel"), _("Confirm"), NULL, layoutDialogSwipe(&bmp_icon_question, _("Cancel"), _("Confirm"), NULL,
_("Fee"), str_fee, _("is unexpectedly high."), NULL, _("Fee"), str_fee, _("is unexpectedly high."), NULL,
_("Send anyway?"), NULL); _("Send anyway?"), NULL);

View File

@ -130,9 +130,6 @@ bool compute_address(const CoinInfo *coin, InputScriptType script_type,
if (!coin->has_segwit) { if (!coin->has_segwit) {
return 0; return 0;
} }
if (!coin->has_address_type_p2sh) {
return 0;
}
raw[0] = 0; // push version raw[0] = 0; // push version
raw[1] = 32; // push 32 bytes raw[1] = 32; // push 32 bytes
memcpy(raw + 2, digest, 32); // push hash memcpy(raw + 2, digest, 32); // push hash
@ -175,9 +172,6 @@ bool compute_address(const CoinInfo *coin, InputScriptType script_type,
if (!coin->has_segwit) { if (!coin->has_segwit) {
return 0; return 0;
} }
if (!coin->has_address_type_p2sh) {
return 0;
}
ecdsa_get_address_segwit_p2sh( ecdsa_get_address_segwit_p2sh(
node->public_key, coin->address_type_p2sh, coin->curve->hasher_pubkey, node->public_key, coin->address_type_p2sh, coin->curve->hasher_pubkey,
coin->curve->hasher_base58, address, MAX_ADDR_SIZE); coin->curve->hasher_base58, address, MAX_ADDR_SIZE);
@ -270,8 +264,8 @@ int compile_output(const CoinInfo *coin, const HDNode *root, TxOutputType *in,
addr_raw_len = base58_decode_check(in->address, coin->curve->hasher_base58, addr_raw_len = base58_decode_check(in->address, coin->curve->hasher_base58,
addr_raw, MAX_ADDR_RAW_SIZE); addr_raw, MAX_ADDR_RAW_SIZE);
size_t prefix_len = 0; size_t prefix_len = 0;
if (coin->has_address_type // p2pkh // p2pkh
&& addr_raw_len == if (addr_raw_len ==
20 + (prefix_len = address_prefix_bytes_len(coin->address_type)) && 20 + (prefix_len = address_prefix_bytes_len(coin->address_type)) &&
address_check_prefix(addr_raw, coin->address_type)) { address_check_prefix(addr_raw, coin->address_type)) {
out->script_pubkey.bytes[0] = 0x76; // OP_DUP out->script_pubkey.bytes[0] = 0x76; // OP_DUP
@ -281,8 +275,9 @@ int compile_output(const CoinInfo *coin, const HDNode *root, TxOutputType *in,
out->script_pubkey.bytes[23] = 0x88; // OP_EQUALVERIFY out->script_pubkey.bytes[23] = 0x88; // OP_EQUALVERIFY
out->script_pubkey.bytes[24] = 0xAC; // OP_CHECKSIG out->script_pubkey.bytes[24] = 0xAC; // OP_CHECKSIG
out->script_pubkey.size = 25; out->script_pubkey.size = 25;
} else if (coin->has_address_type_p2sh // p2sh } else
&& addr_raw_len == 20 + (prefix_len = address_prefix_bytes_len( // p2sh
if (addr_raw_len == 20 + (prefix_len = address_prefix_bytes_len(
coin->address_type_p2sh)) && coin->address_type_p2sh)) &&
address_check_prefix(addr_raw, coin->address_type_p2sh)) { address_check_prefix(addr_raw, coin->address_type_p2sh)) {
out->script_pubkey.bytes[0] = 0xA9; // OP_HASH_160 out->script_pubkey.bytes[0] = 0xA9; // OP_HASH_160
@ -880,11 +875,9 @@ uint32_t tx_output_weight(const CoinInfo *coin, const TxOutputType *txoutput) {
addr_raw_len = addr_raw_len =
base58_decode_check(txoutput->address, coin->curve->hasher_base58, base58_decode_check(txoutput->address, coin->curve->hasher_base58,
addr_raw, MAX_ADDR_RAW_SIZE); addr_raw, MAX_ADDR_RAW_SIZE);
if (coin->has_address_type && if (address_check_prefix(addr_raw, coin->address_type)) {
address_check_prefix(addr_raw, coin->address_type)) {
output_script_size = TXSIZE_P2PKHASH; output_script_size = TXSIZE_P2PKHASH;
} else if (coin->has_address_type_p2sh && } else if (address_check_prefix(addr_raw, coin->address_type_p2sh)) {
address_check_prefix(addr_raw, coin->address_type_p2sh)) {
output_script_size = TXSIZE_P2SCRIPT; output_script_size = TXSIZE_P2SCRIPT;
} }
} }