How can a user or wallet have multiple addresses at all if out of a private key can be generated only a single public key? A user of a wallet, regardelss of a version of a wallet, can generate as many addresses as he wants, right?
Since an address is basically a public key, and in &quot;private-public key&quot; cryptograpthy there's only one public key that corresponds to a private key, how is generating lots of addresses possible at all?
This Can same private key generate multiple addresses? isn't what I'm asking about.
Modern wallets are hierarchical deterministic (HD) wallets.
A root key is used to derive an effectively infinite number of private keys using systems such as BIP32.
Each derivation results in a single public/private keypair, and hence a single address at that level.
Prior to the usage of HD wallets, things were a bit more straighforward - every time you requested a new address from the wallet, it would generate a new, random private key and store it in the wallet file, and give you the address created by the public key for the new private key.
The move to HD wallets was done for ergonomic and safety reasons - in older wallets, if you did not make a backup after every new address, you would lose any addresses generated after your most recent backup if the wallet file was lost. With HD wallets, only the root key (commonly a BIP39 mnemonic) must be backed up - all addresses and their keys can be recovered from it.