I have a few questions regarding wallets and BIP44/49/89 standards.
In many places I found that BIP44 is used for traditional addresses (P2PKH) and that the path is
m/44'/.... Also, if we want another type of address, say P2WPH, then we use different standard, it this case BIP84 and the path
m/84'/..., and so on...
One of the places I found it would be the following answer: link.
Second place: link. Andrew Chow wrote the following:
By this logic, the xprv and xpub prefixes used previously then indicate that legacy addresses should be made. Hence BIP 44 shows xprv.
So I started to think that way too. That is, the type of the address is determined by the standard used. So:
- BIP44 - traditional addresses (P2PKH), XPUB (it's defined in BIP32 but used here),
- BIP49 - P2WPKH-nested-in-P2SH, YPUB,
- BIP84 - P2WPH, ZPUB,
That's what I thought until I looked at golang's implementation of bitcoin wallet. Namely, it says there that it uses only BIP44 standard. Since the given wallet is used (I assume) for all addresses (not just P2PKH, P2WPKH-nested-in-P2SH and P2WPH, but for all as many as there are), I got a bit confused and started to think differently about these standards and how they are used. So I have a two questions.
1. BIP44 is just a derivation path standard, it doesn't decide what type of address you have to generate from it? You can generate any "type" of address you want and that's just how the golang bitcoin wallet works? It uses the BIP44 derivation path, but leaf-level tree keys are used for all address types.
2. Although BIP44 can be used for all addresses (if the answer to the previous question is yes), there are also standards that define other derivation paths such as BIP49 and BIP84 whose purpose is only to separate keys intended for a certain type of address to other derivation paths, nothing but that? But even if, for example, BIP84 says it's for P2WPKH, it's just a derivation path, nothing else. I mean, you can also use P2PKH here (it's weird, but you can) since it's a derivation path? Actually, they just wanted to kind of point out that if you use P2WPKH then a different derivation path is used, but you can still use the BIP44 derivation path?