0

I trying to build out a service that holds user's monero private keys. But the issue I'm having is how does one update their balance of these private keys? And no I cannot use subaddresses for my use case as each user has their own unique private key. The solution I came up with was scanning each monero private spend key manually one at a time and updating the balance like that. But that's not going to really scale that well if I had 100k private keys to scan.

What can I do to solve updating monero balances of 100 user's private keys?

0

Computing the balance of a wallet requires scanning all the transactions with the secret view key to detect received coins, and using the secret spend key to detect which of them have been spent. Therefore if you have several distinct wallets, you have to scan every transaction with the secret keys of every wallet. There is no trick allowing to compute the balances of several distinct wallets faster.

If I understand you question correctly, you're trying to make a custodial wallet (where you have the secret spend keys, like the wallet of an exchange). In this case, having only one wallet and using one subaddress/account per client (or one payment id per client) is the most efficient way to compute the balances, as you only have to scan the transactions with one secret view key, even if you have thousands of clients.

  • cannot use subaddresses because the user will also have a copy of their private. its a shared private key system. users should not have each others keys. – Patoshi パトシ Mar 8 at 15:32
  • Why would users ever give the private spend keys of their personal wallets to a third party? That would be a very bad idea. – glv Mar 8 at 15:42
  • You get to do unique services related to crypto with a shared private key. Obviously your not putting your entire life savings on such a private key. Ex. Give me your private key to send a payment on your behalf OR send me your monero and lose total control over it. One method you still control the keys and can always withdraw your coins, the other method you give me the coins completely and lose total control over it. Obviously this is all based on trust of the 3rd party. A shared private key has its use cases. – Patoshi パトシ Mar 8 at 18:35

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.