Wallet, Accounts & Address

Hi, this might be basic, however creating a bit of confusion for me to understand how everything is connected.

A wallet has its set of Public-Private key pair.

An Account will have its set of Public-Private key pair.

Algorand’s Key Management Daemon (kmd) process is one of the ways of managing the wallets.

A wallet will consist of many Accounts. Each of these accounts will represent an entity on Algorand Blockchain.

So when we say an address, it is the address generated from the public key of an account?
And how does this address different from the address of the wallet (which will also be generated from the public key of the wallet)?

All ASAs are eventually part of Account, so these accounts need to opt-in for any asset?

For an instance, If I am connecting end user to Algorand blockchain, and handling their keys. Are these users part of my single wallet with multiple accounts. And each of the account can be mapped with a user?

Lastly, How many accounts are possible in a wallet, is there any limit?

And I want to add: Algorand Mobile Wallet app shows the accounts mnemonics, how can I get the mobile wallet mnemonic too?

Hi,

At the Algorand blockchain level itself, there is no notion of wallet: just accounts.
“Simple” accounts are defined by a pair of a public key and secret key. The address is just a representation of the public key with a checksum.

There also exist more complex accounts: multisignature accounts and contract accounts (for smart contracts - Introduction - Algorand Developer Portal).

Wallets are provided by Algorand’s Key Management Daemon (kmd). Accounts generated from a kmd wallets are derived from some “master seed” (or secret key). However, a wallet does not have a public key.
For more details, see Overview - Algorand Developer Portal

Here are some answers:

So when we say an address, it is the address generated from the public key of an account?

Yes

A wallet will consist of many Accounts. Each of these accounts will represent an entity on Algorand Blockchain.

Yes

So when we say an address, it is the address generated from the public key of an account?

Public key of the account, for simple accounts. Wallets do not have public keys by themselves.

All ASAs are eventually part of Account, so these accounts need to opt-in for any asset?

Yes. A special transaction is used to opt-in for an asset. See Algorand Standard Assets (ASAs) - Algorand Developer Portal

For an instance, If I am connecting end user to Algorand blockchain, and handling their keys. Are these users part of my single wallet with multiple accounts. And each of the account can be mapped with a user?

It might be an option for settings where very low security is required. If the machine with KMD is compromised, all the secret keys may be lost and all the Algos held by these accounts can immediately be spent by the hacker (without any way of recovering them). You need to study carefully security trade-offs. In particular, you may want to consider storing the keys completely offline, inside HSM, … depending on the security model you are considering.

Lastly, How many accounts are possible in a wallet, is there any limit?

I don’t know, my guess is that there is no limit

And I want to add: Algorand Mobile Wallet app shows the accounts mnemonics, how can I get the mobile wallet mnemonic too?

I don’t know the details of Algorand Mobile Wallet, but I don’t think it actually derives the accounts from a single master seed / mnemonic.

2 Likes

The mobile wallet does not have a mnemonic for the wallet. Just mnemonics for each account.

Using the kmd wallet, you have no practical limits on the number of accounts.

1 Like