trezor / trezor-common

:lock: Don't post issues/PRs to here, use the new monorepo:
https://github.com/trezor/trezor-firmware
GNU Lesser General Public License v3.0
91 stars 232 forks source link

Minor: is regtest supported? #270

Closed afk11 closed 5 years ago

afk11 commented 5 years ago

A while back some wallets changed the regtest bech32 prefix from 'tb' to 'bcrt'. This means that trezor will fail to accept the newer form (from bitcoin core, electrum, and other libraries)

I'm unsure if regtest is a desired network here, so opening this to get your opinion on it!

afk11 commented 5 years ago

@slush0 @prusnak bump

tldr: regtest worked magically before, but broken now cuz everyone else has upgraded, making it a pain in the ass to do any integration testing right now.

prusnak commented 5 years ago

We are following SLIP-0173: https://github.com/satoshilabs/slips/blob/master/slip-0173.md

If Bech32 prefix changed in the original implementation, that file is the place where the change should start.

matejcik commented 5 years ago

that document lists bcrt correctly though. but to track that we'd need a separate entry in defs/bitcoin for bitcoin regrtest. i believe the original issue is about if we want that or not

afk11 commented 5 years ago

@matejcik yes, I believe that would be necessary at this point since it's diverged from testnet.

prusnak commented 5 years ago

@afk11 Let's get this added. Please create a copy of bitcoin_testnet.json named bitcoin_regtest.json here: https://github.com/trezor/trezor-firmware/blob/master/common/defs/bitcoin/