Bech32 guards improving security and UX #134
dr-orlovsky
started this conversation in
Ideas
Replies: 1 comment
-
Command-line tool to generate guards: $ cargo install crc32mnemo
$ cargo crc32mnemo --bech32 bc1q0x8502jd7qruk5z4psrqjlr5x8cg9uqllpn0u4
HRP bc
Variant BIP173
Data 00798f47aa4df007cb50550c06097c7431f082f01f
CRC32 3bfaa607
Mnemonic dream-helium-aspect The tool can be found in https://github.com/dr-orlovsky/crc32mnemo/ |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Bech32(m) data are implying Bech32 string against an original, for instance to ensure that the clipboard data were not malleated or other types of MitM attacks hasn't happened. The verification are done either visually or by reading out parts of the Bech32m string in loud.
Bech32(m) encoded data can hardly be verified visually or read at whole because of the lengthy nature and pure noise (from the human perspective) content, since the encoding does not imply any human-meaning semantic.
While Bech32 was designed to minimize probability of errors during data transfer and simplify verification by humans, it hardly reaches the end goal.
First, not all users know that the last 6 characters of the bech32(m) encoding are the checksum, and they has to be checked first and foremost. Quite opposite, people start with the initial part, which contains the least important information and mostly the same for all bech32 strings (for instance, first 4 characters in all bitcoin addresses on the same wallet are equal
bc1q
, thus efficiently resulting that users check just 2 or 3 characters (=1.5-2 bytes) of critical data).Second, there is no simply pronounced way of representing the identity of the whole bech32 string.
I propose an extension to bech32 data, called guard, which is a three word mnemonic following the original bech32 string, like in
bc1q0x8502jd7qruk5z4psrqjlr5x8cg9uqllpn0u4_dream_helium_aspect
. Here the guard isdream_helium_aspect
and it provides a easily readable and visually distinguishable mnemonic representation of CRC32 checksum over bech32 address data.The guard can be used for simple verification and provides the same guarantees as verifying the last six characters of the bech32 string
lpn0u4
)Beta Was this translation helpful? Give feedback.
All reactions