3

I know that they cannot be mixed case due to their BIP but what was the intention behind this idea and would it be problematical to convert a mixed case bech32 address to a lower/upper case bech32 address?

  • 1
    Correcting a few wrong case characters wouldn't be the end of the world but it's probably better to tell the user it's all one case. This will allow them to reinterpret what they're reading in light of this understanding which might be different than just converting the case. – G. Maxwell Apr 27 at 2:58
1

Having only one case (which is really no case) makes bech32 less prone to handwriting errors. It makes it easier for people to write down a bech32 address as they don't need to be concerned about which casing to use and to distinguish cases. It makes it easier to type in an address as it doesn't matter whether something was accidentally the wrong case.

In general, it is easier to deal with a character set that does not have mixed case characters.

The BIP specifies that mixed case shouldn't be used so that parsers don't mistakenly treat random strings as valid bech32 strings. While it wouldn't matter if a parser normalized the strings to a particular case, doing so would increase the probability that something that is not bech32 is interpreted as bech32. This has some money losing risk so precaution is necessary.

| improve this answer | |
  • 1
    This is incorrect. BIP173 specifies that parsers should reject mixed case strings. The reason is that it simply massively reduces the chance that random strings are treated as valid bech32. – Pieter Wuille Nov 28 '19 at 17:39
  • @PieterWuille Updated my answer – Andrew Chow Nov 28 '19 at 18:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.